Resource icon

Advanced Guide to ddrescue

Technibble Support

Administrator
Staff member
Reaction score
5
Technibble Support submitted a new resource:

Guide to Using DDRescue to Recover Data - This guide is intended for people who are looking to do quality data recovery using free tools.

It seems that a guide for using ddrescue might be of some benefit to many members who may be shy of the linux terminal. So, I’ve decided to document some real-world examples from in the shop. I plan on doing this in 3 parts to cover the most common scenarios.

Part 1: Creating an image from a failing disk
Part 2: Restoring an image to a new disk & cloning directly to a new disk
Part 3: Working with the image files

In will be using...

Read more about this resource...
 
Great article, much appreciated.

I know that this question will be a bit of topic but I've had no luck performing pm's hdd tests on external 2.5's via usb
I've tried a few different brands
what could I use to check their health when pm doesn't perform?
 
Also for ddrescue what do you do if it can't read superblocks?
ddrescue reads at the sector level. If superblocks are in bad sectors, you will need to keep re-reading those sectors until the drive reads them (if possible) or have to recover the file system manually or with data recovery software against the clone afterwards.
 
When running ddrescue from a live CD, you have no persistent storage – everything is lost on a reboot. Consider mounting a USB thumb drive to hold the ddrescue log file, then you're not committed to doing everything in a single session.
 
You'll always get better results from directly connecting the drive to a motherboard port. USB often gets in the way of less-used commands.
Yeah I understand, but that means disassembling the external costing more time and effort and also theres drives that do not have a detachable USB 3 interface so not always possible to bypass USB
 
Silverleaf, I got to this forum through your guide after suffering the "unmountable boot drive" startup problem on Windows 10. After all Windows-based solutions to get rebooted (without wiping out the drive with a re-install and having to re-install all my programs) failed Google lead me to the amazing world of Linux where I have learned how to create an Unbuntu Live USB, see all my files and create a whole image of my hard drive on a USB external drive using this ddrescue and this Guide.

What was not clear to me at the end was exactly what to do next to take another whack at getting my windows 10 working again using that image. You talked about "mounting" and "unmounting" the image and copying files. What files? From where to where?
 
Great resource. Nice tutorial. I use GNU ddrescue a lot on my disks for years and this a really good tutorial for those who are not familiarized with the tool. I would add one useful tip: If your disk is giving you errors or you have issues reading some blocks, It's advisable to run the same command, starting from the very end of the disk, in backwards (with the -R flag); using the mapfile of the first command obviously. I got some really good results in the past doing it (slower but more efficient).

PS. In fact, I am running GNU ddrescue right now in backwards (on one bad disk. It is taking too much time this time, so I am gonna flip some parameters :D.
 
Last edited:
Great resource. Nice tutorial. I use GNU ddrescue a lot on my disks for years and this a really good tutorial for those who are not familiarized with the tool. I would add one useful tip: If your disk is giving you errors or you have issues reading some blocks, It's advisable to run the same command, starting from the very end of the disk, in backwards (with the -R flag); using the mapfile of the first command obviously. I got some really good results in the past doing it (slower but more efficient).

PS. In fact, I am running GNU ddrescue right now in backwards (on one bad disk. It is taking too much time this time, so I am gonna flip some parameters :D.

Would you mind giving us an example of the command line to do this? TIA
 
Would you mind giving us an example of the command line to do this? TIA

Yeah sure. If you are imaging (generating an Image file of the damaged disk), for a first sweep I'll would do:

ddrescue -R -n /dev/SOURCEDISK image.img mapfile.log //Jump all the bad areas and read backwards

Note: And if you are cloning (copy the content directly to another healthy disk):
ddrescue -R -n -f /dev/SOURCEDISK /dev/DESTINATIONDISK mapfile.log


Then, for the second sweep you can do what the guide says and try to scratch some data from the bad areas:

ddrescue -d -R -r3 /dev/SOURCEDISK image.img mapfile.log

Note: if it takes a lot of time (months) try one only pass ("r1") and see if you get some info that way, so you save some time. If not, then try more passes.

Is quite more slower to read backwards, but it has the advantage that if your disk has lots of bad areas at the beginning, starting from the very end of the disk, jumps those problems and can help you to recover lot of data before you get to the problem. Also, many times if you have problems reading some sectors or your disk's heap is doing something strange... reading backwards get better results. As a rule of thumb, if your disk doesn't has to much damage and you are getting the data nicely you can go with the forwards/normal way but somethings doing things like don't use kernel's cache (-d) and read backwards (-R) get better results.

I hope you find this useful.
 
Back
Top