[libvirt] [PATCH 0/2] qemu: Enable -blockdev support (blockdev-add saga)

To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu. There is one known qemu bug though: Internal snapshots don't work with -blockdev: https://bugzilla.redhat.com/show_bug.cgi?id=1658981 Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed. Any other ideas? Peter Krempa (2): qemu: caps: Add capability for dynamic 'auto-read-only' support for files qemu: enable blockdev support src/qemu/qemu_capabilities.c | 5 + src/qemu/qemu_capabilities.h | 1 + .../caps_4.1.0.x86_64.xml | 2 + .../controller-virtio-scsi.x86_64-latest.args | 35 +++-- .../disk-aio.x86_64-latest.args | 19 ++- ...-backing-chains-noindex.x86_64-latest.args | 145 +++++++++++++++--- .../disk-cache.x86_64-latest.args | 50 ++++-- .../disk-cdrom-network.x86_64-latest.args | 32 ++-- .../disk-cdrom-tray.x86_64-latest.args | 24 ++- .../disk-cdrom.x86_64-latest.args | 21 +-- .../disk-copy_on_read.x86_64-latest.args | 19 ++- .../disk-detect-zeroes.x86_64-latest.args | 17 +- .../disk-error-policy.x86_64-latest.args | 30 ++-- .../disk-floppy-q35-2_11.x86_64-latest.args | 14 +- .../disk-floppy-q35-2_9.x86_64-latest.args | 14 +- .../disk-floppy.x86_64-latest.args | 21 ++- .../disk-network-gluster.x86_64-latest.args | 32 ++-- .../disk-network-iscsi.x86_64-latest.args | 58 ++++--- .../disk-network-nbd.x86_64-latest.args | 41 +++-- .../disk-network-rbd.x86_64-latest.args | 67 +++++--- .../disk-network-sheepdog.x86_64-latest.args | 16 +- ...isk-network-source-auth.x86_64-latest.args | 30 ++-- .../disk-network-tlsx509.x86_64-latest.args | 64 +++++--- .../disk-readonly-disk.x86_64-latest.args | 14 +- .../disk-scsi-device-auto.x86_64-latest.args | 14 +- .../disk-scsi.x86_64-latest.args | 35 +++-- .../disk-shared.x86_64-latest.args | 36 +++-- ...irtio-scsi-reservations.x86_64-latest.args | 20 ++- .../floppy-drive-fat.x86_64-latest.args | 7 +- ...egl-headless-rendernode.x86_64-latest.args | 7 +- .../graphics-egl-headless.x86_64-latest.args | 7 +- ...threads-virtio-scsi-pci.x86_64-latest.args | 25 ++- ...y-hotplug-nvdimm-access.x86_64-latest.args | 7 +- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 7 +- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 7 +- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 7 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 7 +- .../memory-hotplug-nvdimm.x86_64-latest.args | 7 +- ...eo-bochs-display-device.x86_64-latest.args | 10 +- ...virtio-non-transitional.x86_64-latest.args | 7 +- .../virtio-transitional.x86_64-latest.args | 7 +- .../x86_64-pc-graphics.x86_64-latest.args | 8 +- .../x86_64-pc-headless.x86_64-latest.args | 8 +- .../x86_64-q35-graphics.x86_64-latest.args | 8 +- .../x86_64-q35-headless.x86_64-latest.args | 8 +- 45 files changed, 714 insertions(+), 306 deletions(-) -- 2.21.0

Initial implementation of 'auto-read-only' didn't reopen the backing files when needed. For '-blockdev' to work we need to be able to tel qemu to open a file read-only and change it during blockjobs as we label backing chains with a sVirt label which does not allow writing. The dynamic auto-read-only supports this as it reopens files when writing is demanded. Add a capability to detect that the posix file based backends support the dynamic part. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Jiri Denemark <jdenemar@redhat.com> --- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml | 1 + 3 files changed, 4 insertions(+) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 9b19930964..a3de99d365 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -539,6 +539,7 @@ VIR_ENUM_IMPL(virQEMUCaps, "migration-file-drop-cache", "net-socket-dgram", "dbus-vmstate", + "blockdev-file-dynamic-auto-read-only", ); @@ -1284,6 +1285,7 @@ static struct virQEMUCapsStringFlags virQEMUCapsQMPSchemaQueries[] = { { "query-display-options/ret-type/+egl-headless/rendernode", QEMU_CAPS_EGL_HEADLESS_RENDERNODE }, { "nbd-server-add/arg-type/bitmap", QEMU_CAPS_NBD_BITMAP }, { "blockdev-add/arg-type/+file/drop-cache", QEMU_CAPS_MIGRATION_FILE_DROP_CACHE }, + { "blockdev-add/arg-type/+file/$dynamic-auto-read-only", QEMU_CAPS_BLOCK_FILE_AUTO_READONLY_DYNAMIC }, }; typedef struct _virQEMUCapsObjectTypeProps virQEMUCapsObjectTypeProps; diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 54f91151c6..f16c0c91fa 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -520,6 +520,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */ QEMU_CAPS_MIGRATION_FILE_DROP_CACHE, /* migration with disk cache on is safe for type='file' disks */ QEMU_CAPS_NET_SOCKET_DGRAM, /* -net socket,fd= with dgram socket */ QEMU_CAPS_DBUS_VMSTATE, /* -object dbus-vmstate */ + QEMU_CAPS_BLOCK_FILE_AUTO_READONLY_DYNAMIC, /* the auto-read-only property of block backends for files is dynamic */ QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags; diff --git a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml index 05e6538e37..540512c67d 100644 --- a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml @@ -210,6 +210,7 @@ <flag name='bochs-display'/> <flag name='migration-file-drop-cache'/> <flag name='net-socket-dgram'/> + <flag name='blockdev-file-dynamic-auto-read-only'/> <version>4000050</version> <kvmVersion>0</kvmVersion> <microcodeVersion>43100759</microcodeVersion> -- 2.21.0

