How to Safely Upgrade to the Latest Version of WordPress

August 8, 2009 by Russell Hall  
Filed under Articles, WordPress

A Pictorial Guide to Safely Updating to WordPress 2.8.3 How to perform a WordPress database and files back up in under 60 minutes!

I recently upgraded to WordPress 2.8.0 and thought everything was just great, but then I read that the reason WordPress 2.8.1 was released so quickly was because there were a few bugs with WP2.8.0,- in particular relating to security issues. I also noticed that I was getting some display errors and so I decided to do the update to the current WordPress version of 2.8.3.

Now, if you’re ever thinking of updating your own WP version, you may be tempted to simply click the ever present link in admin that prompts you to "Update to the latest version of WordPress" 2.8.3 as it is at the present time of writing this article. Sure, you could click the upgrade link and everything would probably go just fine and you’d be done in about 30 seconds flat! But what if something went wrong during the auto-reinstall process and you lost some or all of your data? Yeah.. how would that make you feel,..months or years of hard work down the tubes?

So I decided to do a proper back up and be sure. I’ve done plenty of database back ups and exports and imports before (most of which have gone smoothly but a couple required hand editing) and so I thought it wouldn’t be any drama and I reckoned I pretty much knew what to do. However, just to be sure, I Googled the search phrase "how to safely update to the latest version of Wordpress",.. and surprisingly I found very little relevant results relating to version 2.8 and above. There was quite a bit about 2.7 (as that was a milestone upgrade) but little else on the later versions.

Anyway,.. I did find out and figure out what I had already concluded and so I proceeded to get on with the job. Just before I got started I decided that it would be good to document it all for the benefit of others perhaps less experienced, and that’s how this article has come about. I’d read some blog posts and forum threads where people had said that the process had taken them 3 hours! I thought that sounded very odd as I knew from experience that a simple MySQL database export & import could be done in about 15 minutes or less (about 5 minutes with a plugin… more on that later). So I put the stopwatch on this task and I’m pleased to report that it can be done in under 60  minutes (it took me 58 minutes exactly),.. and I did some other tasks while I was waiting for a couple of the folders to download (wp-admin & wp-includes took the longest.. 40 minutes for them both together).

Ok you guys,… let’s get started with the main part of this article which is the Tutorial on how to do an effective WP version update without losing any data! I must at this juncture, point out that this tutorial is based on my experience and presented in good faith. No responsibility or liability will be taken in circumstances where this information may have been applied either incorrectly or having resulted in a different outcome for any reason whatsoever.

First step

(actually it’s a cautionary notice really),.. DO NOT click the "version update" auto install link until you’ve gone through this backup procedure. You might want to put up the under maintenance splash page for an hour while you do this (use the plugin "Maintenance Mode",.. it does a good job).

image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
1 Go to your plugins page in WP Admin and check the "plugins" select all tab. Then from Bulk Actions select "Deactivate" and hit "Apply". Great,.. now all your plugins are deactivated. (see image )
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
2 Open your ftp client and download all your WP install files that are sitting in your primary directory (usually /public_html) to a new empty folder on your desktop (just a holding folder is fine) it should only take about 60 seconds (with broadband) even though there are quite a few files.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
3 Select the current theme you’re using and download the whole folder to your desktop (put it into the same holding folder,.. I named mine "wp-update-back-up files"). That should only take you about 3 minutes.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
4

Select the wp-admin and wp-includes folders and download them (you don’t need to download   wp-content because you’ve already downloaded the current them folder,..and the plugins can all be replaced from their direct download directories if necessary anyway). This part will take around 40 minutes (@1.5gb/sec download)

