Location of bad blocks
Ulf Tropp
tropp at ce.chalmers.se.
Tue May 9 17:40:15 AEST 1989
In article <146 at wybbs.UUCP> voorst at wybbs.UUCP (Dale Van Voorst) writes:
>Does a program exist that will tell you what file, if any, a bad block is
>being used by, given one or all of the following: (head/cylinder/sector)?
>
Try icheck(8) and ncheck(8).
icheck -b blocknumber specialdevice
will propably give you the inode the block is owned by (or the free list).
ncheck -i inode specialdevice
will then give you the filename(s). Sometimes the inode(s) itself is
in a bad block. The information given by icheck is somewhat system specific.
If your vendor has decided that these commands are obsolete, since fsck(8)
is much better, you are out of luck. Blocknumber is of course
calculated from head/cyl/sec and the geometry of the disk, but
beware that the numbers reported may be relative to the beginning of the
disk, not the beginning of the file system.
There may be a program called fsdb(8?) on your system, but i know nothing
about that one.
This procedure works in v7 and BSD, so you have a chance.
Ulf Tropp, tropp at ce.chalmers.se
More information about the Comp.unix.wizards
mailing list