#728326 istgt: abysmal error reporting

Package:
istgt
Source:
istgt
Description:
iSCSI userspace target daemon for Unix-like operating systems
Submitter:
Michal Suchanek
Date:
2013-10-31 15:45:15 UTC
Severity:
normal
#728326#5
Date:
2013-10-30 17:57:49 UTC
From:
To:
Hello,

I get this error in log:
Oct 30 18:49:15 OptiPlex960 istgt[11969]: Login from iqn.1994-05.com.redhat:82afc45e9e1c (10.10.10.2) on iqn.2001-04.optiplex960.uvt316-2.ruk.cuni.cz:rhev LU1 (10.10.10.10:3260,1), ISID=23d0b0000, TSIH=2, CID=0, HeaderDigest=on, DataDigest=on
Oct 30 18:49:15 OptiPlex960 istgt[11969]: istgt_iscsi.c:5223:worker: ***ERROR*** conn->state = 2

WTF is conn->state = 2?

Man page does not say about conn->state

I can connect with local open-iscsi but not this redhat initiator.

Is there anything that can be done to get some real disgnostics?

Thanks

Michal

#728326#10
Date:
2013-10-30 22:22:41 UTC
From:
To:
Hi Michal,

I agree that's not very clear, but at least it gave a source code line
number!  And:

src/istgt_iscsi.h:

That situation can happen for many reasons during istgt_iscsi_read_pdu()
and suggests it didn't like something about a packet it just received.

It seems istgt has a 'TRACELOG' with extra debugging messages.  You
could enable it using "-t net" or "-t all" on the command line when
starting istgt;  that may give you some further info.

Regards,

#728326#15
Date:
2013-10-31 15:42:55 UTC
From:
To:
Excerpts from Steven Chamberlain's message of Wed Oct 30 23:22:41 +0100 2013:
is ignored. eg. -t all does nothing, -t net does nothing, -t net -t
iscsi shows some info, -t net -t iscsi -t all even more.

and this is what I get:

Oct 31 16:37:07 OptiPlex960 istgt[31997]: Login from iqn.1994-05.com.redhat:82afc45e9e1c (10.10.10.2) on iqn.2001-04.optiplex960.uvt316-2.ruk.cuni.cz:rhev LU1 (10.10.10.10:3260,1), ISID=23d170000, TSIH=1, CID=0, HeaderDigest=on, DataDigest=on
istgt_iscsi.c: 433:istgt_iscsi_read_pdu: BHS read 48
istgt_iscsi.c: 189:istgt_iscsi_read: Read EOF
istgt_iscsi.c: 451:istgt_iscsi_read_pdu: iscsi_read() EOF
istgt_iscsi.c:5223:worker: ***ERROR*** conn->state = CONN_STATE_EXITING

So it seems like the initiator just disconnects shortly after login. The
initiator disconnecting is something that could perhaps be reported
without enabling tracing.

Thanks

Michal