In case you haven’t noticed, there’s been a few changes and other screwey things happening on this site. On 9 March 2009 I received a email from my then hosting provider MacHighway.
Unfortunately, we’ve needed to suspend your blog, greginthedesert.net. Your site is regularly using between 30 – 99% of the CPU on that server. It appears that your site is getting around 161k hits per month. The good news is that Technorati estimates that a blog getting 100k his a month is worth $75k/year. The bad news is that it’s far exceeds the fair use policy of our shared hosting environment. Your sites’ needs have outgrown what a shared hosting provider can offer.
Additionally, your site calls on a tremendous amount of resources with all of the dynamic information that the site needs to load in order just to display the front page. This is exacerbating the problem and should definitely be trimmed down.
I totally understand how this was a problem and I can see how I made it worse with some of the stuff I was using to generate my blog since I have been experimenting with plug-in’s and templates. I replied to the support ticket and said I had a number of ideas on how to reduce the CPU usage of my blog and that I wasn’t coming close to my bandwidth or disk usage quotas. They were having none of it and said move my blog elsewhere.
It also would have been nice if they could have given me some heads up about the excessive CPU usage. I guess they didn’t want me as their customer. It’s too bad since the few other issues I had with MacHighway were well taken care of.
I started to look for a non-shared hosting provider. Dedicated hosting is expensive, the cheapest I found was nearly $100 a month. Even though the MacHighway support guy suggested my blog should be worth $75,000, I make tens of dollars a year on advertising, not hundreds. There is no way I can afford dedicated hosting. Also, the 161,000 hits a month I get are only translating to about 9,000 real people a month. I also can only see where 58K hits a month are coming from including robots, image leachers, etc.
After a searching around for a few days including local services providers I ended up going with another shared hosting provider: Dream Host. In fact, there’s a number of things I like about them but that’s a blog post for another day.
MacHighway temporarily enabled my blog so I could export my data. I copied all the WordPress directories to my hard drive, exported the database and exported a WXR file. Just in case the database dump failed to import.
After getting my domain redirected to the new servers at DreamHost and WordPress installed, I attempted to import the database. The raw sql file is 230MB and compressed it’s 22MB, far more than the 7MB limit that the phpmyadmin allows. I had to become familiar with the command line to do the import. After contacting DreamHost support because a few things weren’t properly configured on my account I attempted to try the command line import sequence. The import failed on line two, where the sql file’s phpmyadmin version was 18.104.22.168 and DreamHost’s version is 22.214.171.124. I commented that line out and tried the import again, next fail was at line 7.
I contacted DreamHost support to see what they would say about the situation. They tried importing and found several lines which failed. The support person suggested that I continue to comment out lines which fail. I thought that was a bad idea since many of those line look like important parts of the database creation process and I didn’t know how long this editing-upload-fail-repeat process would continue.
Database import wasn’t going to work. I started working on importing the WXR file. My import file was 10.6 MB, bigger than than the 7MB limit imposed by wordpress for import files. I compressed it, which I read elsewhere could overcome the import size limitation. Even though it brought the file under 7MB, it could not get it to sucessfully import. I had two results with the importing of the WXR file, sometime the site would just hang sometime it would give me a 408 page.
I went through and removed the 14,000 plus but that didn’t change the results. I broke the WXR file into several small files and was able to have successful imports. I went through a process of having one half of the cut up file succeeded importing and the other half fail. It has become clear that there is some part at the beginning of the WXR that is corrupt or some other problem that is confusing the import process.
There are still abut 400 posts left to import, but the majority of the important ones are there and I will continue to go through the process of breaking up the remainder of the WXR file until I find the problem entry. Although I learned a lot about WordPress and phpmyadmin and SQL databases, I’m looking forward to getting this whole ordeal behind me and return to blogging.