Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 24 Apr 2001 15:08:03 -0600
From:      "Kenneth D. Merry" <ken@kdm.org>
To:        Todd Cohen <cohentl@clarkson.edu>
Cc:        freebsd-scsi@FreeBSD.ORG
Subject:   Re: is this device bad?
Message-ID:  <20010424150803.A1146@panzer.kdm.org>
In-Reply-To: <Pine.GSO.4.10.10104241500090.19100-100000@isis.aoc.clarkson.edu>; from cohentl@clarkson.edu on Tue, Apr 24, 2001 at 03:00:20PM -0400
References:  <20010424125534.A557@panzer.kdm.org> <Pine.GSO.4.10.10104241500090.19100-100000@isis.aoc.clarkson.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
[ reply moved to the bottom ]

On Tue, Apr 24, 2001 at 15:00:20 -0400, Todd Cohen wrote:
> On Tue, 24 Apr 2001, Kenneth D. Merry wrote:
> > On Tue, Apr 24, 2001 at 14:44:02 -0400, Todd Cohen wrote:
> > > I ran that command... it sat at "Fromatting..." for about 20-30 minutes or
> > > so.. then had the following error:
> > > 
> > > lizard# camcontrol format da1 -v -w
> > > You are about to REMOVE ALL DATA from the following device:
> > > pass1: <SEAGATE ST410800N 7114> Fixed Direct Access SCSI-2 device
> > > pass1: Serial Number 00337771
> > > pass1: 10.000MB/s transfers (10.000MHz, offset 8)
> > > Are you SURE you want to do this? (yes/no) yes
> > > Current format timeout is 10800 seconds
> > > Enter new timeout in seconds or press
> > > return to keep the current timeout [10800]
> > > Formatting...camcontrol: error sending format command
> > > CAM status is 0xb
> > > lizard#                                                  
> > 
> > That's a command timeout, but the timeout was set to 3 hours, not 20-30
> > minutes.  Was there anything in the dmesg after camcontrol returned?
> > 
> (da0:sym0:0:0:0): READ(06). CDB: 8 1f 4e 46 2 0 
> (da0:sym0:0:0:0): MEDIUM ERROR info:1f4e47 asc:11,0
> (da0:sym0:0:0:0): Unrecovered read error
> (da0:sym0:0:0:0): READ(06). CDB: 8 1f 60 10 10 0 
> (da0:sym0:0:0:0): MEDIUM ERROR info:1f6017 asc:11,0
> (da0:sym0:0:0:0): Unrecovered read error
> sym0:4:control msgout: 80 6.

Isn't the drive you're trying to talk to da1?

The last message is the one that might pertain to da1, but I'm not sure
what that means.  You'll have to ask Gerard what that means, and then we
can perhaps figure out why the disk is timing out.

Another potential problem is the timeout length may be overflowing a 32-bit
integer.

IIRC, HZ on the alpha is 1000.  The sym(4) driver uses the following to
calculate the timeout:

        ccb->ccb_h.timeout_ch = timeout(sym_timeout, (caddr_t) ccb,
                                       ccb->ccb_h.timeout*hz/1000);

So with a timeout of 10800 seconds, or 10,800,000 ms, multiplied by hz,
which is likely 1000 on the alpha, you would overflow a 32-bit integer.

So try a timeout of 4200 seconds instead, and see if that works.  That's 70
minutes, but it might be enough for the format to complete.

If not, we'll have to adjust the above calculation to use 64-bit math so it
won't overflow.

Ken
-- 
Kenneth Merry
ken@kdm.org

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?20010424150803.A1146>