Glossary

SCSI Status Codes

The SCSI Status Code is what comes back from the SCSI target at the end of every command, and sometimes before the command completes.  It informs the SCSI initiator if the command worked (successful) or didn’t work (unsuccessful).

Here is a list of the status codes and what they mean.  By the way, the small “h” behind each code means we are using hexadecimal (hex – base 16) notation.

00h – Good Status. The device server has successfully completed the task (command).

02h – Check Condition Status. This indicates that Sense Data is available and that a Contingent Allegiance Condition (CAC) may exits.  A CAC usually means that some kind of error has occurred.

04h – Condition Met. This code is returned for unlinked conditional commands, such as PREFETCH.  This means the command was successful.

08h – Busy. This means the device (logical unit) can not accept a command right now.  This condition is temporary and the command should be tried again.

10h – Intermediate. This is the same as a Good status (00h), except it is returned from a command that was part of a series of linked commands.  The last command in the series cannot have this status.

14h – Intermediate-Condition Met. Combination of 04h and 10h codes (see above).

18h – Reservation Conflict. The device or element is Busy because a reservation is in place.  Think of this as “Busy, because I am reserved”.)

22h – Command Terminated. This status code is now obsolete, but it was the result of a Terminate I/O Process message (that message is also obsolete).

28h – Task Set Full (was Queue Full). The Command Queue (task set) is full. You can think of this as “Busy, because my queue is full”.

30h – ACA Active. This code means that an Auto Contingent Allegiance (ACA) Condition exits in the task set.  A Clear ACA message is normally used to clear this condition.

40h – Task Aborted.  This means that a task has been aborted by another SCSI initiator (nasty) and the Task Aborted Status (TAS) bit is 1 (one) in the Control Mode page.  More info to come on mode pages.

If you have any specific questions about these status codes, or when and why they occur, leave a comment and we will get you hooked up.

Incoming search terms for the article:

Be the first to comment - What do you think?  Posted by Greg - April 2, 2010 at 7:30 AM

Categories: Glossary   Tags:

SCSI Sense Data

SCSI Sense Data is the information that comes back from a target when either 1) a CHECK CONDITION Status has been received at the end of a Command (using an auto-sense mechanism), or 2) a REQUEST SENSE command has been issue by a SCSI Initiator.

Whenever I do my SAN training classes, this is one of the topics that I always cover – How to Decode SCSI Sense Data.  Becoming a sense data decoder is not that difficult if you know the basic structure of the sense data and the 4 basic steps that I used to decode 95% (or more) of all the sense data that I see.  Below are the basic steps.

Step 1 – Check the Sense Key.  The Sense Key provides “basic” information about the error and is located in byte 2, bits 3-0, of the returned sense data.

Step 2 – Check the Additional Length field.  This field is located in byte 7 and tells you how many more bytes of data are valid (after byte 7).

Step 3 – Check the Additional Sense Code (ASC) and Additional Sense Code Qualifier (ASCQ).  These are bytes 12 & 13 of the returned sense data and provide more detailed information about the failure or error condition.

Step 4 – Check the Sense Key Specific Valid (SKSV) bit, which is located in bit 7 of byte 15.  If that bit is on, it means that there is “even more” detail about the condition that caused the problem in bytes 15-17.  You will have to plug it into another decode table, based on the Sense Key (from Step 1), but in some cases, this can point you to the exact bit and byte in error so that you can debug your problem.

Sense Data Decoder Steps

Steps to Decode SCSI Sense Data

These 4 basic steps can decode up to 95% of all the SCSI error conditions that you will ever see, but there can be even more details, depending on the SCSI device (disk drive, tape drive, etc.) that you are working with.  Master these 4 steps and practice them whenever you can and you will become a SCSI Sense Data Decoder in a relatively short period of time.  If you want to learn how to decode sense data even faster, just let me know and we can get you signed up.

Incoming search terms for the article:

Be the first to comment - What do you think?  Posted by Greg - March 24, 2010 at 4:35 PM

Categories: Glossary   Tags: ,

Storage Area Network (SAN)

Storage Area Network (SAN) - Similar to data network except ...

Read more...

Be the first to comment - What do you think?  Posted by Greg - March 1, 2010 at 12:48 PM

Categories: Glossary   Tags:

« Previous PageNext Page »