Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Oct 2001 14:09:36 +0100 (CET)
From:      Alexander Leidinger <Alexander@Leidinger.net>
To:        ken@kdm.org
Cc:        scsi@FreeBSD.ORG
Subject:   Re: repeating medium errors and error from "camcontrol defects"
Message-ID:  <200110301309.f9UD9bD05779@Magelan.Leidinger.net>
In-Reply-To: <20011027160051.A66375@panzer.kdm.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 27 Okt, Kenneth D. Merry wrote:

>> > Then, write zeroes to the bad block to force the drive to remap it.
>> 
>> Is there a way to determine the file which is affected? I didn't want
>> just wrote zeros to it if I didn't know which file this affects. Maybe
>> I'm able to replace the file from a backup after or before overwritting
>> the block .
> 
> I don't know how you'd do that.  It's probably possible to dissect the
> filesystem information to figure it out, but I don't know how to do that.

I'm at least able to determine the partition which contains the bad
block: http://www.leidinger.net/FreeBSD/b2i.c

"b2i" means "block to inode", but this is misleading at the moment,
"b2p" (block to partition) or "bip" (block in partition) is the actual
semantic of b2i.c.

At the moment I try to squeeze some information (or pointers to docs)
about the on disk layout of FFS out of fs@freebsd.org. bde suggested to
just compare the files on the partition with the backup or just to read
every file on it and see which one produces errors (I'm going to do this
now), but I think a dedicated program which does the phys block ->
filename mapping needs less resources on a possible heavy loaded system.

Bye,
Alexander.

-- 
                   It's not a bug, it's tradition!

http://www.Leidinger.net                       Alexander @ Leidinger.net
  GPG fingerprint = C518 BC70 E67F 143F BE91  3365 79E2 9C60 B006 3FE7


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-scsi" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200110301309.f9UD9bD05779>