We require that 'auto-read-only' is dynamic for posix-file backeds this prevents problems with libvirt's usage of sVirt where we don't grant qemu permissions to write backing chain until it's needed. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- src/qemu/qemu_capabilities.c | 3 + .../caps_4.1.0.x86_64.xml | 1 + .../controller-virtio-scsi.x86_64-latest.args | 35 +++-- .../disk-aio.x86_64-latest.args | 19 ++- ...-backing-chains-noindex.x86_64-latest.args | 145 +++++++++++++++--- .../disk-cache.x86_64-latest.args | 50 ++++-- .../disk-cdrom-network.x86_64-latest.args | 32 ++-- .../disk-cdrom-tray.x86_64-latest.args | 24 ++- .../disk-cdrom.x86_64-latest.args | 21 +-- .../disk-copy_on_read.x86_64-latest.args | 19 ++- .../disk-detect-zeroes.x86_64-latest.args | 17 +- .../disk-error-policy.x86_64-latest.args | 30 ++-- .../disk-floppy-q35-2_11.x86_64-latest.args | 14 +- .../disk-floppy-q35-2_9.x86_64-latest.args | 14 +- .../disk-floppy.x86_64-latest.args | 21 ++- .../disk-network-gluster.x86_64-latest.args | 32 ++-- .../disk-network-iscsi.x86_64-latest.args | 58 ++++--- .../disk-network-nbd.x86_64-latest.args | 41 +++-- .../disk-network-rbd.x86_64-latest.args | 67 +++++--- .../disk-network-sheepdog.x86_64-latest.args | 16 +- ...isk-network-source-auth.x86_64-latest.args | 30 ++-- .../disk-network-tlsx509.x86_64-latest.args | 64 +++++--- .../disk-readonly-disk.x86_64-latest.args | 14 +- .../disk-scsi-device-auto.x86_64-latest.args | 14 +- .../disk-scsi.x86_64-latest.args | 35 +++-- .../disk-shared.x86_64-latest.args | 36 +++-- ...irtio-scsi-reservations.x86_64-latest.args | 20 ++- .../floppy-drive-fat.x86_64-latest.args | 7 +- ...egl-headless-rendernode.x86_64-latest.args | 7 +- .../graphics-egl-headless.x86_64-latest.args | 7 +- ...threads-virtio-scsi-pci.x86_64-latest.args | 25 ++- ...y-hotplug-nvdimm-access.x86_64-latest.args | 7 +- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 7 +- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 7 +- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 7 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 7 +- .../memory-hotplug-nvdimm.x86_64-latest.args | 7 +- ...eo-bochs-display-device.x86_64-latest.args | 10 +- ...virtio-non-transitional.x86_64-latest.args | 7 +- .../virtio-transitional.x86_64-latest.args | 7 +- .../x86_64-pc-graphics.x86_64-latest.args | 8 +- .../x86_64-pc-headless.x86_64-latest.args | 8 +- .../x86_64-q35-graphics.x86_64-latest.args | 8 +- .../x86_64-q35-headless.x86_64-latest.args | 8 +- 44 files changed, 710 insertions(+), 306 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index a3de99d365..ad62e4f8d7 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -4452,6 +4452,9 @@ virQEMUCapsInitProcessCaps(virQEMUCapsPtr qemuCaps) if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_CPU_UNAVAILABLE_FEATURES)) virQEMUCapsSet(qemuCaps, QEMU_CAPS_CANONICAL_CPU_FEATURES); + if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_BLOCK_FILE_AUTO_READONLY_DYNAMIC) && + virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_DISK_DEVICE_ID)) + virQEMUCapsSet(qemuCaps, QEMU_CAPS_BLOCKDEV); } diff --git a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml index 540512c67d..18123e2218 100644 --- a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml @@ -191,6 +191,7 @@ <flag name='usb-storage.werror'/> <flag name='egl-headless'/> <flag name='vfio-pci.display'/> + <flag name='blockdev'/> <flag name='memory-backend-memfd'/> <flag name='memory-backend-memfd.hugetlb'/> <flag name='iothread.poll-max-ns'/> diff --git a/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args b/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args index 32b781ced9..1647cfdd97 100644 --- a/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args @@ -32,21 +32,36 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -device virtio-scsi-pci,id=scsi2,cmd_per_lun=50,bus=pci.0,addr=0x4 \ -device virtio-scsi-pci,id=scsi3,max_sectors=512,bus=pci.0,addr=0x5 \ -device virtio-scsi-pci,id=scsi4,ioeventfd=on,bus=pci.0,addr=0x6 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-scsi0-0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-5-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,"driver":"raw",\ +"file":"libvirt-5-storage"}' \ -device scsi-hd,bus=scsi0.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi0-0-0-0,drive=drive-scsi0-0-0-0,id=scsi0-0-0-0,bootindex=1 \ --drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-scsi1-0-0-0 \ +device_id=drive-scsi0-0-0-0,drive=libvirt-5-format,id=scsi0-0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest2",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ -device scsi-hd,bus=scsi1.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi1-0-0-0,drive=drive-scsi1-0-0-0,id=scsi1-0-0-0 \ --drive file=/dev/HostVG/QEMUGuest3,format=raw,if=none,id=drive-scsi2-0-0-0 \ +device_id=drive-scsi1-0-0-0,drive=libvirt-4-format,id=scsi1-0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest3",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ -device scsi-hd,bus=scsi2.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi2-0-0-0,drive=drive-scsi2-0-0-0,id=scsi2-0-0-0 \ --drive file=/dev/HostVG/QEMUGuest4,format=raw,if=none,id=drive-scsi3-0-0-0 \ +device_id=drive-scsi2-0-0-0,drive=libvirt-3-format,id=scsi2-0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest4",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ -device scsi-hd,bus=scsi3.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi3-0-0-0,drive=drive-scsi3-0-0-0,id=scsi3-0-0-0 \ --drive file=/dev/HostVG/QEMUGuest5,format=raw,if=none,id=drive-scsi4-0-0-0 \ +device_id=drive-scsi3-0-0-0,drive=libvirt-2-format,id=scsi3-0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest5",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-hd,bus=scsi4.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi4-0-0-0,drive=drive-scsi4-0-0-0,id=scsi4-0-0-0 \ +device_id=drive-scsi4-0-0-0,drive=libvirt-1-format,id=scsi4-0-0-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args b/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args index 623ea39a2e..a424e58a48 100644 --- a/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args @@ -27,13 +27,20 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\ -cache=none,aio=native \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"aio":"native","node-name":"libvirt-2-storage","cache":{"direct":true,\ +"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-2-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-2-format,id=ide0-0-0,bootindex=1,\ write-cache=on \ --drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\ -readonly=on,aio=threads \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest2",\ +"aio":"threads","node-name":"libvirt-1-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args b/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args index bba58be46c..a2f030f165 100644 --- a/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args @@ -27,33 +27,138 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive 'file=gluster+unix:///Volume2/Image?socket=/path/to/sock,file.debug=4,\ -format=qcow2,if=none,id=drive-virtio-disk0' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/tmp/missing-backing-store.qcow",\ +"node-name":"libvirt-25-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-25-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-25-storage"}' \ +-blockdev '{"driver":"gluster","volume":"Volume2","path":"Image",\ +"server":[{"type":"unix","path":"/path/to/sock"}],"debug":4,\ +"node-name":"libvirt-24-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-24-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-24-storage","backing":"libvirt-25-format"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-24-format,\ id=virtio-disk0,bootindex=1 \ --drive file=nbd:unix:/var/run/nbdsock:exportname=bar,format=qcow2,if=none,\ -id=drive-virtio-disk1 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"file","filename":"/tmp/Fedora-17-x86_64-Live-KDE.iso",\ +"node-name":"libvirt-23-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-23-format","read-only":true,"driver":"raw",\ +"file":"libvirt-23-storage"}' \ +-blockdev '{"driver":"file","filename":"/tmp/image5.qcow",\ +"node-name":"libvirt-22-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-22-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-22-storage","backing":"libvirt-23-format"}' \ +-blockdev '{"driver":"file","filename":"/tmp/image4.qcow",\ +"node-name":"libvirt-21-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-21-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-21-storage","backing":"libvirt-22-format"}' \ +-blockdev '{"driver":"file","filename":"/tmp/image3.qcow",\ +"node-name":"libvirt-20-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-20-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-20-storage","backing":"libvirt-21-format"}' \ +-blockdev '{"driver":"file","filename":"/tmp/image2",\ +"node-name":"libvirt-19-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-19-format","read-only":true,"driver":"vmdk",\ +"file":"libvirt-19-storage","backing":"libvirt-20-format"}' \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-18-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-18-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-18-storage","backing":"libvirt-19-format"}' \ +-blockdev '{"driver":"nbd","server":{"type":"unix","path":"/var/run/nbdsock"},\ +"export":"bar","node-name":"libvirt-17-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-17-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-17-storage","backing":"libvirt-18-format"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-17-format,\ id=virtio-disk1 \ --drive file=gluster://example.org:6000/Volume1/Image,file.debug=4,format=raw,\ -if=none,id=drive-virtio-disk2 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"gluster","volume":"Volume1","path":"Image",\ +"server":[{"type":"inet","host":"example.org","port":"6000"}],"debug":4,\ +"node-name":"libvirt-16-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-16-format","read-only":false,"driver":"raw",\ +"file":"libvirt-16-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-16-format,\ id=virtio-disk2 \ --object secret,id=virtio-disk3-secret0,\ +-blockdev '{"driver":"file","filename":"/tmp/image.qcow",\ +"node-name":"libvirt-15-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-15-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-15-storage","backing":null}' \ +-object secret,id=libvirt-14-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive 'file=rbd:pool/image:id=myname:auth_supported=cephx\;none:\ -mon_host=mon1.example.org\:6321\;mon2.example.org\:6322\;mon3.example.org\:\ -6322,file.password-secret=virtio-disk3-secret0,format=qcow2,if=none,\ -id=drive-virtio-disk3' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk3,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image",\ +"server":[{"host":"mon1.example.org","port":"6321"},{"host":"mon2.example.org",\ +"port":"6322"},{"host":"mon3.example.org","port":"6322"}],"user":"myname",\ +"auth-client-required":["cephx","none"],\ +"key-secret":"libvirt-14-storage-secret0","node-name":"libvirt-14-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-14-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-14-storage","backing":"libvirt-15-format"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-14-format,\ id=virtio-disk3 \ --drive file=/dev/HostVG/QEMUGuest11,format=qcow2,if=none,id=drive-virtio-disk4 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk4,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest11",\ +"node-name":"libvirt-13-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-13-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-13-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-13-format,\ id=virtio-disk4 \ --drive file=/var/lib/libvirt/images/rhel7.1484071880,format=qcow2,if=none,\ -id=drive-virtio-disk5 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=drive-virtio-disk5,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/rhel7.qcow2",\ +"node-name":"libvirt-12-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-12-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-12-storage","backing":null}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483536402",\ +"node-name":"libvirt-11-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-11-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-11-storage","backing":"libvirt-12-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483545313",\ +"node-name":"libvirt-10-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-10-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-10-storage","backing":"libvirt-11-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483545901",\ +"node-name":"libvirt-9-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-9-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-9-storage","backing":"libvirt-10-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483546244",\ +"node-name":"libvirt-8-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-8-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-8-storage","backing":"libvirt-9-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483605920",\ +"node-name":"libvirt-7-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-7-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-7-storage","backing":"libvirt-8-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483605924",\ +"node-name":"libvirt-6-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-6-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-6-storage","backing":"libvirt-7-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1483615252",\ +"node-name":"libvirt-5-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-5-storage","backing":"libvirt-6-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1484071872",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-4-storage","backing":"libvirt-5-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1484071876",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-3-storage","backing":"libvirt-4-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1484071877",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"qcow2",\ +"file":"libvirt-2-storage","backing":"libvirt-3-format"}' \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/rhel7.1484071880",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage","backing":"libvirt-2-format"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=libvirt-1-format,\ id=virtio-disk5 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x8 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ diff --git a/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args index 7ea6d5b4d5..cf2bfe83b7 100644 --- a/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args @@ -28,25 +28,45 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device lsi,id=scsi0,bus=pci.0,addr=0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\ -cache=writeback \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-5-storage","cache":{"direct":false,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,\ +"cache":{"direct":false,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-5-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-5-format,id=ide0-0-0,bootindex=1,\ write-cache=on \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-1,\ -cache=unsafe \ --device ide-hd,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-4-storage","cache":{"direct":false,"no-flush":true},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,\ +"cache":{"direct":false,"no-flush":true},"driver":"qcow2",\ +"file":"libvirt-4-storage"}' \ +-device ide-hd,bus=ide.0,unit=1,drive=libvirt-4-format,id=ide0-0-1,\ write-cache=on \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-scsi0-0-0,\ -cache=none \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-3-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-3-storage"}' \ -device scsi-hd,bus=scsi0.0,scsi-id=0,device_id=drive-scsi0-0-0,\ -drive=drive-scsi0-0-0,id=scsi0-0-0,write-cache=on \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-virtio-disk0,\ -cache=writethrough \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ +drive=libvirt-3-format,id=scsi0-0-0,write-cache=on \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-2-storage","cache":{"direct":false,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,\ +"cache":{"direct":false,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-2-format,\ id=virtio-disk0,write-cache=off \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-usb-disk1,\ -cache=directsync \ --device usb-storage,bus=usb.0,port=1,drive=drive-usb-disk1,id=usb-disk1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device usb-storage,bus=usb.0,port=1,drive=libvirt-1-format,id=usb-disk1,\ removable=off,write-cache=off \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args index cf711c0a3f..056a73c4aa 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args @@ -26,18 +26,26 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-shutdown \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=ftp://host.name:21/url/path/file.iso,format=raw,if=none,\ -id=drive-ide0-0-0,readonly=on \ --device ide-cd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=ftps://host.name:990/url/path/file.iso,format=raw,if=none,\ -id=drive-ide0-0-1,readonly=on \ --device ide-cd,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \ --drive file=https://host.name:443/url/path/file.iso,format=raw,if=none,\ -id=drive-ide0-1-0,readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \ --drive file=tftp://host.name:69/url/path/file.iso,format=raw,if=none,\ -id=drive-ide0-1-1,readonly=on \ --device ide-cd,bus=ide.1,unit=1,drive=drive-ide0-1-1,id=ide0-1-1 \ +-blockdev '{"driver":"ftp","url":"ftp://host.name:21/url/path/file.iso",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":true,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device ide-cd,bus=ide.0,unit=0,drive=libvirt-4-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"ftps","url":"ftps://host.name:990/url/path/file.iso",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":true,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device ide-cd,bus=ide.0,unit=1,drive=libvirt-3-format,id=ide0-0-1 \ +-blockdev '{"driver":"https","url":"https://host.name:443/url/path/file.iso",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-2-format,id=ide0-1-0 \ +-blockdev '{"driver":"tftp","url":"tftp://host.name:69/url/path/file.iso",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=1,drive=libvirt-1-format,id=ide0-1-1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args index ad17416851..65974ca759 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args @@ -27,15 +27,23 @@ file=/tmp/lib/domain--1-test/master-key.aes \ -no-acpi \ -boot menu=on,strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/var/lib/libvirt/images/f14.img,format=qcow2,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/f14.img",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-3-format,\ id=virtio-disk0,bootindex=2 \ --drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\ -id=drive-ide0-1-0,readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,bootindex=1 \ --drive if=none,id=drive-ide0-1-1,readonly=on \ --device ide-cd,bus=ide.1,unit=1,drive=drive-ide0-1-1,id=ide0-1-1 \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-2-format,id=ide0-1-0,bootindex=1 \ +-blockdev '{"driver":"file","filename":"/tmp/cdrom.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=1,drive=libvirt-1-format,id=ide0-1-1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args index bacef71aad..a32daba5e7 100644 --- a/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args @@ -27,15 +27,18 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/root/boot.iso,format=raw,if=none,id=drive-ide0-0-1,readonly=on \ --device ide-cd,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \ --drive if=none,id=drive-ide0-1-0,readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\ -write-cache=on \ --drive if=none,id=drive-ide0-1-1,readonly=on \ --device ide-cd,bus=ide.1,unit=1,drive=drive-ide0-1-1,id=ide0-1-1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-4-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"file","filename":"/root/boot.iso",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":true,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device ide-cd,bus=ide.0,unit=1,drive=libvirt-3-format,id=ide0-0-1 \ +-device ide-cd,bus=ide.1,unit=0,id=ide0-1-0,write-cache=on \ +-device ide-cd,bus=ide.1,unit=1,id=ide0-1-1 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args b/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args index 1f1d37c957..58bab55572 100644 --- a/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args @@ -28,13 +28,20 @@ file=/tmp/lib/domain--1-test/master-key.aes \ -boot menu=on,strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \ --drive file=/var/lib/libvirt/images/f14.img,format=qcow2,if=none,\ -id=drive-virtio-disk0,copy-on-read=on \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/f14.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-2-storage"}' \ +-blockdev '{"driver":"copy-on-read","node-name":"libvirt-CoR-vda",\ +"file":"libvirt-2-format"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-CoR-vda,\ id=virtio-disk0,bootindex=2 \ --drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\ -id=drive-ide0-1-0,readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,bootindex=1 \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=1 \ -netdev user,id=hostnet0 \ -device virtio-net-pci,tx=bh,netdev=hostnet0,id=net0,mac=52:54:00:e5:48:58,\ bus=pci.0,addr=0x2 \ diff --git a/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args b/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args index b48c0f8d43..381956291c 100644 --- a/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args @@ -27,13 +27,18 @@ file=/tmp/lib/domain--1-test/master-key.aes \ -no-acpi \ -boot menu=on,strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/var/lib/libvirt/images/f14.img,format=qcow2,if=none,\ -id=drive-virtio-disk0,discard=unmap,detect-zeroes=unmap \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/f14.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"discard":"unmap",\ +"detect-zeroes":"unmap","driver":"qcow2","file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-2-format,\ id=virtio-disk0,bootindex=2 \ --drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\ -id=drive-ide0-1-0,readonly=on,discard=ignore,detect-zeroes=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,bootindex=1 \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"discard":"ignore",\ +"detect-zeroes":"on","driver":"raw","file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args b/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args index ea754cef0f..2ed63972bc 100644 --- a/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args @@ -27,17 +27,29 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\ -cache=none \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-3-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-3-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-3-format,id=ide0-0-0,bootindex=1,\ write-cache=on,werror=stop,rerror=stop \ --drive file=/dev/HostVG/QEMUGuest2,format=qcow2,if=none,id=drive-ide0-0-1,\ -cache=none \ --device ide-hd,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest2",\ +"node-name":"libvirt-2-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-2-storage"}' \ +-device ide-hd,bus=ide.0,unit=1,drive=libvirt-2-format,id=ide0-0-1,\ write-cache=on,werror=enospc \ --drive file=/dev/HostVG/QEMUGuest3,format=qcow2,if=none,id=drive-ide0-1-0,\ -cache=none \ --device ide-hd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest3",\ +"node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,\ write-cache=on,werror=report,rerror=ignore \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args index 02e2b1e76c..81521c2425 100644 --- a/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args @@ -30,9 +30,17 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ addr=0x1 \ -device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ -device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ --drive file=/tmp/firmware.img,format=raw,if=none,id=drive-fdc0-0-0 \ --drive file=/tmp/data.img,format=qcow2,if=none,id=drive-fdc0-0-1 \ --device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1,driveB=drive-fdc0-0-1 \ +-device isa-fdc,bootindexA=1 \ +-blockdev '{"driver":"file","filename":"/tmp/firmware.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device floppy,unit=0,drive=libvirt-2-format,id=fdc0-0-0 \ +-blockdev '{"driver":"file","filename":"/tmp/data.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device floppy,unit=1,drive=libvirt-1-format,id=fdc0-0-1 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args index a158e8e3d3..43aad24a03 100644 --- a/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args @@ -30,9 +30,17 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ addr=0x1 \ -device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ -device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ --drive file=/tmp/firmware.img,format=raw,if=none,id=drive-fdc0-0-0 \ --drive file=/tmp/data.img,format=qcow2,if=none,id=drive-fdc0-0-1 \ --device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1,driveB=drive-fdc0-0-1 \ +-device isa-fdc,bootindexA=1 \ +-blockdev '{"driver":"file","filename":"/tmp/firmware.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device floppy,unit=0,drive=libvirt-2-format,id=fdc0-0-0 \ +-blockdev '{"driver":"file","filename":"/tmp/data.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device floppy,unit=1,drive=libvirt-1-format,id=fdc0-0-1 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args index f2ce94a330..1376eaeed6 100644 --- a/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args @@ -27,12 +27,21 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/dev/fd0,format=raw,if=none,id=drive-fdc0-0-0 \ --drive file=/tmp/firmware.img,format=raw,if=none,id=drive-fdc0-0-1 \ --global isa-fdc.driveA=drive-fdc0-0-0 \ --global isa-fdc.driveB=drive-fdc0-0-1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-3-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/fd0",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device floppy,unit=0,drive=libvirt-2-format,id=fdc0-0-0 \ +-blockdev '{"driver":"file","filename":"/tmp/firmware.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device floppy,unit=1,drive=libvirt-1-format,id=fdc0-0-1 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args index c34abe89b4..76aeccf6d8 100644 --- a/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args @@ -27,20 +27,28 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=gluster://example.org:6000/Volume1/Image,file.debug=4,format=raw,\ -if=none,id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"gluster","volume":"Volume1","path":"Image",\ +"server":[{"type":"inet","host":"example.org","port":"6000"}],"debug":4,\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-3-format,\ id=virtio-disk0,bootindex=1 \ --drive 'file=gluster+unix:///Volume2/Image?socket=/path/to/sock,file.debug=4,\ -format=raw,if=none,id=drive-virtio-disk1' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"gluster","volume":"Volume2","path":"Image",\ +"server":[{"type":"unix","path":"/path/to/sock"}],"debug":4,\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-2-format,\ id=virtio-disk1 \ --drive file.driver=gluster,file.volume=Volume3,file.path=Image.qcow2,\ -file.server.0.type=tcp,file.server.0.host=example.org,file.server.0.port=6000,\ -file.server.1.type=tcp,file.server.1.host=example.org,file.server.1.port=24007,\ -file.server.2.type=unix,file.server.2.socket=/path/to/sock,file.debug=4,\ -format=qcow2,if=none,id=drive-virtio-disk2 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"gluster","volume":"Volume3","path":"Image.qcow2",\ +"server":[{"type":"inet","host":"example.org","port":"6000"},{"type":"inet",\ +"host":"example.org","port":"24007"},{"type":"unix","path":"/path/to/sock"}],\ +"debug":4,"node-name":"libvirt-1-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-1-format,\ id=virtio-disk2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args index 19fcd97c80..5bf3e350df 100644 --- a/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args @@ -28,39 +28,49 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device virtio-scsi-pci,id=scsi0,bus=pci.0,addr=0x2 \ --drive file.driver=iscsi,file.portal=example.org:6000,\ -file.target=iqn.1992-01.com.example,file.lun=0,file.transport=tcp,format=raw,\ -if=none,id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"iscsi","portal":"example.org:6000",\ +"target":"iqn.1992-01.com.example","lun":0,"transport":"tcp",\ +"node-name":"libvirt-5-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,"driver":"raw",\ +"file":"libvirt-5-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-5-format,\ id=virtio-disk0,bootindex=1 \ --drive file.driver=iscsi,file.portal=example.org:6000,\ -file.target=iqn.1992-01.com.example,file.lun=1,file.transport=tcp,format=raw,\ -if=none,id=drive-virtio-disk1 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"iscsi","portal":"example.org:6000",\ +"target":"iqn.1992-01.com.example","lun":1,"transport":"tcp",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-4-format,\ id=virtio-disk1 \ --object secret,id=virtio-disk2-secret0,\ +-object secret,id=libvirt-3-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive file.driver=iscsi,file.portal=example.org:6000,\ -file.target=iqn.1992-01.com.example:storage,file.lun=1,file.transport=tcp,\ -file.user=myname,file.password-secret=virtio-disk2-secret0,format=raw,if=none,\ -id=drive-virtio-disk2 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"iscsi","portal":"example.org:6000",\ +"target":"iqn.1992-01.com.example:storage","lun":1,"transport":"tcp",\ +"user":"myname","password-secret":"libvirt-3-storage-secret0",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-3-format,\ id=virtio-disk2 \ --object secret,id=virtio-disk3-secret0,\ +-object secret,id=libvirt-2-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive file.driver=iscsi,file.portal=example.org:6000,\ -file.target=iqn.1992-01.com.example:storage,file.lun=2,file.transport=tcp,\ -file.user=myname,file.password-secret=virtio-disk3-secret0,format=raw,if=none,\ -id=drive-virtio-disk3 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk3,\ +-blockdev '{"driver":"iscsi","portal":"example.org:6000",\ +"target":"iqn.1992-01.com.example:storage","lun":2,"transport":"tcp",\ +"user":"myname","password-secret":"libvirt-2-storage-secret0",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-2-format,\ id=virtio-disk3 \ --drive file.driver=iscsi,file.portal=example.org:3260,\ -file.target=iqn.1992-01.com.example,file.lun=0,file.transport=tcp,format=raw,\ -if=none,id=drive-scsi0-0-0-0 \ +-blockdev '{"driver":"iscsi","portal":"example.org:3260",\ +"target":"iqn.1992-01.com.example","lun":0,"transport":"tcp",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-block,bus=scsi0.0,channel=0,scsi-id=0,lun=0,\ -drive=drive-scsi0-0-0-0,id=scsi0-0-0-0 \ +drive=libvirt-1-format,id=scsi0-0-0-0 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args index 554387358a..95ef39093c 100644 --- a/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args @@ -27,22 +27,39 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=nbd:example.org:6000,format=raw,if=none,id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"nbd","server":{"type":"inet","host":"example.org",\ +"port":"6000"},"node-name":"libvirt-5-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,"driver":"raw",\ +"file":"libvirt-5-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-5-format,\ id=virtio-disk0,bootindex=1 \ --drive file=nbd:example.org:6000:exportname=bar,format=raw,if=none,\ -id=drive-virtio-disk1 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"nbd","server":{"type":"inet","host":"example.org",\ +"port":"6000"},"export":"bar","node-name":"libvirt-4-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-4-format,\ id=virtio-disk1 \ --drive 'file=nbd://[::1]:6000,format=raw,if=none,id=drive-virtio-disk2' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"nbd","server":{"type":"inet","host":"::1","port":"6000"},\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-3-format,\ id=virtio-disk2 \ --drive 'file=nbd://[::1]:6000/bar,format=raw,if=none,id=drive-virtio-disk3' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk3,\ +-blockdev '{"driver":"nbd","server":{"type":"inet","host":"::1","port":"6000"},\ +"export":"bar","node-name":"libvirt-2-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-2-format,\ id=virtio-disk3 \ --drive file=nbd:unix:/var/run/nbdsock:exportname=bar,format=raw,if=none,\ -id=drive-virtio-disk4 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk4,\ +-blockdev '{"driver":"nbd","server":{"type":"unix","path":"/var/run/nbdsock"},\ +"export":"bar","node-name":"libvirt-1-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-1-format,\ id=virtio-disk4 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args index 98297d8872..28cea02729 100644 --- a/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args @@ -27,37 +27,56 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive 'file=rbd:pool/image:auth_supported=none:mon_host=mon1.example.org\:\ -6321\;mon2.example.org\:6322\;mon3.example.org\:6322,format=raw,if=none,\ -id=drive-virtio-disk0' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image",\ +"server":[{"host":"mon1.example.org","port":"6321"},{"host":"mon2.example.org",\ +"port":"6322"},{"host":"mon3.example.org","port":"6322"}],\ +"node-name":"libvirt-6-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-6-format","read-only":false,"driver":"raw",\ +"file":"libvirt-6-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-6-format,\ id=virtio-disk0,bootindex=1 \ --drive file=rbd:pool/image@asdf:auth_supported=none,format=raw,if=none,\ -id=drive-virtio-disk1 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image","snapshot":"asdf",\ +"node-name":"libvirt-5-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,"driver":"raw",\ +"file":"libvirt-5-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-5-format,\ id=virtio-disk1 \ --drive 'file=rbd:pool/image@foo:auth_supported=none:mon_host=mon1.example.org\:\ -6321\;mon2.example.org\:6322\;mon3.example.org\:6322,format=raw,if=none,\ -id=drive-virtio-disk2' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image","snapshot":"foo",\ +"server":[{"host":"mon1.example.org","port":"6321"},{"host":"mon2.example.org",\ +"port":"6322"},{"host":"mon3.example.org","port":"6322"}],\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-4-format,\ id=virtio-disk2 \ --drive file=rbd:pool/image@foo:auth_supported=none:conf=/blah/test.conf,\ -format=raw,if=none,id=drive-virtio-disk3 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk3,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image","snapshot":"foo",\ +"conf":"/blah/test.conf","node-name":"libvirt-3-storage","auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-3-format,\ id=virtio-disk3 \ --object secret,id=virtio-disk4-secret0,\ +-object secret,id=libvirt-2-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive 'file=rbd:pool/image:id=myname:auth_supported=cephx\;none:\ -mon_host=mon1.example.org\:6321\;mon2.example.org\:6322\;mon3.example.org\:\ -6322,file.password-secret=virtio-disk4-secret0,format=raw,if=none,\ -id=drive-virtio-disk4' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk4,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image",\ +"server":[{"host":"mon1.example.org","port":"6321"},{"host":"mon2.example.org",\ +"port":"6322"},{"host":"mon3.example.org","port":"6322"}],"user":"myname",\ +"auth-client-required":["cephx","none"],\ +"key-secret":"libvirt-2-storage-secret0","node-name":"libvirt-2-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-2-format,\ id=virtio-disk4 \ --drive 'file=rbd:pool/image:auth_supported=none:mon_host=[\:\:1]\:\ -6321\;example.org\:6789\;[ffff\:1234\:567\:abc\:\:0f]\:6322\;[2001\:db8\:\:\ -ff00\:42\:8329]\:6322,format=raw,if=none,id=drive-virtio-disk5' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=drive-virtio-disk5,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image",\ +"server":[{"host":"::1","port":"6321"},{"host":"example.org","port":"6789"},\ +{"host":"ffff:1234:567:abc::0f","port":"6322"},\ +{"host":"2001:db8::ff00:42:8329","port":"6322"}],\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=libvirt-1-format,\ id=virtio-disk5 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args index 011c02ba88..c2b1156f0c 100644 --- a/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args @@ -27,11 +27,17 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMU,,Guest,,,,1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=sheepdog:example.org:6000:image,,with,,commas,format=raw,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMU,Guest,,1",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-2-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"sheepdog","server":{"type":"inet","host":"example.org",\ +"port":"6000"},"vdi":"image,with,commas","node-name":"libvirt-1-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-1-format,\ id=virtio-disk0 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args index 9bc67a1c40..357a277c46 100644 --- a/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args @@ -27,23 +27,29 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --object secret,id=virtio-disk0-secret0,\ +-object secret,id=libvirt-2-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive file.driver=iscsi,file.portal=example.org:6000,\ -file.target=iqn.1992-01.com.example:storage,file.lun=1,file.transport=tcp,\ -file.user=myname,file.password-secret=virtio-disk0-secret0,format=raw,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"iscsi","portal":"example.org:6000",\ +"target":"iqn.1992-01.com.example:storage","lun":1,"transport":"tcp",\ +"user":"myname","password-secret":"libvirt-2-storage-secret0",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x2,drive=libvirt-2-format,\ id=virtio-disk0,bootindex=1 \ --object secret,id=virtio-disk1-secret0,\ +-object secret,id=libvirt-1-storage-secret0,\ data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\ keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \ --drive 'file=rbd:pool/image:id=myname:auth_supported=cephx\;none:\ -mon_host=mon1.example.org\:6321\;mon2.example.org\:6322\;mon3.example.org\:\ -6322,file.password-secret=virtio-disk1-secret0,format=raw,if=none,\ -id=drive-virtio-disk1' \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk1,\ +-blockdev '{"driver":"rbd","pool":"pool","image":"image",\ +"server":[{"host":"mon1.example.org","port":"6321"},{"host":"mon2.example.org",\ +"port":"6322"},{"host":"mon3.example.org","port":"6322"}],"user":"myname",\ +"auth-client-required":["cephx","none"],\ +"key-secret":"libvirt-1-storage-secret0","node-name":"libvirt-1-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=libvirt-1-format,\ id=virtio-disk1 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-network-tlsx509.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-tlsx509.x86_64-latest.args index c043de80d8..fa729cb6e8 100644 --- a/tests/qemuxml2argvdata/disk-network-tlsx509.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-tlsx509.x86_64-latest.args @@ -28,34 +28,50 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --object tls-creds-x509,id=objvirtio-disk0_tls0,dir=/etc/pki/libvirt-vxhs/dummy,\ -,path,endpoint=client,verify-peer=yes \ --drive file.driver=vxhs,file.tls-creds=objvirtio-disk0_tls0,\ -file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc251,\ -file.server.host=192.168.0.1,file.server.port=9999,format=raw,if=none,\ -id=drive-virtio-disk0,cache=none \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ +-object tls-creds-x509,id=objlibvirt-4-storage_tls0,\ +dir=/etc/pki/libvirt-vxhs/dummy,,path,endpoint=client,verify-peer=yes \ +-blockdev '{"driver":"vxhs","tls-creds":"objlibvirt-4-storage_tls0",\ +"vdisk-id":"eb90327c-8302-4725-9e1b-4e85ed4dc251",\ +"server":{"host":"192.168.0.1","port":"9999"},"node-name":"libvirt-4-storage",\ +"cache":{"direct":true,"no-flush":false},"auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=libvirt-4-format,\ id=virtio-disk0,bootindex=1,write-cache=on,\ serial=eb90327c-8302-4725-9e1b-4e85ed4dc251 \ --object tls-creds-x509,id=objvirtio-disk1_tls0,dir=/etc/pki/libvirt-vxhs/dummy,\ -,path,endpoint=client,verify-peer=yes \ --drive file.driver=vxhs,file.tls-creds=objvirtio-disk1_tls0,\ -file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc252,\ -file.server.host=192.168.0.2,file.server.port=9999,format=raw,if=none,\ -id=drive-virtio-disk1,cache=none \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk1,\ +-object tls-creds-x509,id=objlibvirt-3-storage_tls0,\ +dir=/etc/pki/libvirt-vxhs/dummy,,path,endpoint=client,verify-peer=yes \ +-blockdev '{"driver":"vxhs","tls-creds":"objlibvirt-3-storage_tls0",\ +"vdisk-id":"eb90327c-8302-4725-9e1b-4e85ed4dc252",\ +"server":{"host":"192.168.0.2","port":"9999"},"node-name":"libvirt-3-storage",\ +"cache":{"direct":true,"no-flush":false},"auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-3-format,\ id=virtio-disk1,write-cache=on,serial=eb90327c-8302-4725-9e1b-4e85ed4dc252 \ --drive file.driver=vxhs,file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc253,\ -file.server.host=192.168.0.3,file.server.port=9999,format=raw,if=none,\ -id=drive-virtio-disk2,cache=none \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk2,\ +-blockdev '{"driver":"vxhs","vdisk-id":"eb90327c-8302-4725-9e1b-4e85ed4dc253",\ +"server":{"host":"192.168.0.3","port":"9999"},"node-name":"libvirt-2-storage",\ +"cache":{"direct":true,"no-flush":false},"auto-read-only":true,\ +"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-2-format,\ id=virtio-disk2,write-cache=on,serial=eb90327c-8302-4725-9e1b-4e85ed4dc252 \ --object tls-creds-x509,id=objvirtio-disk3_tls0,dir=/etc/pki/libvirt-nbd/dummy,,\ -path,endpoint=client,verify-peer=yes \ --drive file.driver=nbd,file.server.type=inet,file.server.host=example.com,\ -file.server.port=1234,file.tls-creds=objvirtio-disk3_tls0,format=raw,if=none,\ -id=drive-virtio-disk3,cache=none \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=drive-virtio-disk3,\ +-object tls-creds-x509,id=objlibvirt-1-storage_tls0,\ +dir=/etc/pki/libvirt-nbd/dummy,,path,endpoint=client,verify-peer=yes \ +-blockdev '{"driver":"nbd","server":{"type":"inet","host":"example.com",\ +"port":"1234"},"tls-creds":"objlibvirt-1-storage_tls0",\ +"node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=libvirt-1-format,\ id=virtio-disk3,write-cache=on \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args b/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args index c325c6fe76..5ca36c0871 100644 --- a/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args @@ -27,10 +27,16 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/dev/sr0,format=raw,if=none,id=drive-ide0-1-0,readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-2-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/sr0",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args b/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args index 9661115009..7cff9c94b6 100644 --- a/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args @@ -28,11 +28,17 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device lsi,id=scsi0,bus=pci.0,addr=0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/tmp/scsidisk.img,format=raw,if=none,id=drive-scsi0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-2-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"file","filename":"/tmp/scsidisk.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-hd,bus=scsi0.0,scsi-id=0,device_id=drive-scsi0-0-0,\ -drive=drive-scsi0-0-0,id=scsi0-0-0 \ +drive=libvirt-1-format,id=scsi0-0-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args b/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args index 7bf011fd5f..ad07d206d6 100644 --- a/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args @@ -31,21 +31,36 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -device megasas,id=scsi1,bus=pci.0,addr=0x3 \ -device mptsas1068,id=scsi2,bus=pci.0,addr=0x4 \ -device spapr-vscsi,id=scsi3,reg=0x00002000 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/tmp/scsidisk.img,format=raw,if=none,id=drive-scsi0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-5-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-5-format","read-only":false,"driver":"raw",\ +"file":"libvirt-5-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-5-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"file","filename":"/tmp/scsidisk.img",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw",\ +"file":"libvirt-4-storage"}' \ -device scsi-hd,bus=scsi0.0,scsi-id=0,device_id=drive-scsi0-0-0,\ -drive=drive-scsi0-0-0,id=scsi0-0-0 \ --drive file=/tmp/scsidisk2.img,format=raw,if=none,id=drive-scsi1-0-0-0 \ +drive=libvirt-4-format,id=scsi0-0-0 \ +-blockdev '{"driver":"file","filename":"/tmp/scsidisk2.img",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ -device scsi-hd,bus=scsi1.0,channel=0,scsi-id=0,lun=0,device_id=abcdefghijklmn,\ -drive=drive-scsi1-0-0-0,id=scsi1-0-0-0,serial=abcdefghijklmn \ --drive file=/tmp/scsidisk3.img,format=raw,if=none,id=drive-scsi2-0-0-0 \ +drive=libvirt-3-format,id=scsi1-0-0-0,serial=abcdefghijklmn \ +-blockdev '{"driver":"file","filename":"/tmp/scsidisk3.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ -device scsi-hd,bus=scsi2.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi2-0-0-0,drive=drive-scsi2-0-0-0,id=scsi2-0-0-0,\ +device_id=drive-scsi2-0-0-0,drive=libvirt-2-format,id=scsi2-0-0-0,\ wwn=0x5000c50015ea71ac \ --drive file=/tmp/scsidisk4.img,format=raw,if=none,id=drive-scsi3-0-0-0 \ +-blockdev '{"driver":"file","filename":"/tmp/scsidisk4.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-hd,bus=scsi3.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi3-0-0-0,drive=drive-scsi3-0-0-0,id=scsi3-0-0-0 \ +device_id=drive-scsi3-0-0-0,drive=libvirt-1-format,id=scsi3-0-0-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x5 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args b/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args index afc2549442..375e2de560 100644 --- a/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args @@ -28,20 +28,36 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device virtio-scsi-pci,id=scsi0,bus=pci.0,addr=0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0,\ -cache=none \ --device ide-hd,bus=ide.0,unit=0,share-rw=on,drive=drive-ide0-0-0,id=ide0-0-0,\ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-4-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-4-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,share-rw=on,drive=libvirt-4-format,id=ide0-0-0,\ bootindex=1,write-cache=on,serial=XYZXYZXYZYXXYZYZYXYZY \ --drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\ -readonly=on \ --device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \ --drive file=/dev/scsi,format=raw,if=none,id=drive-scsi0-0-0-0,cache=none \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest2",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":true,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device ide-cd,bus=ide.1,unit=0,drive=libvirt-3-format,id=ide0-1-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/scsi",\ +"node-name":"libvirt-2-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-2-storage"}' \ -device scsi-hd,bus=scsi0.0,channel=0,scsi-id=0,lun=0,\ -device_id=drive-scsi0-0-0-0,share-rw=on,drive=drive-scsi0-0-0-0,id=scsi0-0-0-0,\ +device_id=drive-scsi0-0-0-0,share-rw=on,drive=libvirt-2-format,id=scsi0-0-0-0,\ write-cache=on \ --drive file=/dev/virtio,format=raw,if=none,id=drive-virtio-disk0,cache=none \ +-blockdev '{"driver":"host_device","filename":"/dev/virtio",\ +"node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,share-rw=on,\ -drive=drive-virtio-disk0,id=virtio-disk0,write-cache=on \ +drive=libvirt-1-format,id=virtio-disk0,write-cache=on \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x4 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args b/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args index 746dbdedfe..bd07929eec 100644 --- a/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args @@ -30,16 +30,22 @@ path=/tmp/lib/domain--1-QEMUGuest1/pr-helper0.sock \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device virtio-scsi-pci,id=scsi0,num_queues=8,bus=pci.0,addr=0x3 \ --drive file=/dev/HostVG/QEMUGuest1,file.pr-manager=pr-helper0,format=raw,\ -if=none,id=drive-scsi0-0-0-0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"pr-manager":"pr-helper0","node-name":"libvirt-2-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ -device scsi-block,bus=scsi0.0,channel=0,scsi-id=0,lun=0,\ -drive=drive-scsi0-0-0-0,id=scsi0-0-0-0,bootindex=1 \ --object pr-manager-helper,id=pr-helper-scsi0-0-0-1,\ +drive=libvirt-2-format,id=scsi0-0-0-0,bootindex=1 \ +-object pr-manager-helper,id=pr-helper-libvirt-1-storage,\ path=/path/to/qemu-pr-helper.sock \ --drive file=/dev/HostVG/QEMUGuest2,file.pr-manager=pr-helper-scsi0-0-0-1,\ -format=raw,if=none,id=drive-scsi0-0-0-1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest2",\ +"pr-manager":"pr-helper-libvirt-1-storage","node-name":"libvirt-1-storage",\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-block,bus=scsi0.0,channel=0,scsi-id=0,lun=1,\ -drive=drive-scsi0-0-0-1,id=scsi0-0-0-1 \ +drive=libvirt-1-format,id=scsi0-0-0-1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x4 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args b/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args index 2e6f893fad..1bf202659e 100644 --- a/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args +++ b/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args @@ -27,9 +27,12 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=fat:floppy:/var/somefiles,if=none,id=drive-fdc0-0-0,readonly=on \ --global isa-fdc.driveA=drive-fdc0-0-0 \ -global isa-fdc.bootindexA=1 \ +-blockdev '{"driver":"vvfat","dir":"/var/somefiles","floppy":true,"rw":false,\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device floppy,unit=0,drive=libvirt-1-format,id=fdc0-0-0 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args index c78272eadc..d7b86e6270 100644 --- a/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args @@ -25,8 +25,11 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -display egl-headless,rendernode=/dev/dri/foo \ -device cirrus-vga,id=video0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ diff --git a/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args index c78272eadc..d7b86e6270 100644 --- a/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args @@ -25,8 +25,11 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -display egl-headless,rendernode=/dev/dri/foo \ -device cirrus-vga,id=video0,bus=pci.0,addr=0x2 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ diff --git a/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args b/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args index bc66de1f76..df4c565a17 100644 --- a/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args +++ b/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args @@ -30,16 +30,25 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ -device virtio-scsi-pci,iothread=iothread2,id=scsi0,bus=pci.0,addr=0xb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ --drive file=/var/lib/libvirt/images/iothrtest1.img,format=raw,if=none,\ -id=drive-virtio-disk1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw",\ +"file":"libvirt-3-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-3-format,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/iothrtest1.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw",\ +"file":"libvirt-2-storage"}' \ -device virtio-blk-pci,iothread=iothread1,scsi=off,bus=pci.0,addr=0x4,\ -drive=drive-virtio-disk1,id=virtio-disk1 \ --drive file=/var/lib/libvirt/images/iothrtest2.img,format=raw,if=none,\ -id=drive-scsi0-0-0-3 \ +drive=libvirt-2-format,id=virtio-disk1 \ +-blockdev '{"driver":"file",\ +"filename":"/var/lib/libvirt/images/iothrtest2.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device scsi-hd,bus=scsi0.0,channel=0,scsi-id=0,lun=3,\ -device_id=drive-scsi0-0-0-3,drive=drive-scsi0-0-0-3,id=scsi0-0-0-3 \ +device_id=drive-scsi0-0-0-3,drive=libvirt-1-format,id=scsi0-0-0-3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args index e694496b84..ee860097e8 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args @@ -31,8 +31,11 @@ share=no,size=536870912 \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args index 3eef32b324..9705dcd137 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args @@ -31,8 +31,11 @@ share=no,size=536870912,align=2097152 \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args index 6217a27ad1..b3f750456c 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args @@ -31,8 +31,11 @@ share=no,size=536870912 \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args index b2987205f3..07ec6b68fa 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args @@ -31,8 +31,11 @@ share=no,size=536870912,pmem=on \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args index 498c13c50f..0b7a379914 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args @@ -31,8 +31,11 @@ share=no,size=536870912 \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args index 87c928a540..2d7cdedcf4 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args @@ -31,8 +31,11 @@ size=536870912 \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\ resourcecontrol=deny \ diff --git a/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args b/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args index d1a25d5c62..2112c10576 100644 --- a/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args +++ b/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args @@ -27,9 +27,13 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=on \ -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --drive file=/var/lib/libvirt/images/QEMUGuest1,format=qcow2,if=none,\ -id=drive-ide0-0-0,cache=none \ --device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/QEMUGuest1",\ +"node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},\ +"auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,\ +"cache":{"direct":true,"no-flush":false},"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device ide-hd,bus=ide.0,unit=0,drive=libvirt-1-format,id=ide0-0-0,bootindex=1,\ write-cache=on \ -device bochs-display,id=video0,vgamem=16384k,bus=pci.0,addr=0x2 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \ diff --git a/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args index 3688709092..7fa2c6ed5f 100644 --- a/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args @@ -42,9 +42,12 @@ multifunction=on,addr=0x2 \ -device virtio-scsi-pci-non-transitional,id=scsi0,bus=pci.4,addr=0x0 \ -device virtio-serial-pci-non-transitional,id=virtio-serial0,bus=pci.3,\ addr=0x0 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-virtio-disk0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device virtio-blk-pci-non-transitional,scsi=off,bus=pci.5,addr=0x0,\ -drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 \ +drive=libvirt-1-format,id=virtio-disk0,bootindex=1 \ -fsdev local,security_model=passthrough,id=fsdev-fs0,path=/export/fs1 \ -device virtio-9p-pci-non-transitional,id=fs0,fsdev=fsdev-fs0,mount_tag=fs1,\ bus=pci.1,addr=0x0 \ diff --git a/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args index 9d4ec5f922..dea7e0d3f3 100644 --- a/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args @@ -32,9 +32,12 @@ addr=0x1 \ -device pcie-root-port,port=0x9,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x1 \ -device virtio-scsi-pci-transitional,id=scsi0,bus=pci.2,addr=0x4 \ -device virtio-serial-pci-transitional,id=virtio-serial0,bus=pci.2,addr=0x3 \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-virtio-disk0 \ +-blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw",\ +"file":"libvirt-1-storage"}' \ -device virtio-blk-pci-transitional,scsi=off,bus=pci.2,addr=0x5,\ -drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 \ +drive=libvirt-1-format,id=virtio-disk0,bootindex=1 \ -fsdev local,security_model=passthrough,id=fsdev-fs0,path=/export/fs1 \ -device virtio-9p-pci-transitional,id=fs0,fsdev=fsdev-fs0,mount_tag=fs1,\ bus=pci.2,addr=0x1 \ diff --git a/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args index 4875a8799e..7c9c5a0bc6 100644 --- a/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args @@ -30,9 +30,11 @@ file=/tmp/lib/domain--1-guest/master-key.aes \ -boot strict=on \ -device qemu-xhci,p2=15,p3=15,id=usb,bus=pci.0,addr=0x4 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x5 \ --drive file=/var/lib/libvirt/images/guest.qcow2,format=qcow2,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/guest.qcow2",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x6,drive=libvirt-1-format,\ id=virtio-disk0,bootindex=1 \ -netdev user,id=hostnet0 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:4c:e3:86,bus=pci.0,\ diff --git a/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args index cc33248272..7f825462aa 100644 --- a/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args @@ -31,9 +31,11 @@ file=/tmp/lib/domain--1-guest/master-key.aes \ -boot strict=on \ -device qemu-xhci,p2=15,p3=15,id=usb,bus=pci.0,addr=0x3 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x4 \ --drive file=/var/lib/libvirt/images/guest.qcow2,format=qcow2,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/guest.qcow2",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=libvirt-1-format,\ id=virtio-disk0,bootindex=1 \ -netdev user,id=hostnet0 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:09:a4:37,bus=pci.0,\ diff --git a/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args index 8e1f1cc865..52fa25898d 100644 --- a/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args @@ -38,9 +38,11 @@ multifunction=on,addr=0x2 \ -device pcie-root-port,port=0x16,chassis=7,id=pci.7,bus=pcie.0,addr=0x2.0x6 \ -device qemu-xhci,p2=15,p3=15,id=usb,bus=pci.2,addr=0x0 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.3,addr=0x0 \ --drive file=/var/lib/libvirt/images/guest.qcow2,format=qcow2,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.4,addr=0x0,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/guest.qcow2",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.4,addr=0x0,drive=libvirt-1-format,\ id=virtio-disk0,bootindex=1 \ -netdev user,id=hostnet0 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:d2:70:0b,bus=pci.1,\ diff --git a/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args index b3fb8d8340..0cda5c3227 100644 --- a/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args @@ -39,9 +39,11 @@ addr=0x1 \ -device pcie-root-port,port=0xe,chassis=7,id=pci.7,bus=pcie.0,addr=0x1.0x6 \ -device qemu-xhci,p2=15,p3=15,id=usb,bus=pci.2,addr=0x0 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.3,addr=0x0 \ --drive file=/var/lib/libvirt/images/guest.qcow2,format=qcow2,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,scsi=off,bus=pci.4,addr=0x0,drive=drive-virtio-disk0,\ +-blockdev '{"driver":"file","filename":"/var/lib/libvirt/images/guest.qcow2",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=off,bus=pci.4,addr=0x0,drive=libvirt-1-format,\ id=virtio-disk0,bootindex=1 \ -netdev user,id=hostnet0 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:09:a4:37,bus=pci.1,\ -- 2.21.0

