With the recent scare regarding a serious security vulnerability in pre-WP 2.8.4 , and the response from WordPress I found myself facing upgrading multiple sites that I own, or sites that I manage for others.
In some cases, this was not an upgrade from 2.8.2 to 2.8.4 since I had neglected some sites for a while, or haven’t been able to upgrade yet, others were almost up to date. If, like me, you’re responsible for multiple site, either your own, or sites that you manage as a webmaster, this needs a bit of planning, and in my case, a simple list that I can tick off, just to make sure I don’t miss anything.
First, I identified the steps involved in an upgrade of WordPress. There are clear instructions on the WordPress site, I’ll just post my simplified approach here.
Step one, list all sites you need to upgrade.
Most likely, when managing multiple sites, you will have some list with the sitenames, WordPress login info, database connection details, and FTP info, together with your contact details. If not, now is a good time to make such a list.
List all activities involved in upgrading
Now these may not apply to everyone, but I try to be safe rather than sorry.
- Inform the site owners, and get their consent – Most likely, in case if such an urgent need to upgrade, I’m sure that won’t be too hard.
- Prepare your tools – Make sure you have access to the sites, ftp access, WordPress logins, and any other tools you prefer to use (e.g. plugins for backing up WordPress, the theme(s), the database, see also links at the bottom of this article)
- Backup the database – I prefer to do so by doing a full export of the database via PHPMyAdmin, if you feel comfortable doing so using a plugin, or any other tool, that is fine. Just make sure you will be able to restore the site exactly as it was before you did any upgrade activities.
- Complete Site backup – I use the manual approach, and use an FTP program to download the entire site to a folder on my local machine.
- Export your posts – Just because it’s easy, and in case a backup fails, at least you will have a WordPress formatted XML file with all posts, comments, categories, users, tags etc.
- Put the site offline – To avoid site visitors to run into a half upgraded site, I use the maintenance mode plugin to disable access to the site, unless you’re logged in as a user with Administrator site.
- De-activate all plugins – This may seem a simple one, but one good advice, make note of all plugins that you deactivate. In most cases, there may be plugins already de-activated that you needn’t/shouldn’t activate once the upgrade is finished
- Check custom modifications to WordPress – This may apply to very few, but I know that for some customers, I have modified the script that holds all the buttons in the WordPress editor (quicktags.js). This file is located in the wp-includes/js folder. Note, recently, I found a better way to add custom quicktags without having to modify core WordPress
- Upload the latest version of WordPress – Assuming you have already downloaded the theme, and unpacked it somewhere on you local machine. Using FTP, overwrite all files on your server. Check if there are any files failed to upload. If so, retry until all files are uploaded.
- Perform the upgrade – To do so, navigate to http://www.yoursite.com/wp-admin/upgrade.php and hit Enter. WordPress will inform you if a database upgrade is required, and with a click on a button, the database upgrade will be performed.
- Reapply the custom modifications – This refers to any modifications made to core WordPress files, such as modifications to quicktags.js. Verify any changes in the standard code, there may also have been changes caused by the upgrade, so you can’t simply copy the old files over the new ones. You will have to check this carefully.
- Activate plugins – Re activate the plugins, and update when indicated.
- Test and verify the site – This should be a shared responsibility of you, as the site manager and the site owner. Generally, the site owner will have a different way of looking at things, and probably uses different functions than site managers/webmasters.
- Get go/no go from the site owner – It should also be clear that it is the site owners responsibility to release the site again.
- Put the site back online – When using the maintenance mode plugin, de-activate it.
Put Together An Upgrade Checklist
What I then did was put this all together in a spreadsheet, and just work by this checklist. Whether you want to do so top to bottom, then left to right, or left to right and top to bottom is up to you. The last approach will ensure the shortest downtime for each site.
So there you have it, a simple checklist and planning to make this as painless as possible.