PDA

View Full Version : 7 days to clone 250GB HDD - What am I doing wrong?



Highland
03-23-2005, 12:37 PM
Warning: Linux NEWBIE

I am attempting to clone my damaged external HDD (USB 2.0) to a new identical exernal HDD (USB 2.0) - both are 250Gb Maxtor ATA/133 7200RPM.

I started Knoppix CD Live in my laptop (Thinkpad P4M 2 Ghz). I switched to an X-Windows session and from the root@tty1[/]$ prompt I used the following command:

dd if=/dev/sdb of=/dev/sdc conv=noerror,sync bs=8k

The transfer rate was approximately 1.4Gb/Hr (The actual listed transfer rate was 368k/s). That is about 7.5 days to clone a 250Gb HDD. Can that be right??

I did have a number of I/O error messages listed as the transfer moved throught the HDD. At 5.2Gb transfered I closed the session.

I see from several posts and the http://www.knoppix.net/docs/index.php/ImageYourHardDriveUsingKnoppix article that the basic:

dd if=/dev/sdb of=/dev/sdc

command is recommended. Am I making a mistake by adding conv=noerror,sync bs=8k to the command? Should I increase the bs rate?

Sorry for such a stupid question. Any help will be MUCH appreciated!

Ken

.................................
Details:
Disk Information (Damaged HDD):
Manufacturer: Maxtor One Touch USB 2.0 / Firewire (External) HDD
Details: Size: 250Gb / Label: Maxtor / Filesystem: NTFS

Computer Information:
IBM Thinkpad R40 - Intel P4 2.4Ghz / 1Gb RAM / 40Gb HDD

Recovery Disk:
Maxtor DiamondMax 10 - ATA/133 16MB buffer - USB 2.0
Details: Size: 250Gb / Label: DiaMax / Fi

OErjan
03-23-2005, 05:23 PM
do you actually have 8K as a reasonable blocksize?? i doublt it. i would go with 512b it is a safe bet that can be shoehorned into most actuall blocksizes.
and YES it may take LoOooOooong time to do. a few days sounds WEIRD, a 40G hdd should take a good 2 hours.
BUT as the disc is DAMAGED it may be longer.

Highland
03-23-2005, 07:13 PM
OErjan,

Thanx. I am really a NEWBIE. I used the 8k setting because it was part of a How to article. I have no idea what the best size is/should be.

There are errors on the disk, but only a small percentage of the disk.

I will try a larger bs setting.

What happens if I use no bs setting?

Ken

OErjan
03-24-2005, 07:42 AM
WHAT? what do you mean "larger", 512b (b as in byte) is much SMALLER than 8K, as 8K =8192b.
if you give NO bs it deafults to bit by bit iirc.
that may actually be a BETTER option for you, as it wil copy EVERYTHING from your drive.
just a few more questions.
why do you not just copy what you can the normal way from disk to disk?
a two reasons i can think of (there are LOADS more)
you need to have the "clone" bootable
you need to make forensic work on it (meaning do you have to recover broken files)
just being curious.
you see, using dd will actually copy the faulty bits aswell as the good ones as exactly as possible.

Highland
03-24-2005, 10:45 AM
Sorry, I misread 512b as 512k.

I would be happy to copy "disk to disk" just a few directories only, most of the drive is backed-up to CDs. I presume that I have lost some data in the faulty sections of the drive.

The problem is I don't know what commands to use to copy the directories. I don't know any Linux commands! I think I may have to mount the new drive??? I have tried the cp /dev/sda1/'directory name' /dev/sdb1 command, but I get the cannot stat message. There are spaces in the directory names too.

If anyone could give me a basic 1,2,3 set of commands to copy directories, it would be much apprecated. I just don't know Linux.

Ken

OErjan
03-24-2005, 02:01 PM
ah, can you use kde? or is it shell only?
in console i use would use

cp -afx "/path/to/dir/with/split Name" /path/to/new/directory
that is use " " to show bash that it ia ONE SINGLE PATH. otherwise it tries to copy the files to a dir called name.
the -a means copy files under this directory recursively (everything under this point), preserve the names... as well as it can be done, preserve filepermissions and atributes as well as can be done (we are still refering to first option, a )
f means force copy even if not sound, x only in this same filesystem, in other words, do not copy folowing links to another partition, disk...
it may be a few "bad" files but most should be ok, atleast if the original is ok.

or use konqueror as root (if you are in a Xwindow environment)

sudo konqueror&

OErjan
03-24-2005, 02:29 PM
by the way, if you want a "crash course" in linux comandline http://floppix.com/labs.html is a good place to start.
98% of what is there goes for most linux distributions.
i always reccomend it as a good way to get well aquainted with linux in a no nonsence way. ofcource it may be somewhat "thin" on explanations and not verry in depth, on the other hand there is not much "fat" to trim, just "bare essentials".

Highland
03-24-2005, 03:28 PM
OErjan

Thank you!! I am trying it now. The "crash course" link looks very useful.

Ken

OErjan
03-24-2005, 03:53 PM
just another thing, you copy as root right? if not you might find that you do not have permissions to some files...