<div dir="ltr">I'm trying to figure out how to probe smart statistics reliably for SATA drives behind a SAS expander. I've installed the omni-ms version of smartmontools, and it appears to work, with a few caveats. <div>
<br></div><div>If I run with -d sat,12 (as esproul suggested in IRC), it looks like I get full information back from the drive, but the soft errors and recoverable errors counts get incremented. I also get this message in the ring buffer:</div>
<div><div>Sep 11 23:35:15 v3 scsi: [ID 107833 kern.warning] WARNING: /scsi_vhci/disk@g5000cca369e606ce (sd79):</div><div>Sep 11 23:35:15 v3      Error for Command: <undecoded cmd 0xa1>    Error Level: Recovered</div>
<div>Sep 11 23:35:15 v3 scsi: [ID 107833 kern.notice]        Requested Block: 0                         Error Block: 0</div><div>Sep 11 23:35:15 v3 scsi: [ID 107833 kern.notice]        Vendor: ATA                                Serial Number:       MN3220</div>
<div>Sep 11 23:35:15 v3 scsi: [ID 107833 kern.notice]        Sense Key: Soft_Error</div><div>Sep 11 23:35:15 v3 scsi: [ID 107833 kern.notice]        ASC: 0x0 (<vendor unique code 0x0>), ASCQ: 0x1d, FRU: 0x0</div></div>
<div><br></div><div>If I run with -d scsi, a subset of the smart information is reported, and the illegal request counter gets incremented. </div><div><br></div><div>It looks like the scsi_vhci driver gets upset in two different ways, depending on how smartctl is called. In the former case it gets an unexpected message, and in the latter, it thinks the smart request is an illegal request. </div>
<div><br>So, from cursory digging into the code, it appears that the common scsi layer doesn't know how to decode this command, and that is what is causing the ruckus. It the solution just a matter of adding:</div><div>
0xa1 0x0 "SAT SMART Data"</div><div>to extended_sense_list[] in usr/src/uts/common/io/scsi/impl/scsi_subr.c ?</div><div><br></div><div>I'm not sure if I'm reading the error message correctly or not. Is this basically the right thing to do?</div>
<div>thanks.</div><div> -nld</div></div>