← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1449492] Re: Cinder not working with IPv6 ISCSI

 

Reviewed:  https://review.openstack.org/234425
Committed: https://git.openstack.org/cgit/openstack/os-brick/commit/?id=10924909cd81db10ac3bbf0f02496233fa94f6ea
Submitter: Jenkins
Branch:    master

commit 10924909cd81db10ac3bbf0f02496233fa94f6ea
Author: Lukas Bezdicka <lbezdick@xxxxxxxxxx>
Date:   Tue Oct 13 16:26:00 2015 -0400

    Remove brackets from portal
    
    In case IPv6 address is present in location os_brick would fail to
    get correct path as brackets are forbidden chars in udev and are removed.
    
    Closes-Bug: #1449492
    Change-Id: I965ce7bb9bc2b2c3fdd240d998441f8b06b36934


** Changed in: os-brick
       Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1449492

Title:
  Cinder not working with IPv6 ISCSI

Status in OpenStack Compute (nova):
  In Progress
Status in os-brick:
  Fix Released

Bug description:
  Testing configuring Openstack completely with IPv6

  Found that IP address parsing was thrown in a lot of cases because of
  need to have '[]' encasing the address, or not for use with URLs and
  the parsing of some user space 3rd party C binaries - iscsiadm for
  example. All the others are best left by using a name set to the IPv6
  address in the /etc/hosts file, iSCSI though its not possible.

  Got Cinder working by setting iscsi_ip_address
  (/etc/cinder/cinder.conf) to '[$my_ip]' where my ip is an IPv6 address
  like 2001:db08::1 (not RFC documentation address ?) and changing one
  line of python iin the nova virt/libvirt/volume.py code:

  
  --- nova/virt/libvirt/volume.py.orig    2015-04-27 23:00:00.208075644 +1200
  +++ nova/virt/libvirt/volume.py 2015-04-27 22:38:08.938643636 +1200
  @@ -833,7 +833,7 @@
       def _get_host_device(self, transport_properties):
           """Find device path in devtemfs."""
           device = ("ip-%s-iscsi-%s-lun-%s" %
  -                  (transport_properties['target_portal'],
  +                  (transport_properties['target_portal'].replace('[','').replace(']',''),
                      transport_properties['target_iqn'],
                      transport_properties.get('target_lun', 0)))
           if self._get_transport() == "default":

  Nova-compute was looking for '/dev/disk/by-path/ip-[2001:db08::1]:3260
  -iscsi-iqn.2010-10.org.openstack:*' when there were no '[]' in the
  udev generated path....

  This one can't be worked around by using the /etc/hosts file. iscsiadm
  and tgt ned the IPv6 address wrapped in '[]', and iscsadm uses it in
  output.  The above patch could be matched with a bi ihte cinder code
  that puts '[]' around iscsi_ip_address if if it is not supplied.

  More work is obvioulsy need on a convention for writing IPv6 addresses
  in the Openstack configuration files, and there will be a lot of
  places where code will need to be tweaked.

  Lets start by fixing this blooper/lo hanging one  first though as it
  makes it possible to get Cinder working in a pure IPv6 environment.
  Above may be a bit of a hack, but only one one code path needs
  adjustment...

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1449492/+subscriptions