WordPress version 2.7 has been released and can be upgraded easily using UNIX / Linux shell prompt. A few assumptions:
- WordPress database name: wptheosblog
- WordPress directory name: /var/www/html/theos.in
- WordPress domain name: theos.in
- Operating system: Linux
If you are not comfortable with UNIX shell prompt (IF YOU ARE new to a UNIX/Linux os), please follow traditional way of upgrading wordpress
and DO NOT use the three Steps described here.
[click to continue…]
Since I use wordpress as CMS for 2-3 different websites, upgrading wordpress is an essential task for me. Upgrading wordpress from shell prompt is the easiest thing.
Howto update wordpress
Please note that if you are not comfortable with UNIX shell prompt (IF YOU ARE new to UNIX/Linux), please follow traditional way of upgrading wordpress and DO NOT use following instructions ;)
Step # 1: Backup existing database and wordpress directory
Type the following commands at shell prompt:
$ mkdir /backup/wp/28nov2006
$ mysqldump -u user -p WP-DATABASENAME > /backup/wp/28nov2006/blog.db.sql
$ tar -zcvf /backup/wp/28nov2006.tar.gz /var/www/html/blog
Step # 2: Download latest wordpress CMS
$ cd /tmp
$ wget http://wordpress.org/latest.zip
$ unzip latest.zip
Step # 3: Overwrite all new files
$ cd /var/www/html/blog
$ cp -avr /tmp/wordpress/* .
$ rm -rf /tmp/wordpress /tmp/latest.zip
Open a browser and run update script such as http://yourblog.com/wp-admin/upgrade.php
And you are done. Thanks to UNIX shell access. It just took less than 1 minute!!! Replace path names and database name with actual values.
In case, if something goes wrong, you can always restore old database and files from /backup/wp/28nov2006 directory.
PS: I wrote this because some one recently asked me how to upgrade wordpess from command line.