Sunday, July 8, 2012

Recover data from failing drive.

I have used dd in the past, but dd is intelligent when copying data from a failing disk. What you want is some software that intelligently copies byte data from different part of the drive not to stick in a failing area.

ddrescue to the rescue! (phun intended). ddrescue covers all of the above and is available via
apt-get install gddrescue
(There is another software called dd_rescue, but this has largely been superseded by GNU ddrescue).

Just fire up ddrescue with infile and outfile, I'll use a logfile as well since I don't want it to try previously read sectors from a failing drive.

ddrescue /dev/sdX failingdrive.img failingdrive.log

And that's it!

When people have a failing drive they usually prioritize images for recovery, and for that we can use the splendid tool photorec. Photorecovery can work directly on a drive or file, but since I'm trying to be as gentle as possible with the failing drive I rather use it on my drive image. I'll use a logfile here to for resuming recovery and specifying a directory for the recovered images:

photorec /log failing-photos.log /d ~/recovered_images failingdrive.img

After that you will have to select which partition to search for images, or just specify the whole drive and search. Use apt-get install photorec to install.



  1. I really like your this work hope so every one who visit this page too share his comments. Thanks for share this.
    access 1337x in UK

  2. Thanks for your information, it was really very helpfull.. recover deleted files from USB

  3. These articles and blogs are genuinely sufficiency for me for a day.recover my files

  4. I think this is an informative post and it is very useful and knowledgeable. therefore, I would like to thank you for the efforts you have made in writing this article. odzyskiwanie danych z uszkodzonego telefonu