0

From time to time I have HDDs and microSD cards which have bad sectors.

I realized that all photorec, (ext/ntfs/...)undelete and dd fail or are incredible slow.

Other users seem to have the same problem with other tools (in this particular post Clonezilla and EaseUS Disk Copy Pro).

The reason is all those tools fail when there is a bad sector at all or they try to read bad sectors many times instead of trying it only 1 or 2 times. If a tool tries to read a bad sector many times it may take days for the tool to finish.

I have written my own script which creates a disk image and it replaces bad sectors by zeroes. After that I can run any recovery tool I like on it with no problems. (I read the image from the damaged disk and store it as a file on a healthy disk.)

Is it possible to do the same on the Linux command line using common Linux commands?

After two failed reads a bad sector should be replaced by zeroes in the image. Also the buffer size (similar to dd's bs option) should be big enough to get max. read/write performance.

zomega
  • 972

0 Answers0