On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
https://bugzilla.redhat.com/show_bug.cgi?id=1658981
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I am very much in favour of getting some testing before releasing such big changes. Any way of not including this in release tarballs is fine, but we should also not completely give up on non-blockdev approach until we do actually release it, if only because by having this in for the whole development period only to disable it for release would mean that we are releasing something we did not test at all for a whole cycle. Yeah, I know the above does not give a clear answer or solution, but that is because I am ambivalent about it. But I'm not against having this in git to test it. Since the change itself is fairly trivial you can consider it Reviewed-but-not-tested-by: me =)

On Fri, Sep 13, 2019 at 23:35:47 +0200, Martin Kletzander wrote:
On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
https://bugzilla.redhat.com/show_bug.cgi?id=1658981
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I am very much in favour of getting some testing before releasing such big changes. Any way of not including this in release tarballs is fine, but we should also not completely give up on non-blockdev approach until we do actually release it, if only because by having this in for the whole development period only to disable it for release would mean that we are releasing something we did not test at all for a whole cycle.
At this point it would be more like half of a cycle. Also once we enable it anyways (even for some future-qemu-only) the testing given will decrease by time into the almost-bitrot region. To facilitate some deliberate testing I've added the possibility to control the qemu capability bits from the qemu namespace: https://libvirt.org/drvqemu.html#xmlnsfeatures That allows developers and uses who wish to experiment to deliberately disable any feature. (Obviously resulting breakage may be considered unsupported)

