How to move installation to a new Hard Drive?
I need to move my installation from two separate HDs to a single HD. The new drive is a different size and partition setup from the other two drives. The two originating drives, we'll call them hda and hdb each hold multiple partitions. I need only one partition from each. They will go on to a target partition, sde. So how do I get hda2 (bootable system) and hdb3 (data) onto sde1 and sde3 respectively?
#rsync -av /media/hda2 /media/sde1
#rsync -av /media/hdb3 /media/sde3
But for some reason, the target size ends up being larger than the source size.
so I did a
#dd if=/dev/hdb3 of=/dev/sde3 conv=noerror,sync
hdb3 is larger than sde3 even though the data contained in hdb3 is much smaller than the size of sde3, dd totally messed up the partition table of sde. So I've repartitioned with gparted and I'm ready to take another swing at it.
I also realize that I'll have a little editing to do to the fstab and a few other files on the new drive (sde1), and reinstalling grub, before it will boot.
So, to sum up, I'd like to take a partition from hda (ubuntu) and a partition from hdb (mythtv data), and migrate them seamlessly to sde into a bootable working system.
Need more details?
hda2 is a bootable ubuntu system with Mythtv installed, using the partition on hdb3 to store it's files. I've been using it as a multi-purpose system. I now have enough parts to build a second system, and dedicate one to Mythtv and one to a 64 bit linux playground.
I need to move the mythtv-ready ubuntu to sde1 and move 160GB of mythtv data files to sde3 (sde2 is a swap partition)
hda2 is 15GB with 9GB of data
hdb3 is 280GB with 116GB of data
sde1 is 10GB
sde3 is 200GB
All of the other hardware will be the same.
Thanks in advance!