image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
5 Now that you’ve downloaded the main WP files from your server (these will be replaced in the auto-update process shortly), you should go to your hosting Control panel (in my case that’s Cpanel) and click on phpMyAdmin to take you to your database admin panel.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
6 Once in the admin panel you need to select the database relevant to the domain upon which the WP install resides (in most cases you’ll only have 1 database per domain unless you’re operating a "hive",.. which I don’t really recommend for most circumstances…more on this later,.. or send me an email and I’ll tell you when *& why to avoid a WP hive set up). You go to the "select all" tab and click it. Once clicked you need to set up the download settings properly (see the image and attendent notes). From within the same window then select "SQL" (the default setting) and in the options box make sure that the "Compatibility" is left at the defaulted "none" setting. Next, click the boxes in the "Structures" window as follows: "add DROP TABLE", "add IFNOT EXISTS", "add AUTO_INCREMENT value", "Enclose Table & Fieldnames with backquotes". From the "Data" window select: "Complete inserts", "Extended inserts", "Use hexadecimal for BLOB". Note that "Export type" is defaulted at "none",- leave it set at the "none" default.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
7 Get ready to save and export your database tables to your desktop. It’s a simple process of checking all of the boxes indicated as follows (and in the images attached) and then select "save" in the bottom left of the page, followed by clicking "go" on the botton right of the page, then the file (either, "none" "zipped" or "gzipped" as per your choice) will get sent automatically to your desktop.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
8 Once you’ve selected "Go" to start the download of your database tables, the relevant file will be sent to your desktop (takes less than 30 seconds). Once it is on your desktop I recommend opening it up into a plain editor such as "Wordpad" and just make sure that you can read the text and that it hasn’t come out garbled. Usually it will be OK,.and if there was any error in data transfer you should have received an error dialogue anyway.
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
9 Now you have successfully saved your WordPress theme, the install files, and the wp-admin & wp-includes folder, and that process should have taken around 50 minutes (@1.5gb/sec broadband) so that you can go ahead and click the "Please Update to 2.83" link in your WP admin panel knowing that your current install and data is safely backed up!
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
10 You’ll see an "Update Wordpress" progress window show up that goes through the 5 steps of the update from uploading and unpacking the 2.8.3.zip to unpacking it and installing it and finally notifying of the successful completion (that takes about 10 seconds).
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge
11 Now that your new update install had been done, go to your plugins page in WP admin and check the "select all" box to prepare to reactivate all your relevant plugins (you don’t need to reactivate any that you weren’t using before). Click "reactivate" from the "Bulk Actions" menu and you’re all done and ready to go. All you need to do now is go and check out you blog at the front end and make sure all is fine. If for any reason you see errors, you can just try to troubleshoot them as you go, but if it seems major then at least you can start from scratch by reinstating the previous install via the saved files you have (and that would be the topic of an entirely separate tutorial).
image-in-series-how-to-upgrade-to-latest-version-wordpress
Mouseover to enlarge

 

So that’ it folks,- a brief tutorial on how to safely perform an update to Wordpress 2.8.3 version in 60 minutes or less! In fact, you can follow this process for any version update because the principles of saving current files and installing the new will remain the same.

A question I’ve been asked about this updating procedure is "what about using an Update plugin?". My response is that you could do that, but make sure that all the files involved have in fact been saved properly. Frankly, I think once you understand simple procedure involved in performing the update, then you might as well do it manually to ensure the human element of control. After all, you can set to this task and have it done in under and hour, and still be working on other things in the background (like writing your next post in Word, ready to upload once your blog is reactivated,… just as I did with this article you’re reading now!).

If you enjoyed this article please leave a comment and/or Tweet, Facebook, Stumble, Digg or bookmark it,.. and feel welcome to link to it if you wish.

If you have any requests for other similar tutorials please feel welcome to ask, and time permitting I’ll see if I can fit them in.

Happy blogging!

russell-sign-off

 

 

 

 

Post to Twitter Tweet This Post to Digg Digg This Post to Facebook Facebook Post to Reddit Reddit Post to StumbleUpon Stumble This

Tags: , , , , , , , , , ,

Related posts

Enter Google AdSense Code Here

Speak Your Mind

Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!

Leave a comment & get a linkback to your blogCommentLuv Enabled

Spam Protection by WP-SpamFree

Subscribe without commenting