On Sat, Sep 14, 2019 at 10:55:59AM +0200, Peter Krempa wrote:
On Fri, Sep 13, 2019 at 23:35:47 +0200, Martin Kletzander wrote:
On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
https://bugzilla.redhat.com/show_bug.cgi?id=1658981
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I am very much in favour of getting some testing before releasing such big changes. Any way of not including this in release tarballs is fine, but we should also not completely give up on non-blockdev approach until we do actually release it, if only because by having this in for the whole development period only to disable it for release would mean that we are releasing something we did not test at all for a whole cycle.
At this point it would be more like half of a cycle. Also once we enable it anyways (even for some future-qemu-only) the testing given will decrease by time into the almost-bitrot region.
To facilitate some deliberate testing I've added the possibility to control the qemu capability bits from the qemu namespace:
Still, without enabling it, how many people will actually enable it for their domains to try it out before we release it. Maybe when setting it we could do something along the lines of: if (virRandom() < .5 || we_are_in_tests) { if (!we_are_in_tests) { VIR_INFO("You are a lucky winner! This domain (%s) " "will now use blockdev if possible!", vm->def->name); } virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_BLOCKDEV); } And then revert this particular part before releasing. Or is that way too crazy? I mean the `.5` constant can be changed, but it is closest to gradual testing as you can get with projects like libvirt.
That allows developers and uses who wish to experiment to deliberately disable any feature. (Obviously resulting breakage may be considered unsupported)
does that mark the domain as tainted? Probably no because it is already visible from the XML, right? I'm asking purely from curiosity. Have a nice weekend!
-- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
What are the chances of that bug actually getting fixed any time in the forseeable future ? savevm has been a pain for a long time since it blocks QEMU and we've been waiting for it to be fixedd by QEMU devs for at least 7-8 years now, and I don't see anyone from QEMU block maintainers commenting on this new BZ to indicate they're going to fix this latest problem.
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I'd only be in favour of enabling it if there is some clear time frame on whicht hat bug above is likely to be fixed. I'm guesing it is pretty unlikely to be fixed before our freeze, so I thinking speculatively enabling it is premature.
Any other ideas?
We already have the option you added to allow capabilities to be force enabled for people to test with, though admittedly that is going to get fairly limited usage. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|

