Categories
General

Upgrading WordPress using rsync

After the recent flurry of WordPress upgrades I started looking for an easier way to upgrade. This post at techites.com was a good start, but this comment on the post, using rsync, sounded much easier. Here’s the workflow I figured out:

  • wget http://wordpress.org/latest.zip (download the latest version)
  • unzip wordpress-XXX.zip (extract it)
  • mv wordpress [your-site's-folder-name] (rename the wordpress folder to the name of the folder your blog lives in on the server)
  • rsync -avrz [your-site's-folder-name] [username@server]:[path-to-blog-folder] (update the remote folder with the local folder)

Repeat the last two steps for each install you want to update. I’m sure it’s possible to write a script to do this for a whole bunch of installs at once if desired. You may want to test all this out on your local testing server beforehand.

Update: Jonathan’s right, Subversion is a VERY easy way to update WordPress…once you’ve got it set up. This Codex page describes the process. It’s easiest to do if you’re either just setting up your blog or if you only have a couple of plugins or themes installed. There are other benefits to using Subversion. You can easily switch from using the current release version to using the bleeding edge version, for instance to test out a release candidate. The WP Subversion repository also wasn’t affected by the recent security exploit, so there may be a security advantage.

Avatar photo

By isaac

I like cats. he/him