From owner-freebsd-scsi@FreeBSD.ORG Wed Jan 14 14:56:48 2009 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D4BC1106578B for ; Wed, 14 Jan 2009 14:56:48 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.freebsd.org (Postfix) with ESMTP id 6AF088FC18 for ; Wed, 14 Jan 2009 14:56:48 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from phobos.local ([192.168.254.200]) (authenticated bits=0) by pooker.samsco.org (8.14.2/8.14.2) with ESMTP id n0EEZfWS096908; Wed, 14 Jan 2009 07:35:41 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <496DF83D.4090904@samsco.org> Date: Wed, 14 Jan 2009 07:35:41 -0700 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.13) Gecko/20080313 SeaMonkey/1.1.9 MIME-Version: 1.0 To: Wes Morgan References: In-Reply-To: X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=3.8 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.1.8 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on pooker.samsco.org Cc: freebsd-scsi@freebsd.org Subject: Re: SMART status of SATA drives on SAS controller X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jan 2009 14:56:50 -0000 A tweak is needed to smartctl to make this work. See below. FreeBSD needs to become more aware of the ATA Passthrough feature of SCSI, but for now this patch with let smartctl work correctly. --- os_freebsd.cpp.orig 2008-03-04 15:09:47.000000000 -0700 +++ os_freebsd.cpp 2008-09-23 09:43:01.000000000 -0600 @@ -525,7 +524,7 @@ return -1; } - if ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) { + if (((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) && ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_SCSI_STATUS_ERROR)) { #if __FreeBSD_version > 500000 cam_error_print(cam_dev,ccb,CAM_ESF_ALL,CAM_EPF_ALL,stderr); #endif Scott Wes Morgan wrote: > I've got 8 SATA2 drives in an zfs raidz2 on an LSI controller (1068 I > believe, mpt driver), and one of them seems to be acting strangely. I'd > like to get the smart status without pulling it out of the array and > dropping it onto an ATA controller, but I don't seem to be able to for > any of the drives. Using the device type as both "SAT" and "SCSI", > neither will successfully show the full output. Is there any way around > this? Error below... > > > === START OF INFORMATION SECTION === > Device Model: WDC WD5002ABYS-01B1B0 > Serial Number: WD-WCASY3240847 > Firmware Version: 02.03B02 > User Capacity: 500,107,862,016 bytes > Device is: Not in smartctl database [for details use: -P showall] > ATA Version is: 8 > ATA Standard is: Exact ATA specification draft version not indicated > Local Time is: Wed Jan 14 06:14:18 2009 CST > SMART support is: Available - device has SMART capability. > SMART support is: Enabled > > === START OF ENABLE/DISABLE COMMANDS SECTION === > SMART Enabled. > (pass4:mpt0:0:4:0): ATA COMMAND PASS THROUGH(16). CDB: 85 6 2c 0 da 0 0 > 0 0 0 4f 0 c2 0 b0 0 > (pass4:mpt0:0:4:0): CAM Status: SCSI Status Error > (pass4:mpt0:0:4:0): SCSI Status: Check Condition > (pass4:mpt0:0:4:0): RECOVERED ERROR asc:0,1d > (pass4:mpt0:0:4:0): ATA pass through information available > SMART Disabled. Use option -s with argument 'on' to enable it. > _______________________________________________ > freebsd-scsi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-scsi > To unsubscribe, send any mail to "freebsd-scsi-unsubscribe@freebsd.org"