(ccing Kevin) On Mon, Sep 16, 2019 at 10:14:44 +0100, Daniel Berrange wrote:
On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
What are the chances of that bug actually getting fixed any time in the forseeable future ?
savevm has been a pain for a long time since it blocks QEMU and we've been waiting for it to be fixedd by QEMU devs for at least 7-8 years now, and I don't see anyone from QEMU block maintainers commenting on this new BZ to indicate they're going to fix this latest problem.
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I'd only be in favour of enabling it if there is some clear time frame on whicht hat bug above is likely to be fixed. I'm guesing it is pretty unlikely to be fixed before our freeze, so I thinking speculatively enabling it is premature.
I'm not sure. Kevin, any idea when we can expect the fix? Otherwise the only option to enable blockdev would be to just enable it and blame qemu for internal snapshots not working.

Am 16.09.2019 um 11:32 hat Peter Krempa geschrieben:
(ccing Kevin)
On Mon, Sep 16, 2019 at 10:14:44 +0100, Daniel Berrange wrote:
On Fri, Sep 13, 2019 at 02:43:53PM +0200, Peter Krempa wrote:
To my knowledge, everything in libvirt is now prepared to fully use -blockdev way to configure disks in qemu.
There is one known qemu bug though: Internal snapshots don't work with -blockdev:
What are the chances of that bug actually getting fixed any time in the forseeable future ?
savevm has been a pain for a long time since it blocks QEMU and we've been waiting for it to be fixedd by QEMU devs for at least 7-8 years now, and I don't see anyone from QEMU block maintainers commenting on this new BZ to indicate they're going to fix this latest problem.
Since I can't in good faith ask for merging this patchset yet I'd like to give it some more testing I'm suggesting that we push it and revert it during freeze or add a capability check once qemu is fixed.
I'd only be in favour of enabling it if there is some clear time frame on whicht hat bug above is likely to be fixed. I'm guesing it is pretty unlikely to be fixed before our freeze, so I thinking speculatively enabling it is premature.
I'm not sure. Kevin, any idea when we can expect the fix?
Otherwise the only option to enable blockdev would be to just enable it and blame qemu for internal snapshots not working.
The main problem with implementing a fix was that it's unclear what the desired result even is. After some discussion with Max, I think we'll try it with restricting snapshotting to everything that is directly attached to a BlockBackend and monitor-owned nodes that don't have any parents. Kevin

On Mon, Sep 16, 2019 at 16:29:01 +0200, Kevin Wolf wrote:
Am 16.09.2019 um 11:32 hat Peter Krempa geschrieben:
[...]
I'd only be in favour of enabling it if there is some clear time frame on whicht hat bug above is likely to be fixed. I'm guesing it is pretty unlikely to be fixed before our freeze, so I thinking speculatively enabling it is premature.
I'm not sure. Kevin, any idea when we can expect the fix?
Otherwise the only option to enable blockdev would be to just enable it and blame qemu for internal snapshots not working.
The main problem with implementing a fix was that it's unclear what the desired result even is. After some discussion with Max, I think we'll try it with restricting snapshotting to everything that is directly attached to a BlockBackend and monitor-owned nodes that don't have any parents.
Yes that is what I would expect as well, and possibly also consistent with a 'drive_add with if=none' being used but not the corresponding -device. (thus no frontend).
participants (4)
-
Daniel P. Berrangé
-
Kevin Wolf
-
Martin Kletzander
-
Peter Krempa