Forum Moderators: phranque
I rent 2 dedicated linux web servers which host all of my websites.
I am looking for a way to back up the entire hard drive on each of these servers - and take an image of them and store it on my home PC - across the internet.
If the server were go up in flames, and the hosting company provides a fresh hard drive, the restore process should put the drive exactly as it was (configuration, websites, and all) when the last backup was taken...
Is this possible? (My home PC is an XP machine)
I appreciate any help you can give...
Dan
AFAIK full disk images (partitions etc.) can only be done offline - like from a boot disk. This would mean someone would physically have to be at the server, boot, create the image, restart.
Not only that but when it comes to restoring you would need the datacenter guys to a) know where you backup dvd is located, b) know how to reinstall the driveimage.
I thought of doing it that way but it's just not practical unless the server is with you.
Simple Tar / Gzip Backup
An easier, but not ideal solution, is to just use a standard incremental backup of the server by creating a tar.gz file. This file is generated everyday and you can download the data to any pc you wish.
I use two drives. One for the server, the other for temp files, log files and backups. If the main drive goes the webhosters reinstall the basic Linux image, I then restore my /home/ website dirs and any other software I have loaded.
This has happened to me twice now and it takes about an hour to get the server back to a working state after a disk has been replaced / Linux reinstalled.
I use a cron job to generate the backup file each day at 04:00. The file is generate and stored on the second disk. I also SCP the complete file to one of my other dedicated servers, and at 04:30 receive the backup of the other dedicated server.
#cd d:/backups (disk with a lot of free space)
#ssh your-host.com "sh -c tar cfz - / 2>/dev/null" > your-host.com.tar.gz You can always unpack entry archive or some part of it. Read
#man tar If you want to make daily updates of backup, you can use rsync (with ssh as a transport, it should be availble in cygwin environment)
[edited by: Dainichi at 7:14 am (utc) on Nov. 8, 2006]