Description of problem: Set group name by blkdeviotune when on other options are set, the group name is set in domain xml, but it doesn't take effect actually as seen from the query result of blkceviotune. Version-Release number of selected component (if applicable): libvirt-3.2.0-9.virtcov.el7.x86_64 How reproducible: 100% Steps to Reproduce: 1.Start a guest with no blkdeviotune parameters 2.# virsh blkdeviotune rhel7.4 vda total_bytes_sec: 0 read_bytes_sec : 0 write_bytes_sec: 0 total_iops_sec : 0 read_iops_sec : 0 write_iops_sec : 0 total_bytes_sec_max: 0 read_bytes_sec_max: 0 write_bytes_sec_max: 0 total_iops_sec_max: 0 read_iops_sec_max: 0 write_iops_sec_max: 0 size_iops_sec : 0 group_name : total_bytes_sec_max_length: 0 read_bytes_sec_max_length: 0 write_bytes_sec_max_length: 0 total_iops_sec_max_length: 0 read_iops_sec_max_length: 0 write_iops_sec_max_length: 0 3.# virsh blkdeviotune rhel7.4 vda --group-name test 4.# virsh blkdeviotune rhel7.4 vda total_bytes_sec: 0 read_bytes_sec : 0 write_bytes_sec: 0 total_iops_sec : 0 read_iops_sec : 0 write_iops_sec : 0 total_bytes_sec_max: 0 read_bytes_sec_max: 0 write_bytes_sec_max: 0 total_iops_sec_max: 0 read_iops_sec_max: 0 write_iops_sec_max: 0 size_iops_sec : 0 group_name : ==> group name is not set total_bytes_sec_max_length: 0 read_bytes_sec_max_length: 0 write_bytes_sec_max_length: 0 total_iops_sec_max_length: 0 read_iops_sec_max_length: 0 write_iops_sec_max_length: 0 5.# virsh dumpxml rhel7.4|grep group -a1 <iotune> <group_name>test</group_name> ==> group name is set in domain xml </iotune> 6. # virsh blkdeviotune rhel7.4 vda --total-iops-sec 1000000000000000 7. # virsh blkdeviotune rhel7.4 vda total_bytes_sec: 0 read_bytes_sec : 0 write_bytes_sec: 0 total_iops_sec : 1000000000000000 read_iops_sec : 0 write_iops_sec : 0 total_bytes_sec_max: 0 read_bytes_sec_max: 0 write_bytes_sec_max: 0 total_iops_sec_max: 100000000000000 read_iops_sec_max: 0 write_iops_sec_max: 0 size_iops_sec : 0 group_name : drive-virtio-disk0 ===> the default value is used. total_bytes_sec_max_length: 0 read_bytes_sec_max_length: 0 write_bytes_sec_max_length: 0 total_iops_sec_max_length: 1 read_iops_sec_max_length: 0 write_iops_sec_max_length: 0 8.But in guest dumpxml, group name is "test": # virsh dumpxml rhel7.4|grep group <group_name>test</group_name> Actual results: As description Expected results: Refuse to set group name when no other options are set.
This bug is going to be addressed in next major release.
Possibly fixed by https://www.redhat.com/archives/libvir-list/2020-January/msg01278.html
Michal, can you please confirm if the patches from comment 3 fixes this issue? If not please move it to backlog. Thanks.
Yes, it's fixed upstream by following commits: 93b66b3cbb qemu: when leaving iotune group update xml properly 57ac9f5eef qemu: get defaults from iotune group we move disk into bb36ae81a0 qemu: fix using defaults when setting persistent iotune params dd94f36ffb qemu: check iotune params same for all disk in group e7efffe6cb qemu: propagate iotune settings to all disks in the group eb4455daab conf: expand iotune params if only group name is given 67ebd6ac26 qemu: Move qemuDiskConfigBlkdeviotuneHas* to conf v6.0.0-172-g93b66b3cbb
Verified with: libvirt-6.5.0-1.module+el8.3.0+7323+d54bb644.x86_64 Steps: 1. Having a vm disk, which has no blkdeviotune params set [root@libvirt-rhel-8 ~]# virsh blkdeviotune vm1 vda total_bytes_sec: 0 read_bytes_sec : 0 write_bytes_sec: 0 total_iops_sec : 0 read_iops_sec : 0 write_iops_sec : 0 total_bytes_sec_max: 0 read_bytes_sec_max: 0 write_bytes_sec_max: 0 total_iops_sec_max: 0 read_iops_sec_max: 0 write_iops_sec_max: 0 size_iops_sec : 0 group_name : total_bytes_sec_max_length: 0 read_bytes_sec_max_length: 0 write_bytes_sec_max_length: 0 total_iops_sec_max_length: 0 read_iops_sec_max_length: 0 write_iops_sec_max_length: 0 2. Try to add a group name for it. [root@libvirt-rhel-8 ~]# virsh blkdeviotune vm1 vda --group-name test error: Unable to change block I/O throttle error: unsupported configuration: creating a new group/updating existing with all tune parameters zero is not supported [root@libvirt-rhel-8 ~]# virsh blkdeviotune vm1 vda --group-name test --config error: Unable to change block I/O throttle error: unsupported configuration: creating a new group/updating existing with all tune parameters zero is not supported [root@libvirt-rhel-8 ~]# virsh destroy vm1 Domain vm1 destroyed [root@libvirt-rhel-8 ~]# virsh blkdeviotune vm1 vda --group-name test --config error: Unable to change block I/O throttle error: unsupported configuration: creating a new group/updating existing with all tune parameters zero is not supported
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:8.3 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-2020:5137