How Not To Upgrade WordPress

Post written by: Mike

I decided to upgrade one of my blogs from WordPress 2.1.3 to 2.2.1 during lunch yesterday. I’ve done several upgrades in the past without any issues using the detailed upgrade instructions instead of the 5 step upgrade instructions.

Yesterday, I was not paying enough attention and messed things up badly. As a result, I could not access the blog after the upgrade. It appears that I deleted the wp-config.php file that the instructions clearly state not to delete.

Then, while FTP’ing the wp-config.php file back to the server I put it in the wrong directory. It ended up in the directory of a different blog that unfortunately happened to share the same database server.

At this point, I had my parenting blog that could not be accessed and my Iowa Hawkeye blog that was showing all of the posts from the parenting blog and no idea what was causing any of it. In fact, I didn’t even know that the Hawkeye blog had a problem yet.

I deleted everything from the parenting blogs directories and restored all of the backup files which included the wp-config.php. Everything was happy on the parenting blog.

Then, I started getting trackbacks in various places from the Talk Hawkeye blog and finally realized that it had issues. I looked at the wp-config.php file there and noticed the timestamp was really recent. So, I copied the file from an old backup of the directories and everything was back to normal.

That is how not to do a WordPress upgrade.

Fortunately, I did backup before the upgrade. Always backup the directories and database before any major changes.

Also, I recommend always using the detailed upgrade instructions paying careful attention to what needs to be deleted and what needs to be kept.

And never upgrade during lunch when you are not really paying attention.

3 comments ↓

#1 Matt Keegan on 07.19.07 at 10:29 am

Ouch! That hurts. I’ve done the same — worked on an update by giving it only partial attention. With so many files involved and the config.php file to keep an eye on, a slip up can be damaging. Thankfully, you had the presence of mind to back everything up before you proceeded.

#2 MajoTajo on 07.19.07 at 1:48 pm

My blog hosting made easy on me with fantastico and upgrades the blog without any hassle 1 click and thats it. If you want to see the code let me know , you can create same for your self :)

#3 Mike on 07.26.07 at 3:59 pm

MajoTajo,
I would be way too paranoid to let the hosting company handle the WordPress upgrades just because of all the little customizations that end up getting put into the theme files.

Matt,
I learned about making the backups one time more than a year ago when I went to do something completely harmless and broke everything and had to start over from scratch because I forgot to backup. That ended up just being a careless cut and paste that cost me a day of effort.

Leave a Comment