[SRU] BDM with device_type=lun fails
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| OpenStack Compute (nova) |
Fix Released
|
Undecided
|
Unassigned | ||
| Ubuntu Cloud Archive |
Fix Released
|
Undecided
|
Unassigned | ||
| Caracal |
In Progress
|
Medium
|
Unassigned | ||
| Dalmatian |
Fix Released
|
Undecided
|
Unassigned | ||
| nova (Ubuntu) |
New
|
Undecided
|
Unassigned | ||
| Noble |
In Progress
|
Medium
|
Unassigned | ||
Bug Description
Original Bug Description Below
[ Impact ]
* On OpenStack Caracal, it is not possible to create a libvirt-backed LUN because OpenStack tries to create the volumes with a "serial" property that libvirt does not support. See [1] in libvirt source code, which demonstrates that for a long time (since at least 2015) the serial property has been incompatible with LUN devices
* Libvirt rejects the creation of the volume with the error: "unsupported configuration: scsi-block 'lun' devices do not support the serial property"
* The OpenStack volumes do not need the "serial" property, since they can be managed entirely by their alias
* The above issues are resolved by the commit at [2]
* From qemu's perspective, LUNs are hds. Therefore, in order for the boot order to be calculated properly, the libvirt driver needs to be aware that the lun device type maps to a qemu hd. This is addressed in [3]
[1] https:/
[2] https:/
[3] https:/
[ Test Plan ]
* Deploy an OpenStack cloud with cinder-lvm support
* Create a volume type for the LUNs
openstack volume type create lun-volumes
* Enforce that LUNs use the default LVM backing
openstack volume type set --property volume_
* Create a LUN volume
openstack volume create --size 5 --type lun-volumes volume1
export LUN_UUID=<UUID of volume1>
* Create another volume
openstack volume create --size 5 volume2
export SECOND_
* Create a server with volume1 and volume2 attached, specifying volume1 as a scsi lun device
openstack server create \
--block-device source_
--block-device source_
--flavor m1.small \
--network private \
--image focal server1 \
--key-name testkey \
--os-
* ssh into the vm and use lsblk to confirm that there's a root/ephemeral disk plus the two attached (LUN will be /sda, ephemeral will be /vda, and volume2 will be /vdb)
Without the patches the above will fail to create (server enters ERROR state and is unusable) with the following error. Whereas with the patches, the server will successfully boot and enter RUNNING state, validating the device's successful creation and that correct boot order determination
libvirt.
2025-12-08 11:39:54.493 1724625 ERROR nova.virt.
[ Where problems could occur ]
* This is removing a property that's commonly used to identify volumes, which could be problematic. However, it is only removed for LUN devices, and it is only removed from the libvirt XML, which never supported this property for LUN devices anyways, so the risks are low.
* OpenStack volumes are intended to be managed entirely by aliases, however, if any feature such as volume migrations or volume retyping relies on the serial property it may not work for LUNs. This has a low risk of affecting existing environments since this bug prevents users from creating libvirt-backed LUNs
* Users will need to be mindful that LUNs are qemu hds when considering their boot order. This is also low-risk for regression because existing environments are not able to create LUNs
[ Other Info ]
* The patches merged upstream during the Dalmation (24.10) cycle. Therefore, this SRU is targetting Noble for the distro, and Jammy-Caracal for the Ubuntu Cloud Archive
* PPA with packages built from this debdiff: https:/
* Upstream backports to unmaintained/
- https:/
- https:/
Original description:
=======
Libvirt recently (since our code was added) refuses the serial option on a disk which is attached as a LUN. Since we officially support this in our API, we need to avoid putting serial on those disks.
Also, even when we don't hit that problem, our boot order calculation fails with:
56694407 tempest-
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
May 07 17:16:33 jammy nova-compute[
| Changed in nova: | |
| status: | New → In Progress |
| summary: |
- BDM with device_type=lun fails + [SRU] BDM with device_type=lun fails |
| description: | updated |
| description: | updated |
| description: | updated |
| description: | updated |
| description: | updated |
| description: | updated |
| description: | updated |
| Changed in cloud-archive: | |
| status: | New → Fix Released |
| Changed in nova (Ubuntu Noble): | |
| status: | New → In Progress |
| importance: | Undecided → Medium |

Reviewed: https:/ /review. opendev. org/c/openstack /nova/+ /918089 /opendev. org/openstack/ nova/commit/ 575ff86a4f15727 86d66639f774405 fbc074fdb1
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit 575ff86a4f15727 86d66639f774405 fbc074fdb1
Author: Dan Smith <email address hidden>
Date: Fri May 3 08:55:50 2024 -0700
Avoid setting serial on raw LUN devices
Libvirt now enforces that device="lun" (i.e. raw device passthrough)
disks must not have the <serial> property set. We recently enabled
the ability to manage devices by alias instead of serial, but to
fully enable this use-case we need to avoid putting serial in the
XML to appease libvirt.
Related-Bug: #2065084 1e64ce046edeaf6 e49a7c89490
Change-Id: Ifa2df89f27e58e