Description of problem: When trying to attach external volume (EBS, via iSCSI) to a VM that has IOThreads configured, I get following error. Version-Release number of selected component (if applicable): libvirt-7.4.0-1.el8s.x86_64 qemu-kvm-6.0.0-19.el8s.x86_64 How reproducible: Always. Steps to Reproduce: Sadly I don't have some easy reproduction scenario. Actual results: libvirt.libvirtError: unsupported configuration: IOThreads only available for virtio pci and virtio ccw disk Expected results: No error. Additional info: I was able to find that this used to be an issue long time ago (https://bugzilla.redhat.com/show_bug.cgi?id=1430275) but it was fixed then, so probably it is regression again. This actually happens with packages of CentOS Virtualization SIG (which is kinda maintained by Red Hat) and I could not find better place where to report this bug.
FTR previously libvirt was accepting this action and XML it generated was: <disk type='block' device='disk'> <driver name='qemu' type='raw' cache='none' io='native' iothread='2'/> <source dev='/dev/dm-58' index='4'/> <backingStore/> <target dev='vdc' bus='virtio'/> <serial>05fcc448-4775-4692-9c22-f931d3356ca1</serial> <alias name='virtio-disk2'/> <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/> </disk>
This has been introduced by a following commit (reverting fixes the problem): commit 3df66f27a606c5c0f27958edf7bfaaf7dcc71264 Author: Peter Krempa <pkrempa> Date: Fri Apr 30 16:19:15 2021 +0200 qemu: Move iothread and s390 address validation for disk devices into the validator The "machine-loadparm-multiple-disks-nets-s390" case now requires the QEMU_CAPS_CCW feature to pass validation. Signed-off-by: Peter Krempa <pkrempa> Reviewed-by: Ján Tomko <jtomko> Reviewed-by: Pavel Hrdina <phrdina>
Fixed upstream: commit c29bb0fbb623af7994925bccad04060c5e27b64b Author: Peter Krempa <pkrempa> Date: Thu Jun 10 16:43:36 2021 +0200 qemu: validate: Don't check bus type in qemuValidateDomainDeviceDefDiskIOThreads IOThreads are supported with all 3 currently supported buses which can have virtio devices (PCI, CCW, MMIO) , so there's no need for this check. Additionally this check was buggy in the current location as on e.g. hotplug cases the address may not yet be assigned for the disk and thus a bogus error would be printed. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1970277 Signed-off-by: Peter Krempa <pkrempa> Reviewed-by: Ján Tomko <jtomko> v7.4.0-161-gc29bb0fbb6
Fixed on libvirt-7.5.0-1.module+el8.5.0+11664+59f87560.x86_64 Test case: rhel.cpu.iothread.negative_test.disk_attach.delete_without_detach
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (virt:av bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2021:4684