[Liverpool] Migrating hard disks

Neil Bothwick neil at stfw.net
Mon Jan 19 13:13:58 UTC 2009


On Mon, 19 Jan 2009 11:31:27 +0000, Adrian McEwen wrote:

>  What's the easiest and quickest way to copy everything from the old
> drive to the new one?
>  I'm thinking of booting from a Knoppix CD with both drives connected
> up and then using "dd" to copy the contents of the old drive onto the
> new.  Is that sensible?  Anything I need to worry about other than the
> partition table?

It's one way of doing it,and it means you don't need to worry about the
partition table or bootloader, al you need to do is resize the last
partition and its filesystem afterwards. However, dd is incredibly slow,
although increasing the blocksize does help. The other disadvantage
is that if your original drive is fragmented,and if it's filling up
that's a real possibility, dd will copy over the fragmentation.

Like Andy, I'd go with rsync and a live CD for this. Partition the new
drive, rsync each filesystem then run grub to install the bootloader on
the new drive.

If downtime is an issue, do the partitioning and rsync while the system
is running (make sure you use rsync -x to avoid copying virtual
filesystems), then boot from the live CD, run rsync again with the
--delete option to make sure the partitions are exact copies, remove the
old drive, boot the live CD again to run grub, then reboot with your
finger crossed. That way the downtime is limited to not much more than
the time taken for two live CD reboots.


-- 
Neil Bothwick

"Do not handicap your children by making their lives easy."
 -- Robert Heinlein



More information about the Liverpool mailing list