If you use Drupal you will be both pleasantly surprised and frustrated by the frequency of updates and security patches.
This How To will help you quickly backup and upgrade your Drupal installation via ssh and simple shell commands.
You must have ssh access to your server in order to follow this tutorial.
- If you have ssh access, just follow these simple steps
- SSH into your server (duh!)
ssh username@host
- change directories so you can see your public_html (web root) sometimes this is welcome or home but usually it will be public_html.
Backing up from here will keep the backup private, and make it easy to back up your whole web directory.
cd ~/
will do the trick on most systems
- Make a backup of your public_html directory
tar cvfz public_html_bak.tgz public_html
- Make a database backup
mysqldump -u username -p dbname | gzip | mysql_bak.sql.gz
- Change into your public_html directory
cd public_html
- Goto http://www.drupal.org and copy the location for the latest drupal version for this example lets say this is http://ftp.drupal.org/files/projects/drupal-6.13.tar.gz
wget http://ftp.drupal.org/files/projects/drupal-6.13.tar.gz
- Extract the tar contents into the current directory stripping of the first directory (drupal-6.13) in this example.
tar xvfz drupal-6.13.tar.gz --strip-components=1
- Run upgrade.php
All done, now wasn't that quick and painless?
Be sure to see the next How To Restore Drupal from backup on a linux server
| Attachment | Size |
|---|---|
| drupal_update_howto.mov | 33.27 MB |


good work
evden eve nakliyat is a leading web site hosting service provider that is known to provide reliable and affordable top medyum packages to customers. porn teen tube company believes in providing absolute and superior control to the customer as well as erotik complete security sikiş izle and flexibility through its porno izle. windows hosting Moreover, the company provides technical support as well as customer service 24x7, tuzcuoğlu nakliyat
in order to enable its customer price. Thanks instaspace
Small adjustment
Actually you should not overwrite the "sites" sub-directory because this contains all your specific settings.
Well, when making a backup I
Well, when making a backup I think having everything is good. You are correct that you do not need to backup or restores sites, but might as well make a full backup.
Just tack on --exclude="sites" if you do not want to extract it from the tar, but doing so will not hurt since you just made the backup.
Thanks
Thanks for this. I've been searching for an easier way to upgrade for the last hour and this is as simple as it gets. And worked perfectly for me.
You are welcome
I am glad you found this post helpfull.
Post new comment