← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1712801] [NEW] Virtuozzo conainers lack SCSI info in libvirt XML

 

Public bug reported:

Scenario is attach Ploop volume located on Vzstorage to Virtuozzo
container, operated via a libvirt driver. Problem is that containers
don't have anything like 'bus', and 'scsi' bus type is just a
convenience value.

nova.conf:
[libvirt]
vzstorage_mount_group = root
images_type = ploop
connection_uri = parallels+unix:///system
live_migration_uri = vz+tcp://%s/system
cpu_mode = none
virt_type = parallels

Attach attempt:
Aug 18 10:35:24.604287 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [None req-dc714064-d843-4bbd-86bd-30bda4c5aba9 tempest-AttachVolumeShelveTestJSON-773580589 tempest-AttachVolumeShelveTestJSON-773580589] [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] Driver failed to attach volume 2a595cc0-164a-4680-ba4d-5e8a352ccb72 at /dev/sdb: ValueError: max() arg is an empty sequence
Aug 18 10:35:24.604448 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] Traceback (most recent call last):
Aug 18 10:35:24.604623 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/block_device.py", line 389, in attach
Aug 18 10:35:24.604811 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     device_type=self['device_type'], encryption=encryption)
Aug 18 10:35:24.604966 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/libvirt/driver.py", line 1235, in attach_volume
Aug 18 10:35:24.605119 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     disk_info['unit'] = self._get_scsi_controller_max_unit(guest) + 1
Aug 18 10:35:24.605269 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/libvirt/driver.py", line 1060, in _get_scsi_controller_max_unit
Aug 18 10:35:24.605417 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     return max(ret)
Aug 18 10:35:24.605586 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] ValueError: max() arg is an empty sequence
Aug 18 10:35:24.605737 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] 

libvirt instance XML:
<domain type='vz' id='0'>
  <name>instance-00000007</name>
  <uuid>0e2917b7-37a7-443d-87b6-439d6ec1906d</uuid>
  <memory unit='KiB'>524288</memory>
  <currentMemory unit='KiB'>524288</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <os>
    <type arch='x86_64'>exe</type>
    <init>/sbin/init</init>
  </os>
  <clock offset='utc'/>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>
  <devices>
    <filesystem type='file' accessmode='passthrough'>
      <driver type='ploop' format='ploop'/>
      <source file='/opt/stack/data/nova/instances/0e2917b7-37a7-443d-87b6-439d6ec1906d/disk'/>
      <target dir='/'/>
    </filesystem>
    <interface type='network'>
      <mac address='00:00:00:00:00:00'/>
      <source network='host-routed'/>
      <target dev='venet0'/>
      <link state='up'/>
    </interface>
    <interface type='bridge' trustGuestRxFilters='no'>
      <mac address='fa:16:3e:44:08:ca'/>
      <source bridge='qbr25d67bec-74'/>
      <target dev='tap25d67bec-74'/>
      <link state='up'/>
    </interface>
    <input type='mouse' bus='parallels'/>
    <input type='keyboard' bus='parallels'/>
    <graphics type='vnc' port='5700' autoport='yes' listen='0.0.0.0'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>
    <video>
      <model type='parallels' heads='1'/>
    </video>
  </devices>
</domain>

** Affects: nova
     Importance: Undecided
         Status: New

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

Title:
  Virtuozzo conainers lack SCSI info in libvirt XML

Status in OpenStack Compute (nova):
  New

Bug description:
  Scenario is attach Ploop volume located on Vzstorage to Virtuozzo
  container, operated via a libvirt driver. Problem is that containers
  don't have anything like 'bus', and 'scsi' bus type is just a
  convenience value.

  nova.conf:
  [libvirt]
  vzstorage_mount_group = root
  images_type = ploop
  connection_uri = parallels+unix:///system
  live_migration_uri = vz+tcp://%s/system
  cpu_mode = none
  virt_type = parallels

  Attach attempt:
  Aug 18 10:35:24.604287 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [None req-dc714064-d843-4bbd-86bd-30bda4c5aba9 tempest-AttachVolumeShelveTestJSON-773580589 tempest-AttachVolumeShelveTestJSON-773580589] [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] Driver failed to attach volume 2a595cc0-164a-4680-ba4d-5e8a352ccb72 at /dev/sdb: ValueError: max() arg is an empty sequence
  Aug 18 10:35:24.604448 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] Traceback (most recent call last):
  Aug 18 10:35:24.604623 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/block_device.py", line 389, in attach
  Aug 18 10:35:24.604811 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     device_type=self['device_type'], encryption=encryption)
  Aug 18 10:35:24.604966 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/libvirt/driver.py", line 1235, in attach_volume
  Aug 18 10:35:24.605119 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     disk_info['unit'] = self._get_scsi_controller_max_unit(guest) + 1
  Aug 18 10:35:24.605269 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]   File "/opt/stack/new/nova/nova/virt/libvirt/driver.py", line 1060, in _get_scsi_controller_max_unit
  Aug 18 10:35:24.605417 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9]     return max(ret)
  Aug 18 10:35:24.605586 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] ValueError: max() arg is an empty sequence
  Aug 18 10:35:24.605737 host-10-94-179-76 nova-compute[68438]: ERROR nova.virt.block_device [instance: 7f4a9527-8ff0-4966-aad5-fe4bc55c9ef9] 

  libvirt instance XML:
  <domain type='vz' id='0'>
    <name>instance-00000007</name>
    <uuid>0e2917b7-37a7-443d-87b6-439d6ec1906d</uuid>
    <memory unit='KiB'>524288</memory>
    <currentMemory unit='KiB'>524288</currentMemory>
    <vcpu placement='static'>1</vcpu>
    <os>
      <type arch='x86_64'>exe</type>
      <init>/sbin/init</init>
    </os>
    <clock offset='utc'/>
    <on_poweroff>destroy</on_poweroff>
    <on_reboot>restart</on_reboot>
    <on_crash>destroy</on_crash>
    <devices>
      <filesystem type='file' accessmode='passthrough'>
        <driver type='ploop' format='ploop'/>
        <source file='/opt/stack/data/nova/instances/0e2917b7-37a7-443d-87b6-439d6ec1906d/disk'/>
        <target dir='/'/>
      </filesystem>
      <interface type='network'>
        <mac address='00:00:00:00:00:00'/>
        <source network='host-routed'/>
        <target dev='venet0'/>
        <link state='up'/>
      </interface>
      <interface type='bridge' trustGuestRxFilters='no'>
        <mac address='fa:16:3e:44:08:ca'/>
        <source bridge='qbr25d67bec-74'/>
        <target dev='tap25d67bec-74'/>
        <link state='up'/>
      </interface>
      <input type='mouse' bus='parallels'/>
      <input type='keyboard' bus='parallels'/>
      <graphics type='vnc' port='5700' autoport='yes' listen='0.0.0.0'>
        <listen type='address' address='0.0.0.0'/>
      </graphics>
      <video>
        <model type='parallels' heads='1'/>
      </video>
    </devices>
  </domain>

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