block_device_mapping_v2.disk_bus allows invalid values
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Lee Yarwood | ||
Stein |
In Progress
|
Medium
|
Unassigned | ||
Train |
Fix Released
|
Medium
|
Lee Yarwood | ||
Ussuri |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Description
===========
There is no validation of the provided disk_bus in the API, with libvirt this eventually leads to the driver and hypervisor eventually ignoring the requested disk_bus and defaulting to virtio.
Steps to reproduce
==================
A common mistake for users to make is to request a virtio-scsi disk_bus:
$ nova boot --flavor 2 --block-device id=a37d4630-
Expected result
===============
This should be rejected as this is not a supported disk_bus, instead scsi should be used.
Actual result
=============
The value is ignored and the instance defaults to a virtio bus.
Environment
===========
1. Exact version of OpenStack you are running. See the following
list for all releases: http://
master
2. Which hypervisor did you use?
(For example: Libvirt + KVM, Libvirt + XEN, Hyper-V, PowerKVM, ...)
What's the version of that?
Libvirt + KVM
2. Which storage type did you use?
(For example: Ceph, LVM, GPFS, ...)
What's the version of that?
N/A
3. Which networking type did you use?
(For example: nova-network, Neutron with OpenVSwitch, ...)
N/A
Logs & Configs
==============
$ nova boot --flavor 2 --block-device id=a37d4630-
[..]
$ sudo virsh domblklist 45bee4d4-
Target Source
-------
vda /opt/stack/
Changed in nova: | |
importance: | Undecided → Medium |
assignee: | nobody → Lee Yarwood (lyarwood) |
Fix proposed to branch: master /review. opendev. org/724842
Review: https:/