Posts Tagged ‘upgrade’

Tips for upgrading to WordPress 2.9 on 1and1

Thursday, December 24th, 2009

A few days ago I upgraded this blog from WordPress 2.8.5 to 2.9. Here are some tips on what I did in case you run into any of the same issues that I did. My blog is hosted by 1and1 and some of the information may be specific to them.

This isn’t meant as a full upgrade guide – just a collection of tips that may help you.

First make sure you backup your data! There are some general wordpress backup tips on a post I did about a previous upgrade.

1. Export the SQL database

In the MySQL admin panel I selected these extra options: ‘Add DROP TABLE’ and ‘Complete inserts’, and then chose to save the file as a .gz (gzip) archive. If you need a free application to read .gz archives then I recommend 7-Zip.

Oneandone MySQL icon

2. Export the XML data

Export the XML post data from the WordPress admin panel (Tools->Export).

3. Zip and downloaded the blog files

Zip up the actual files on the server. On 1and1 the easiest way to do this is to logon to your admin panel, go to the Webspace Explorer, right-click on the directory and select ‘zip’.

You can then right-click on the zip file and choose download to copy it down to your computer.

4. Verify the data

I verified that the exported SQL data, XLM and .zip files were valid. The easiest way to verify the SQL and XLM data is to look at it in a text viewer such as NoteTab Light and make sure that the data at the end of the file is valid. Sometime a download can silently fail and you can end up with truncated data. If you try to restore the data from a truncated file then the restore will fail.

Verify the .gz file by making sure it will open in 7-Zip.

Click on the upgrade button

I finally was ready to click on the upgrade button. I clicked on it and a second or two later I got the message:

‘The update cannot be installed because WordPress 2.9 requires MySQL version 4.1.2 or higher. You are running version 4.0.27’

How I got around it

The partial answer is contained in the post here. However I’ll add a few bits of information on what I did differently.

I created a new MySQL 5.0 database from the MySQL admin panel. On the 1and1 business hosting package I think you can create two MySQL databases so you don’t need to delete the existing one first. Don’t delete it – you may need it if everything goes wrong with the upgrade!

I didn’t import the data by using the XML backup. I imported the data into the new MySQL 5.0 database from the gzipped SQL archive that I’d created in step 1 above.

You can import the SQL data from the MySQL admin panel by going to the tab to execute SQL commands, and then selecting the .gz file. Importing the SQL file through a .gz file gets around the 2MB size limit in the MySQL admin panel.

Importing from the .gz file rather than the .XML will import all your database data, and plugin settings, whereas if you do it from the .XML file you may have to manually re-enter various settings into your blog.

In your wp-config.php you will have to ensure that the DB_NAME, DB_USER, DB_PASSWORD and DB_HOST have been updated with the settings of your new MySQL 5.0 database.

Upload the wp-config.php file and if everything has gone right your blog should still be working and look exactly the same as before. Your blog will be using the old version of WordPress but will be accessing the data from the new MySQL 5.0 database.

You should now be able to click on the upgrade button and the blog should upgrade in less than 5 seconds.

This worked fine for me on 1and1. If you have loads of plugins or a heavily customised theme you may find more problems. If this is the case you can try deactivating plugins, or switch to the default theme.

If you really can’t get things to work you should be able to roll back to your pre-2.9 WordPress blog by restoring the files that you zipped in step 3 above. You MySQL 4.0 database should still be there (as long as you didn’t delete it).

Upgrading WordPress can often be a pain but at least having upgraded the SQL database from 4.0 to 5.0 should avoid more problems in the future. And now with WordPress 2.9 you can look forward to batch updating your plugins rather than doing them one at a time!

Upgrading Samsung N140 RAM to 2GB

Tuesday, December 22nd, 2009

The Samsung N140 netbook – as reviewed here, is a great machine – but it is much better if you upgrade the 1GB RAM that it ships with to 2GB. Here’s a quick guide, with photos, of how I upgraded the memory of mine.

First you’ll need to buy a 2GB RAM module – they aren’t expensive and you can buy them from computer shops or online. You need to be careful to make sure you get the right type. You’ll need a 2GB DDR2 SDRAM at 800 MHz such as this 2GB RAM module from Amazon.

Make sure you back up any important work first in case it all goes wrong. If you manage to fry your original memory module and the new memory module then you won’t be able to boot up the N140!

Shut down computer fully – don’t hibernate or put it on standby otherwise it may get confused by the extra RAM when it wakes up.

Remove the battery.

Touch a radiator or other earthed object to get rid of any static charge that is in your body. If you have one then wear a static strap that is connected to an earthed object. Static is one of the big killers of RAM so be careful!

Remove the screw on the memory cover on the base of the N140. Then you’ll have to pull the cover off – I had to apply a bit of force to get it to open.

samsung n140 underneath memory

Pull the clips outwards and the old RAM should click up.

samsung n140 memory slot 2

Remove the old RAM.

Carefully insert the new RAM into the socket and make sure it clicks back down into place.

samsung n140 memory slot

Put the memory cover back on, re-insert the battery and turn on.

Hold your breath! Hopefully it works and you should see 2GB (or more probably 1.99GB) listed in the System Properties page. You can hold the Start key, Fn key and Pause/Brk to bring up the System Properties page. If it doesn’t then re-open the memory cover and make sure that the memory is correctly plugged in.

Keep the old memory safe – in case of emergency you can always plug the old memory back in.

Roll on one click updating of WordPress plugins

Wednesday, February 13th, 2008

Today I saw the future of WordPress plugin upgrades.

Anyone who has a WordPress blog with a number of plugins installed will know how much of a chore it can be to keep those plugins up to date. The official way of upgrading any plugin involves:

  1. Spotting the plugin has a new version available from the WordPress plugin page.
  2. Downloading the new version of the plugin to your computer.
  3. Unzipping it.
  4. Deactivating the current version of the plugin from the WordPress plugin page.
  5. Uploading the new plugin via FTP.
  6. Activating the new version of the plugin.

This is boring, and wastes my time, but unfortunately is often essential. Especially if the update is to solve a security vulnerability. I have two blogs, this technology related one and my London Underground walking blog. Each of these blogs has six active plugins so each time one of these plugins is updated I have to update the plugin in two separate places.

Today I went onto the option page of the All in One SEO Pack plugin and spotted an option which I hadn’t seen before – ‘One Click Upgrade’.

One Click Upgrade option on WordPress All in One SEO Pack plugin

As it happens this plugin was out of date so I clicked it and after a second or two saw this message.

One Click Upgrade option on WordPress All in One SEO Pack plugin

How cool is that? Very. It has changed upgrading this plugin from a chore to something that is almost fun. Behind the scenes when you click the button it fetches the latest version of the plugin and extracts it to the correct location.

This is the kind of feature that we are used to seeing on PC software but it is the first time I’ve seen it on a WordPress plugin.

On further investigation I spotted an interesting project which attempts to generalise the one click update of WordPress plugins. It is called the One click plugin updater. This tries to add this facility to existing plugins. From the comments on the plugin page it looks like it doesn’t work for all everyone but it is certainly a very good idea.

This facility is definitely something that WordPress should think about integrating into its core code base and encouraging all plugin creators to adopt.