On 12Sep2018 08:35, Cameron Simpson <cs@xxxxxxxxxx> wrote:
On 11Sep2018 15:11, Ranjan Maitra <maitra@xxxxxxxxx> wrote:
There is also xfs_repair: will this utility find the affected files?
Short answer: I don't actually know. It may be more useful to run it
against the bad drive because if those blocks are file data blocks
then on the bad drive it _may_ register them as bad and report; on the
new drive they may just look like blocks of zero bytes because
ddrescue will have filled them in.
However, you _also_ need to run it against the new drive, because if
the bad blocks were filesystem structure black (as opposed to file data
blocks) then your filesystem will be corrupt anyway.
Just to followup to this, xfs_repair(8) has this interesting paragraph:
Disk Errors
xfs_repair aborts on most disk I/O errors. Therefore, if you are trying
to repair a filesystem that was damaged due to a disk drive failure,
steps should be taken to ensure that all blocks in the filesystem are
readable and writable before attempting to use xfs_repair to repair the
filesystem. A possible method is using dd(8) to copy the data onto a
good disk.
So it may abort on your old drive. I suspect that if it completes on the old
drive that just means it didn't access any bad sectors. That may not mean the
copies on the good drive are good if their _data_ sectors were bad (and filled
with zeroes by dd_rescue).
You definitely need to run it against the good drive as well.
Cheers,
Cameron Simpson <cs@xxxxxxxxxx>
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx