Distinguish command timeout
Distinguish command timeout from outqueue or waitqueue. For example, A command sequence: ...NOP,READ,WRITE... NOP OUT command has no dependence on backend media, it is expected to response soon. Once NOP timeout in libiscsi: a, the command is already sent to target, the target side does *not* response. b, the command is still pending in libiscsi. Separate the two cases for trouble shooting. Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
This commit is contained in:
@@ -737,7 +737,7 @@ iscsi_timeout_scan(struct iscsi_context *iscsi)
|
||||
cmdsn_gap++;
|
||||
}
|
||||
ISCSI_LIST_REMOVE(&iscsi->outqueue, pdu);
|
||||
iscsi_set_error(iscsi, "command timed out");
|
||||
iscsi_set_error(iscsi, "command timed out from outqueue");
|
||||
iscsi_dump_pdu_header(iscsi, pdu->outdata.data);
|
||||
if (pdu->callback) {
|
||||
pdu->callback(iscsi, SCSI_STATUS_TIMEOUT,
|
||||
@@ -757,7 +757,7 @@ iscsi_timeout_scan(struct iscsi_context *iscsi)
|
||||
continue;
|
||||
}
|
||||
ISCSI_LIST_REMOVE(&iscsi->waitpdu, pdu);
|
||||
iscsi_set_error(iscsi, "command timed out");
|
||||
iscsi_set_error(iscsi, "command timed out from waitqueue");
|
||||
iscsi_dump_pdu_header(iscsi, pdu->outdata.data);
|
||||
if (pdu->callback) {
|
||||
pdu->callback(iscsi, SCSI_STATUS_TIMEOUT,
|
||||
|
||||
Reference in New Issue
Block a user