Samstag, 25. Juni 2011

Hard Disk backup / mirroring with Ubuntu and dd

In this post I will show you how to mirror  your hard disk with Ubuntu and the dd command. I used this method to backup the data from my laptop, which didn't start anymore. I was sure the hard disk was still alive and i wanted to save all my data.

You will need a s-ATA to USB cable like this one
At first you've got to make sure both hard disks are connected to the PC.
In my case /dev/sdc is the source and /dev/sdd is the target hard disk.


Use this command to mirror the whole hard disk, bit per bit.

pv /dev/sdc | dd bs=128k of=/dev/sdd
Where /dev/sdc is the source- and /dev/sdd is the target-hard-disk!

The dd command copies the hard disk bit per bit and the pv command adds a neat progress bar, because by default dd comes with no visual feedback.


For me it took like 3 hours to mirror all the data to my new USB-hard-disk.

1 Kommentare:

Unknown hat gesagt…

Nice info. Thanks you for going to my blog ;)

Kommentar veröffentlichen