Finding the file that is on a bad block on a HFS+ volume (debugfs for HFS+)

Posted by Blair Zajac on Super User See other posts from Super User or by Blair Zajac
Published on 2012-01-15T07:13:10Z Indexed on 2012/04/04 23:33 UTC
Read the original article Hit count: 282

Filed under:
|
|
|
|

I have a drive in our iMac that has bad blocks, as booting from an Ubuntu 11.10 live CD and using ddrescue -f /dev/sda /dev/null finds them. I'd like to get the drive to remap them by writing to the blocks, say using hdparm --write-sector, but I don't want to do this without knowing what's in those blocks and finding the file that owns them, so I can restore the file from another source.

I found fileXray but don't feel like spending $79 to map a block to a file and hfsdebug has been taken offline. Are there suggestions on a tool or technique to use?

I looked at all the Ubuntu HFS+ packages to see if they could provide this info but nothing jumped out at me.

BTW, I used Disk Utility to erase the empty space, but it didn't get any of the bad blocks to be remapped, according to smartctl -A.

© Super User or respective owner

Related posts about osx

Related posts about mac