WordPress 3.3.2 Fantastico Update Issue

When Fantastico works, it works great. When it doesn’t, it’s a royal pain in the ass. I got notified through CPanel that my WordPress install required an update so I kicked it off through Fantastico. I should have known better and updated manually. This will be the 3rd time I’ve “trusted” a WordPress upgrade through Fantastico only to be savagely beaten in the process. This is a polite warning to all Cpanel/Fantastico users, DO NOT USE THE AUTOMATED UPGRADE FOR WORDPRESS 3.3.2!! It will almost certainly trash your entire website and possibly your server and I’m quite serious. The problem is actually the script provided to Fantastico by WordPress, I shouldn’t really be trashing Fantastico for this although they should be doing some due diligence to ensure their scripts work properly.

The problem begins with the backup part of the script. I have WordPress installed in my root directory but I have a lot of add-on Domains (completely unrelated to my WordPress blog) that use sub-directories off of the root directory. The WordPress 3.3.2 backup script assumes I want to back up EVERYTHING off of my root directory, which is a bogus assumption in the real world, so the script immediately died after creating a corrupted 18.5GB tgz file. Amusingly, the file showed 2GB in FTP, 18.5GB through CPanel’s file manager and downloaded through HTML at 12GB. There should have been an error break, time out condition, something in the script that stopped everything right there so my install would have been saved but NO. It continued on, leaving me with no viable backup to restore from.

The next problem begins with the table prefixes. The 3.3.2 automated upgrade assumed I wanted wp_ prefixes. I did not. I use unique table prefixes in all my product installs (a check to make sure I don’t update the wrong tables in different installations of the same product). After the backup portion of the script died, the update completely stalled and when I refreshed the page, I just got a default installation page so I put in some credentials and an email address and pressed continue. 2 years of work gone in an instant….with just a HELLO WORLD post to show for my efforts. Everything was gone, with no possible restore. Well, sort of. I installed a WordPress backup plugin ages ago just because of nonsense like this so I did have a backup lying around somewhere but it’s a manual effort and only for paranoid loons like me. Short story, I did have a fallback but it was that fallback that keyed me into the table prefix problem.

You see, after the upgrade I dropped all the tables and imported my backed up SQL file only to find there was no change whatsoever. I was still left with a default WordPress template and a single HELLO WORLD post. I immediately had a panic attack. WHY!? Took my pills, calmed down and started digging. I could see all my posts through phpMyAdmin….so why weren’t they showing!? The wp_ prefixes didn’t catch my attention at first because I’m used to seeing those on lots of other sites. The light finally dawned on marble-head that my posts and pics and music and videos were all under a different prefix but the default install was using wp_. The problem was in the wordpress config file, which was looking only for wp_ table prefixes. Updated that to my unique table prefix and VOILA! My site returned.

In short, here’s how YOU should upgrade your WordPress install to 3.3.2. First, do your own backup before you do anything. There are lots of plugins for that or you can do it yourself. Be absolutely sure you backup your table though! It will save you. Next, do NOT use Fantastico. If it backs up all the wrong data like it did with me and your allocated server space is exceeded, you could be severely screwed and lose not just your website but other clients! Don’t do it. Do the upgrade from within WordPress – I found at least that only touched relevant files. If the upgrade stalls or dies, don’t panic, just refresh the page. It will finish but leave you on the default install page. Put in your credentials an continue. Yes, you’ll be left with a crap starter page like me but it’s all good. Go to your favorite table editor and drop all your WordPress tables and import your SQL backup. Check your site, if you use the default wp_ table prefixes, you should be back in business. If not, check those table prefixes in your table editor and write down what you just imported. Now go to your wp-config.php file and change the appropriate line from wp_ to whatever your table prefixes are. Last, go back to your table editor and delete all tables with prefix wp_. Now everything should be back to normal.

This is way too much work to be going through for a simple update to a canned install of WordPress. Very disappointing. Will have to troll some support sites and put a fire under some butts to ensure the next upgrade is less painful.

Comments (0)

› No comments yet.

Pingbacks (0)

› No pingbacks yet.