Discussion Forums > Technology

Question - Using dd to clone different sized disks?

<< < (2/3) > >>

Freedom Kira:

--- Quote from: toaow on May 05, 2011, 10:27:04 PM ---Did he reboot to the LiveCD in between the dd operation and attempting to resize? Trying to do it from GParted after booting from the hard disk won't work. You have to reboot from a LiveCD and NOT mount any partitions, then run GParted.

--- End quote ---

Ah, I believe he did. In that case, wouldn't unmounting the drive and all partitions be sufficient?


--- Quote from: bork on May 06, 2011, 01:27:02 AM ---I have never used dd to clone my boot drive, used a script that mount the partitions on both existing drive and the new drive while in single user and runs dump to move.  If interested, I can provide more details. 

--- End quote ---

If I understand correctly, this does a simple data copy of all the data existing on the drive. It doesn't copy partition tables or MBR, which would mean he would have ended up with a drive that contained all the data except for how to boot. Which doesn't make for a very useful boot drive...

toaow:

--- Quote from: Freedom Kira on May 06, 2011, 04:16:03 AM ---
--- Quote from: toaow on May 05, 2011, 10:27:04 PM ---Did he reboot to the LiveCD in between the dd operation and attempting to resize? Trying to do it from GParted after booting from the hard disk won't work. You have to reboot from a LiveCD and NOT mount any partitions, then run GParted.

--- End quote ---

Ah, I believe he did. In that case, wouldn't unmounting the drive and all partitions be sufficient?


--- End quote ---

It should be. IF all partitions were unmounted and GParted didn't allow a resize, then there's a problem with MBR, or the partition table, or the partition is marked as in use for some reason. Unmount the partition, and run fsck -f on it, then reboot with the LiveCD.

Some older BIOSes don't recognize disks above a certain size, that isn't the case here, is it? You'd know by going to the BIOS setup screen and seeing if it recognized the full size of the disk in question.

kureshii:
Stupid question, but has he already resized and moved the swap partition? Can't overwrite an existing partition after all... also, some clue from the error message would be nice.

Might also be worth noting that GParted needs root privileges to carry out some tasks. App launcher is probably running it as user; try "gksu gparted" from a terminal window.

billlanam:
You could first delete the swap partition, then try to resize the your main partition, and then create a new swap partition.
All this while booted from the livecd, without any of the hard drive's partitions being mounted.
You might have to edit the fstab file in order to use the swap partition again.

Freedom Kira:
Here's a reply from him.


--- Quote from: Coworker ---I used the livecd of gparted too - different cd so had to reboot. Actually tried a couple of times, and it did let me format the remaining 50g.
I'm pretty sure gparted was running as root because I change the privileges on the new 50g from root to myself.

I should probably try the delete - resize - recreate suggestion...

--- End quote ---


--- Quote from: toaow on May 06, 2011, 04:49:33 AM ---Some older BIOSes don't recognize disks above a certain size, that isn't the case here, is it? You'd know by going to the BIOS setup screen and seeing if it recognized the full size of the disk in question.

--- End quote ---

Can't be. It's only 50GB more than what he used to use. And the 50GB shows up in the OS.


--- Quote from: kureshii on May 06, 2011, 05:13:12 AM ---Stupid question, but has he already resized and moved the swap partition? Can't overwrite an existing partition after all... also, some clue from the error message would be nice.

Might also be worth noting that GParted needs root privileges to carry out some tasks. App launcher is probably running it as user; try "gksu gparted" from a terminal window.

--- End quote ---

That stupid question might just be the case... >.>
Gotta hate it when those "did you turn on the printer?" questions actually give you the solution.

Also, from my experience, GParted doesn't let you run it as user. IIRC, whenever I try to run it from System -> Administrative Tools/Administration/whatever, it always asks me to login as root before I can continue.


--- Quote from: billlanam on May 06, 2011, 05:39:26 AM ---You could first delete the swap partition, then try to resize the your main partition, and then create a new swap partition.
All this while booted from the livecd, without any of the hard drive's partitions being mounted.
You might have to edit the fstab file in order to use the swap partition again.

--- End quote ---

That's most likely the solution we all have in mind.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version