Wednesday, February 22, 2006

Backup/Restore on Linux

This is the commands to backup the whole disk and to restore it back.

dd if=/dev/hda1 bs=1k conv=sync,noerror gzip -c ssh -c blowfish user@hostname "dd of=filename.gz bs=1k"

dd if=filename.gz ssh -c blowfish root@deadhost "gunzip -c dd of=/dev/hda1 bs=1k"

The backup command is done from machine where the backup file is located, not from the target machine we want to restore to.

For more detail, see the following:

http://www.inference.phy.cam.ac.uk/saw27/notes/backup-hard-disk-partitions.html

No comments:

Post a Comment