BUG: iSCSI login failed due to authorization failure

6126 views
Skip to first unread message

majianpeng

unread,
Nov 13, 2013, 2:12:07 AM11/13/13
to open-iscsi
Hi all:

Os: ubuntu 13.10
iscsiadm version 2.0-873

When login a target, the error message are:
Logging in to [iface: default, target: kedacom.com, portal: 172.16.123.64,3260] (multiple)
iscsiadm: Could not login to [iface: default, target: kedacom.com, portal: 172.16.123.64,3260].
iscsiadm: initiator reported error (24 - iSCSI login failed due to authorization failure)

I reviewed the code found the iscsi name from iscsi-name or iscsiadm is different.

iscsi-name don't check /etc/iscsi/initiatorname.iscsi.
But iscsid get iscsi-name from initiatorname.iscsi.
So if we use name by iscsi-name and then use iscsiadm to login, it will fail.

Target will print those message:
[ 1615.908301] iSCSI Initiator Node: iqn.1993-08.org.debian:01:6b36811dac8a is not authorized to access iSCSI target portal group: 1.
[ 1615.908376] iSCSI Login negotiation failed.

So i think iscsi-name firtly check /etc/iscsi/initiatorname.iscsi. If this file have valid iscsiname,it print this.

Jianpeng Ma
Thanks!

Mike Christie

unread,
Nov 13, 2013, 6:16:54 PM11/13/13
to open-...@googlegroups.com, majianpeng
iscsi-iname is only used to create a name to put in
/etc/iscsi/initiatorname.iscsi if the distro or user wanted runs it
because they do not have their own naming scheme. So for example I think
fedora/RHEL when you first install/run iscsi will run iscsi-iname and
take the name it prints and put it in /etc/iscsi/initiatorname.iscsi.

majianpeng

unread,
Nov 13, 2013, 7:42:40 PM11/13/13
to Mike Christie, open-iscsi
Ok, but from the name of iscsi-iname, i think this command tell the iscsi name of this machine.
But it not.
Maybe we change the name of iscsi-iname.

Jianpeng Ma
Thanks!

Ulrich Windl

unread,
Nov 14, 2013, 2:34:11 AM11/14/13
to open-...@googlegroups.com
>>> Mike Christie <mich...@cs.wisc.edu> schrieb am 14.11.2013 um 00:16 in
Nachricht <52840866...@cs.wisc.edu>:
Is "No manual entry for iscsi-iname" fixed already? Maybe that's the problem ;-)

At least I get:
# iscsi-iname -h

Generates a unique iSCSI node name on every invocation.

>
> --
> You received this message because you are subscribed to the Google Groups
> "open-iscsi" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to open-iscsi+...@googlegroups.com.
> To post to this group, send email to open-...@googlegroups.com.
> Visit this group at http://groups.google.com/group/open-iscsi.
> For more options, visit https://groups.google.com/groups/opt_out.



Ulrich Windl

unread,
Nov 14, 2013, 2:36:12 AM11/14/13
to open-iscsi
>>> majianpeng <majia...@gmail.com> schrieb am 14.11.2013 um 01:42 in Nachricht
<2013111408...@gmail.com>:
Better approach: Keept the name, but make the default to display the current name (like hostname). Add a new option (like "-c" or "-n") to (c)reate a (n)ew name for the initiator.

>
> Jianpeng Ma
> Thanks!
Reply all
Reply to author
Forward
0 new messages