Quote:
There may have been some problems with the dd copy anyway, given that the disk wasn't quiesced during the cloning process.
|
Exactly! You are unlikely to make a successful image if the disk is in use (and therefore the bit/byte-level data is changing = can lead to inconsistencies & chaos).
If you want to try
dd again, boot from a live cd, and do the work from there, whilst the partition you are interested in is unchanging.
If you want to use
rsync, then by all means use that, but again, it's better to sync a disk that is not being used - ie either run
rsync from a live CD, or make sure you have a free partition on your main disk with a simple linux installation just for "housekeeping" the important partitions (which may be on different hdds). I do the latter because it is faster than running from a live CD, and it is always there on my boot menu in case of an "Oops!". If the "Oops" is so bad that I cannot boot to my rescue partition, I know I can boot from a (slower) live CD, and retrieve my data and OS, to a new hdd if necessary.
The big advantage of
rsync is that after the first copy, subsequent syncs are very fast as only the
differences between the two filesystems are corrected. You need to be very careful with the options to
rsync though! I'll leave you to experiment, with this one
warning:
You need a real test of your backup strategy:
Once you
think you have a backup, pretend you have lost your data (eg take out the primary disk). Now, can you get your data / OS back?
18y ago I installed and set up a big Oracle database under SCO unix. It was stable, it ran fine it was gooood. I thought I had the (tape) backup strategy well & truly fixed, until we
really needed to restore from tape after a power failure (yes, we had UPSs & generators & stuff, but there was a sufficient glitch to hose the system).
Only then did I realise that I had done it stupidly and it did not work as I expected it to. Two hours of panic later, I had resolved the issue, but I wished I had had the sense to
test my backup strategy before it was needed! This doesn't mean "Can I see my backup files?", it means "Can I get my system running again without having to peek at my (supposedly failed) disk?"
So, my strategy is this:
When I think it's time for a backup (actually I think it's time after I finish this post!), I boot to my backup-distro, where I have a script to mount the partitions I need to backup and then
rsync them to an external disk. Then I'm done
Unless the external disk fails
Unlikely, but
possible.
I wish I knew the backup strategy of banks / airlines etc. How do they keep their systems up and running 99.9999% of the time? They cannot just say "System going down for 10Hrs for a backup!". I think it is a complex field (and I am not an IT expert!).
Good luck with your experiments & eventual strategy.