Question re. hard read errors

Richard Johnson raj at cisco.com
Thu Aug 7 16:34:07 PDT 2003


I have a 1.5Gb file stored on a FreeBSD 4.8 disk drive and the system 
is giving me hard read errors when I try reading it.  It appears as 
though this disk has a few bad blocks. :(   Unfortunately, it's a 
compressed tar file and I (stupidly!) erased the file from the original 
computer before untar'ing it here and finding the errors!  I'd like to 
recover as much as possible of this file before writing off the entire 
thing.

I looked at /usr/src/sys/dev/ata/ata-disk.c and found the retry count 
was set to 3.  I changed it to 10.  After the first error (which is, 
indeed, reported 10 times) the system reports that it's going into PIO 
mode and I still hear the same amount of hammering on the drive after 
that and only one error message produced.

Is there some way I can force the system to retry 10 or more times for 
each and every block?  Maybe there's some other utility I can use which 
tries harder to read the blocks?

ANY pointers to information would be greatly appreciated.

/raj




More information about the freebsd-questions mailing list