Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1170447 - [RFE][nova]: hw-iscsi-device-name-support
[RFE][nova]: hw-iscsi-device-name-support
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-nova (Show other bugs)
unspecified
Unspecified Unspecified
low Severity low
: Upstream M2
: 7.0 (Kilo)
Assigned To: RHOS Maint
https://blueprints.launchpad.net/nova...
upstream_milestone_kilo-2 upstream_de...
: FutureFeature, OtherQA, Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2014-12-04 00:03 EST by RHOS Integration
Modified: 2015-08-05 09:19 EDT (History)
12 users (show)

See Also:
Fixed In Version: openstack-nova-2015.1.0-10.el7ost
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-08-05 09:19:14 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2015:1548 normal SHIPPED_LIVE Red Hat Enterprise Linux OpenStack Platform Enhancement Advisory 2015-08-05 13:07:06 EDT

  None (edit)
Description RHOS Integration 2014-12-04 00:03:15 EST
Cloned from launchpad blueprint https://blueprints.launchpad.net/nova/+spec/hw-iscsi-device-name-support.

Description:

LibvirtISCSIVolumeDriver of nova.virt.libvirt.volume.py is hardcoding to use /dev/disk/by-path/ip-%s-iscsi-%s-lun-%s (in self._get_host_device, and disconnect_volume). But when we use h/w iscsi initiators, the filename starts with pci-<hwaddr>-ip-<targetportal>-iscsi-<target>-lun-<lun id>. We would like to modify the code so that pci-<hwaddr> files are also searched to determine if the device exists.

The following algorithm can be used: 

- Perform "ls" of /dev/disk/by-path directory
- Look for a file that contains the ip-<targetportal>-iscsi-<target>-lun-<lun id> in it. Get the complete filename and use this 
to determine if the device exists.

For e.g:
"ls" gives the following output

ip-192.168.2.126:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1
ip-192.168.2.126:3260-iscsi-iqn.2010-10.org.openstack:volume-5fdf6167-ec09-4b0b-acff-b179b415ee4d-lun-1
pci-0000:00:1a.0-usb-0:1.2:1.0-scsi-0:0:0:0
pci-0000:00:1a.0-usb-0:1.2:1.1-scsi-0:0:0:0
pci-0000:00:1a.0-usb-0:1.2:1.1-scsi-0:0:0:1
pci-0000:01:00.2-ip-192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1
pci-0000:01:00.2-ip-192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-5fdf6167-ec09-4b0b-acff-b179b415ee4d-lun-1
pci-0000:01:00.3-ip-192.168.11.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1
pci-0000:01:00.3-ip-192.168.11.26:3260-iscsi-iqn.2010-10.org.openstack:volume-5fdf6167-ec09-4b0b-acff-b179b415ee4d-lun-1

We will be able to search for 192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1 in the list of filenames, and we will find pci-0000:01:00.2-ip-192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1 that contains the search string.

We will then use this filename pci-0000:01:00.2-ip-192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1 to determine whether the device exists (via os.path.exists). In the current code, because of hardcoding "ip-" as the beginning, the code is searching for ip-192.168.10.26:3260-iscsi-iqn.2010-10.org.openstack:volume-0289c43f-7b32-490c-97a2-6385feb1480f-lun-1 which will not be there.

The same logic will also be used in disconnect_volume to determine the device_prefix.

Specification URL (additional information):

None
Comment 7 errata-xmlrpc 2015-08-05 09:19:14 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2015:1548

Note You need to log in before you can comment on or make changes to this bug.