Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 23 Dec 2000 23:15:13 -0800
From:      "Jake Khuon" <khuon@GBLX.Net>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        Jake Khuon <khuon@GBLX.Net>, freebsd-hardware@FreeBSD.ORG, sos@FreeBSD.ORG
Subject:   Re: fixing hard read errors 
Message-ID:  <200012240715.eBO7FDA10056@Espresso.NEEBU.Net>
In-Reply-To: Bruce Evans's message of Sun, 24 Dec 2000 16:42:42 %2B1100. <Pine.BSF.4.21.0012241625010.8602-100000@besplex.bde.org> 

next in thread | previous in thread | raw e-mail | index | archive | help
### On Sun, 24 Dec 2000 16:42:42 +1100 (EST), Bruce Evans <bde@zeta.org.au>
### casually decided to expound upon Jake Khuon <khuon@GBLX.Net> the
### following thoughts about "Re: fixing hard read errors":

BE> On Thu, 21 Dec 2000, Jake Khuon wrote:
BE> 
BE> > I've started taking corruption errors on the drive.
BE> > 
BE> > Dec 20 23:37:50 Mocha /kernel: ad0: HARD READ ERROR blk# 19527354
BE> > Dec 20 23:37:56 Mocha /kernel: ad0: HARD READ ERROR blk# 19527354 status=59
BE> > error=40
BE> > Dec 20 23:37:57 Mocha /kernel: ad0: DMA problem fallback to PIO mode
BE> > 
BE> > Right now, I've had to set the fsck flag to 0 in /etc/fs and am doing a
BE> > forcemount of /usr in /etc/rc before the other mounts just to keep me going.
BE> > 
BE> > Is there a way to use badsect to map these out?  When I try, I get this:
BE> > 
BE> > badsect /usr/BAD 19527354
BE> > block 19527354 out of range of file system
BE> > Don't forget to run ``fsck /dev/rad0s2f''
BE> 
BE> The block number printed by the ad driver is relative to the start of the
BE> disk, but the block number for badsect must be relative to the start of
BE> the filesystem (ad0s2f).

So should I just subtract the offset for ad0s2f from 19527354 or do I have
to convert the offset to something first based on the blocksize of the file
system?


BE> Disk drivers should use the standard function for reporting disk errors
BE> (diskerr()) so that more information, including the filesystem-relative
BE> block number, is printed.  From subr_disklabel.c:
BE> ---
BE> /*
BE>  * Disk error is the preface to plaintive error messages
BE>  * about failing disk transfers.  It prints messages of the form
BE> 
BE> hp0g: hard error reading fsbn 12345 of 12344-12347 (hp0 bn %d cn %d tn %d sn %d)

Yeah... wouldn't that be nice. |8^)


--
/*====================[ Jake Khuon <khuon@GBLX.Net> ]======================+
 | Senior Manager and Chief Architect, Net-Eng/NSM     /~_ |_ () |3 /-\ |_ |
 | VOX: +1 (408) 543-4828  Fax: +1 (408) 543-0074      \_| C R O S S I N G |
 +===============[ 960 Hamlin Court, Sunnyvale, CA   94089 ]===============*/




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




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