Subject: iSCSI: Notifications on error

From: "Lakshmi Ramasubramanian" <[email-masked]>
Date: Thu, 25 Jul 2002 07:08:58 -0700

If a command fails at the SCSI layer (on the target side), the driver
can freeze the queue, and fail all requests till the queue is unfreezed.

The target needs to tell the initiator about the queue freeze condition 
so that an initiator can issue an unfreeze request.
 
Currently there is no way (as much as I could understand) in the spec
to do such a thing. We can use vendor specific Async messages, but that
will cause interop problems.
 
Is it reasonable to request for a mechanism to do the above in the iSCSI
spec?
 
thanks!
 -lakshmi

---

From: [email-masked]
Date: Thu, 25 Jul 2002 10:33:10 -0400

> will cause interop problems.

SCSI and iSCSI already provide the means to do so -- "fails at
the SCSI layer (on the target side)" should mean "results in a
CHECK CONDITION" and a CA (Contingent Allegiance) state.  iSCSI
deals with this by requiring Autosense (MUST implement, MUST use)
- that prevents queue freezing, as the sense information comes
back in the SCSI Response PDU and the target continues execution,
see Section 5.8.4.3 of SAM-2.  A target that returns sense via
Autosense but still freezes execution is broken.

A quick reminder to target implementers - when working from
a (parallel) SCSI device that does CA in the classic manner
(i.e., freezes execution and waits for the initiator to Request
Sense), Autosense MUST be implemented in the iSCSI target
as the iSCSI initiator will not issue the Request Sense command
needed to unfreeze things.  This is IMPORTANT!

The other obvious way to "freeze the queue" on the target side
is ACA (Auto Contingent Allegiance), but this only happens
when the initiator asks for it (look for the NACA bit in
the appropriate SCSI specs) and there's a specific iSCSI
task management operation (mandated by SAM-2) to clear an
ACA condition - see Section 9.5 - an initiator that is using
ACA will know that it has to issue the CLEAR ACA operation,
and it will know this based on the CHECK CONDITION info
that comes back in the SCSI Response.

Both CA and ACA are handled by the iSCSI spec.  Putting in
vendor-specific async messages to handle them would be *very*
wrong.  If this doesn't cover the case of concern, please supply
more information/details.

Thanks,
--David
---------------------------------------------------
David L. Black, Senior Technologist
EMC Corporation, 42 South St., Hopkinton, MA  01748
+1 (508) 249-6449            FAX: +1 (508) 497-8018
[email-masked]       Mobile: +1 (978) 394-7754
---------------------------------------------------

---

From: "Julian Satran" <[email-masked]>
Date: Fri, 26 Jul 2002 11:48:28 +0300

Lakshmi,

The freeze is a SCSI freeze and SCSI has also commands to thaw the queue
(look for ACA reset and equivalents for UA cases).
iSCSI does not have to be involved.

Julo

                      "Lakshmi                                                                                                                
                      Ramasubramanian"           To:       <[email-masked]>                                                                  
                      <[email-masked]        cc:       "Joe Dai" <[email-masked]>                                           
                      rosoft.com>                Subject:  iSCSI: Notifications on error                                                      
                      Sent by:                                                                                                                
                      [email-masked]                                                                                                     
                      du                                                                                                                      

                      07/25/2002 05:08 PM                                                                                                     

thanks!
 -lakshmi