← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1386348] [NEW] [Suggestion] Supply udev script for create scsi disk symlink

 

Public bug reported:

When nova-compute try to configure iscsi port (with iscsiadm command) to
use a lvm cinder volume scan directory /dev/disk/by-path/ for a file
with this name convention:

ip-<target_portal>-iscsi-<target_iqn>-lun-<target_lun>

Unlucky on gentoo/sabayon distro scsi device is visible as GENERIC SCSI
DISK and so nova-compute doesn't continue bootstrap process.

So, I create a bash script and an udev rule that resolve this issue.
This bash script currently use lsscsi external program to retrieve lun
Id (I don't known how retrieve this information directly through udevadm
info or sysfs/proc fs) and others information for udev daemon.

In attachment script that print string with same name convention used
inside volume.py.

Hereinafter an example of udev rule that use this script:
KERNEL=="sd*", SUBSYSTEM=="block", ENV{ID_BUS}=="scsi", PROGRAM="/etc/nova/scsi-openscsi-link.sh %b $id",  SYMLINK+="disk/by-path/%c"

I think that could be helpful insert this script and an example udev
rule (in a file like openstack.rules.example) to help users that use
openstack in different distro.

My cent.

Regards,
Geaaru

** Affects: nova
     Importance: Undecided
         Status: New

** Attachment added: "Script for create symlink"
   https://bugs.launchpad.net/bugs/1386348/+attachment/4246437/+files/scsi-openscsi-link.sh

-- 
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/1386348

Title:
  [Suggestion] Supply udev script for create scsi disk symlink

Status in OpenStack Compute (Nova):
  New

Bug description:
  When nova-compute try to configure iscsi port (with iscsiadm command)
  to use a lvm cinder volume scan directory /dev/disk/by-path/ for a
  file with this name convention:

  ip-<target_portal>-iscsi-<target_iqn>-lun-<target_lun>

  Unlucky on gentoo/sabayon distro scsi device is visible as GENERIC
  SCSI DISK and so nova-compute doesn't continue bootstrap process.

  So, I create a bash script and an udev rule that resolve this issue.
  This bash script currently use lsscsi external program to retrieve lun
  Id (I don't known how retrieve this information directly through
  udevadm info or sysfs/proc fs) and others information for udev daemon.

  In attachment script that print string with same name convention used
  inside volume.py.

  Hereinafter an example of udev rule that use this script:
  KERNEL=="sd*", SUBSYSTEM=="block", ENV{ID_BUS}=="scsi", PROGRAM="/etc/nova/scsi-openscsi-link.sh %b $id",  SYMLINK+="disk/by-path/%c"

  I think that could be helpful insert this script and an example udev
  rule (in a file like openstack.rules.example) to help users that use
  openstack in different distro.

  My cent.

  Regards,
  Geaaru

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


Follow ups

References