Ray Arachelian wrote:
First fill the empty space on it with zeros, remove
the file with the
zeros, unmount it, then dd the whole disk, and pipe it to gzip.
Usual warnings about compressing anything that's a 'critical' archive
presumably apply (I'm not sure how good gzip is at recovering from errors, but
most compression schemes seem pretty bad)
Sadly I'm drowning in raw disk backups here because software and/or OS media
to allow "proper" backups for various systems has long gone :-(
Incidentally, I've had some successes in the past in migrating 'alien' OS
installs from failing drives to new ones via raw data copies; often the OS
doesn't care if a raw backup is restored onto a larger disk - it'll just see
lots of wasted space at the end of the drive. Some OSes will record drive
geometry somewhere in their partition data structures though, and may rely on
it at some stage, so:
a) If the system's in a runnable state, search for any info you can find on
the disk layout (gleaned from man pages for the format/partitioning programs,
C header files etc.) and keep them in plain text outside of the raw drive backup.
b) Make sure you have a note at least of the drive make / model, and
preferably any info you can find on geometry, transfer times etc.
... that way if the drive does go bang you aren't left scratching around for
an identical replacement. It's also useful knowing the partition format in
case you might want to try mounting the filesystem(s) on a more modern system
at some point (e.g. dd the raw partition out of the drive image and mount it
as a filesystem using a loopback device under linux)
dd if=/dev/dsk/c0t1d0s2
Worth having conv=noerror,sync in there too, just in case the disk is getting
a little tired. Actually, sometimes subsequent re-reads will be successful for
bad blocks - I've hacked together scripts before that auto-retry failed
blocks several times just to see if the source drive can eventually be coaxed
into supplying data.
Oh, some systems store data on disk in byte-swapped order (my NCR tower's
one). Not relevant for a raw backup / restore, but it's just a gotcha to look
out for if you want to try interpreting data on a modern system (or even just
browsing in a hex / text editor)
cheers
Jules