Sergey Gotliv has uploaded a new change for review. Change subject: hsm: Distinguish between iface and initiator when creating iSCSI iface ......................................................................
hsm: Distinguish between iface and initiator when creating iSCSI iface VDSM mistakely assumed that iface name and iface initiator name is the same, so if admin configured specific initiator name in the host its mistakenly overriten by ifaceName in the iface file. In such a case the iSCSI connection is failed. Change-Id: I2ea42e63e3e09babaa283c4e97e341ff259a6945 Signed-off-by: Sergey Gotliv <sgot...@redhat.com> --- M vdsm/storage/hsm.py 1 file changed, 4 insertions(+), 3 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/28/25628/1 diff --git a/vdsm/storage/hsm.py b/vdsm/storage/hsm.py index 2e9dbe5..f7f9cdd 100644 --- a/vdsm/storage/hsm.py +++ b/vdsm/storage/hsm.py @@ -148,7 +148,7 @@ sd.GLUSTERFS_DOMAIN: 'glusterfs'} -def _BCInitiatorNameResolve(ifaceName): +def _resolveIscsiIface(ifaceName, initiatorName): if not ifaceName: return iscsi.IscsiInterface('default') @@ -156,7 +156,7 @@ if iface.name == ifaceName: return iface - iface = iscsi.IscsiInterface(ifaceName, initiatorName=ifaceName) + iface = iscsi.IscsiInterface(ifaceName, initiatorName=initiatorName) iface.create() return iface @@ -230,7 +230,8 @@ target = iscsi.IscsiTarget(portal, tpgt, conDict.get('iqn', None)) - iface = _BCInitiatorNameResolve(conDict.get('initiatorName', None)) + iface = _resolveIscsiIface(conDict.get('ifaceName', None), + conDict.get('initiatorName', None)) cred = None username = conDict.get('user', None) -- To view, visit http://gerrit.ovirt.org/25628 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I2ea42e63e3e09babaa283c4e97e341ff259a6945 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Sergey Gotliv <sgot...@redhat.com> _______________________________________________ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches