hdd clone issues

Posted by: oliver

hdd clone issues - 25/10/2007 13:19

I've been trying to clone a hard drive since last night on a laptop (windows xp, sata drive), I was going to do a fresh install and manually setup everything, but I figured a clone would be alot quicker (after about 5-6 hours, it wasn't, but I'd still like not manually setup the computer with apps/drivers/email, etc...)

I really really don't want to create an "image" which needs to be restored to the new drive (causing me to repartition the drive for space for the image, and having to delete and expand that partition after everything is all restored), I'd like to clone to a usb drive with the sata>usb adapter I have.

I tried Ghost 12, which is the worst program on the planet, it seemed to work, but windows would load the welcome screen that refuse to load the desktop (it can only do a clone while windows is running).

PING, which requires an image to be created first, then for it to be restored

HDclone which seemed to work, but I get the glorious NTLDR missing

and a handful other other programs which didn't support USB at all for the destination

So, my question, should I do this in ubuntu with dd? if so what would be the command, and both drives are NTFS.

or is there another program I'm missing?

or should I just try and repair the NTLDR?
Posted by: wfaulk

Re: hdd clone issues - 25/10/2007 14:16

cp /dev/hdq /dev/hdx

Where /dev/hdq is your source drive and /dev/hdx is your destination drive.

But you'll lose any additional space that the drive may have, and if it happens to be a few kB smaller, then it won't work "at all". (It'll sorta-kinda work, but you'll be left with a corrupted filesystem and I don't know how Windows will respond to that.)
Posted by: oliver

Re: hdd clone issues - 25/10/2007 14:58

source is 60gb, destination is 250gb... so i guess that won't work
Posted by: mlord

Re: hdd clone issues - 25/10/2007 15:30

Quote:
source is 60gb, destination is 250gb... so i guess that won't work


You can create a new partition to access the remainder of the space after copying.

Or you could then run the Ubuntu installer afterwards, and use it to resize the Windows partition to be larger, but not actually install Ubuntu (though I do highly recommend skipping the former and doing the latter ).

-ml
Posted by: drakino

Re: hdd clone issues - 25/10/2007 15:35

Beyond the Linux tools that can resize NTFS to then use up the rest of the disk, Microsoft also has Diskpart.exe that should do it. I've personally used the Linux tool qtparted many times to resize NTFS partitions up and down with no issues, and had several customers use Diskpart on SAN attached volumes to expand NTFS partitions.
Posted by: oliver

Re: hdd clone issues - 25/10/2007 20:27

Quote:
Quote:
source is 60gb, destination is 250gb... so i guess that won't work

Or you could then run the Ubuntu installer afterwards, and use it to resize the Windows partition to be larger


which tool would that be on the gutsy livecd? that's the route i'm going to go combined with cp /dev/hdq /dev/hdx
Posted by: oliver

Re: hdd clone issues - 25/10/2007 20:27

also, should the destination already be formatted as NTFS, or just a raw disk without any partitions?
Posted by: oliver

Re: hdd clone issues - 25/10/2007 21:14

cat /dev/sda /dev/sdb makes alot of noise, about 20 beeps at the same time over and over again from the motherboard speaker, anyway to stop this noise? i'll be crazy shortly...

also, i deleted the NTFS partition from the 250gb destination drive, hopefully that's how it should run....
Posted by: tman

Re: hdd clone issues - 25/10/2007 21:25

cp not cat. or cat /dev/sda > /dev/sdb

it shouldn't matter about deleting that partition or not. you're overwriting the entire disk anyway.
Posted by: oliver

Re: hdd clone issues - 25/10/2007 21:34

opps, noise is gone now... glad you posted that info
Posted by: oliver

Re: hdd clone issues - 26/10/2007 13:34

that was sooo easy, way easier than any of the other cloning utilities i tried. and it took about 1/4 of the time.

thanks guys!
Posted by: mlord

Re: hdd clone issues - 26/10/2007 13:36

Quote:
that was sooo easy, way easier than any of the other cloning utilities i tried. and it took about 1/4 of the time.


And the nice thing is, it's not even something that had to be created specially for "cloning". cp is just the ordinary everyday Linux "file copy" command.

And cat is another such ordinary command, which simply catenates a bunch of files together into a single output stream, which can then be directed to any destination using the > redirect operator.

Cute, eh!