can hotplug vcpus to running Windows 10 guest, but not unplug

Hi, i'm playing a bit around with vcpus. My guest is Windows 10 1903. This is the excerpt from the config: ... <vcpu placement='static' current='2'>4</vcpu> <vcpus> <vcpu id='0' enabled='yes' hotpluggable='no'/> <vcpu id='1' enabled='yes' hotpluggable='yes'/> <vcpu id='2' enabled='no' hotpluggable='yes'/> <vcpu id='3' enabled='no' hotpluggable='yes'/> </vcpus> ... I'm able to hotplug vcpus, but when i want to unplug them i get the following: virsh # setvcpus pathway 3 --live virsh # setvcpus pathway 4 --live virsh # setvcpus pathway 2 --live error: internal error: unable to execute QEMU command 'device_del': acpi: device unplug request for not supported device type: qemu64-x86_64-cpu Does anyone know why it can't be unplugged ? Thanks. Brtnf -- Bernd Lentes Systemadministration Institute for Metabolism and Cell Death (MCD) Building 35.34 - Raum 208 HelmholtzZentrum münchen bernd.lentes@helmholtz-muenchen.de phone: +49 89 3187 1241 phone: +49 89 3187 3827 fax: +49 89 3187 2294 http://www.helmholtz-muenchen.de/mcd Perfekt ist wer keine Fehler macht Also sind Tote perfekt Helmholtz Zentrum München Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

On Fri, Feb 14, 2020 at 16:05:00 +0100, Lentes, Bernd wrote:
Hi,
i'm playing a bit around with vcpus. My guest is Windows 10 1903. This is the excerpt from the config: ... <vcpu placement='static' current='2'>4</vcpu> <vcpus> <vcpu id='0' enabled='yes' hotpluggable='no'/> <vcpu id='1' enabled='yes' hotpluggable='yes'/> <vcpu id='2' enabled='no' hotpluggable='yes'/> <vcpu id='3' enabled='no' hotpluggable='yes'/> </vcpus> ...
I'm able to hotplug vcpus, but when i want to unplug them i get the following:
virsh # setvcpus pathway 3 --live virsh # setvcpus pathway 4 --live virsh # setvcpus pathway 2 --live error: internal error: unable to execute QEMU command 'device_del': acpi: device unplug request for not supported device type: qemu64-x86_64-cpu
Does anyone know why it can't be unplugged ?
Sounds like qemu doesn't support unplug of vcpus. Which version of qemu do you use?

----- On Feb 14, 2020, at 4:13 PM, Peter Krempa pkrempa@redhat.com wrote:
Sounds like qemu doesn't support unplug of vcpus. Which version of qemu do you use?
ha-idg-2:~ # rpm -qa|grep qemu qemu-seabios-1.11.0-5.18.1.noarch qemu-ovmf-x86_64-2017+git1510945757.b2662641d5-3.16.1.noarch qemu-block-curl-2.11.2-5.18.1.x86_64 qemu-sgabios-8-5.18.1.noarch qemu-x86-2.11.2-5.18.1.x86_64 libvirt-daemon-qemu-4.0.0-8.15.2.x86_64 qemu-ipxe-1.0.0+-5.18.1.noarch qemu-tools-2.11.2-5.18.1.x86_64 qemu-vgabios-1.11.0-5.18.1.noarch qemu-block-ssh-2.11.2-5.18.1.x86_64 qemu-kvm-2.11.2-5.18.1.x86_64 qemu-2.11.2-5.18.1.x86_64 libvirt-daemon-driver-qemu-4.0.0-8.15.2.x86_64 qemu-block-rbd-2.11.2-5.18.1.x86_64 I found a table on https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/htm... saying that hotplugging is possible but no hotunplugging. But i don't know how recent this information is and if RedHat uses libvirt/qemu. Bernd Helmholtz Zentrum München Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

On Fri, Feb 14, 2020 at 4:54 PM Lentes, Bernd < bernd.lentes@helmholtz-muenchen.de> wrote:
qemu-kvm-2.11.2-5.18.1.x86_64
[...]
I found a table on https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/htm... saying that hotplugging is possible but no hotunplugging. But i don't know how recent this information is and if RedHat uses libvirt/qemu.
RHV uses a special version of qemu-kvm named qemu-kvm-rhev. oVirt, the upstream product of RHV, uses a rebuilt package named qemu-kvm-ev. Eg in oVirt 4.3.8, that is the latest stable release available right now and should apply to your doc link limitations is qemu-kvm-ev-2.12.0-33.1.el7_7.4.x86_64 What is the OS of your hypervisor? In case of CentOS 7 and not a production one, you could enable the repo from CentOS-SIG-Virtualization like this: https://wiki.centos.org/SpecialInterestGroup/Virtualization A repo entry is this one below: [ovirt-4.3-centos-qemu-ev] name=CentOS-7 - QEMU EV baseurl=http://mirror.centos.org/centos/7/virt/$basearch/kvm-common/ gpgcheck=1 enabled=1 gpgkey=https://www.centos.org/keys/RPM-GPG-KEY-CentOS-SIG-Virtualization Then deinstall qemu-kvm and install qemu-kvm-ev. I don't remember if yum would detect qemu-kvm as an "obsolete" version of qemu-kvm-ev, probably yes and in this case you would only need to run yum install qemu-kvm-ev and it will replace the old. Browse the repo packages in case, because it would bring in for example also another version of seabios (I don't see libvirt packages in between). But anyway for your special case also with qemu-kvm-ev it seems no Windows OS is supported for hot unplug. HIH, Gianluca

On 2/14/20 11:17 AM, Gianluca Cecchi wrote:
On Fri, Feb 14, 2020 at 4:54 PM Lentes, Bernd <bernd.lentes@helmholtz-muenchen.de <mailto:bernd.lentes@helmholtz-muenchen.de>> wrote:
qemu-kvm-2.11.2-5.18.1.x86_64
[...]
I found a table on https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/htm... saying that hotplugging is possible but no hotunplugging. But i don't know how recent this information is and if RedHat uses libvirt/qemu.
RHV uses a special version of qemu-kvm named qemu-kvm-rhev. oVirt, the upstream product of RHV, uses a rebuilt package named qemu-kvm-ev.
Just to make sure there's no misunderstanding about the content of these special versions of the qemu-kvm package, I wanted to point out that the qemu-kvm-rhev/qemu-kvm-ev used by RHV/oVirt (and also OpenStack) are actually *closer* to upstream qemu, not further away, than the standard qemu-kvm package in the same release of RHEL/CentOS. Everything in *all* the different builds of the package is upstream, but the -rhev/-ev versions of the packages have a more aggressive rebase-from-upstream schedule, and also have more not-yet-in-the-rebase features that are backported from later upstream releases. The result is that the standard RHEL/CentOS qemu-kvm package is more stable (since it mostly only gets bugfixes), while the -rhev/-ev packages have more new features (at the risk of encountering regressions due to the new code in those features) Backporting of new features to a downstream release can sometimes mean that a feature not present in qemu-kvm-x.y.z upstream *is* present in qemu-kvm-rhev-x.y.z, so looking at the upstream documentation might lead you to believe the package you're using doesn't have feature X, when actually it does. But before that can happen, the feature must have already gone upstream and be available there (just in a slightly higher-numbered, but earlier-released, version). "Upstream first" isn't just a nice idea, it's the rule (and a way of life)! :-)

Would you mind sharing your xml? I have strange high host load on idle windows guest/domain -----Original Message----- Sent: 14 February 2020 16:05 To: libvirt-ML Subject: can hotplug vcpus to running Windows 10 guest, but not unplug Hi, i'm playing a bit around with vcpus. My guest is Windows 10 1903. This is the excerpt from the config: ... <vcpu placement='static' current='2'>4</vcpu> <vcpus> <vcpu id='0' enabled='yes' hotpluggable='no'/> <vcpu id='1' enabled='yes' hotpluggable='yes'/> <vcpu id='2' enabled='no' hotpluggable='yes'/> <vcpu id='3' enabled='no' hotpluggable='yes'/> </vcpus> ... I'm able to hotplug vcpus, but when i want to unplug them i get the following: virsh # setvcpus pathway 3 --live virsh # setvcpus pathway 4 --live virsh # setvcpus pathway 2 --live error: internal error: unable to execute QEMU command 'device_del': acpi: device unplug request for not supported device type: qemu64-x86_64-cpu Does anyone know why it can't be unplugged ? Thanks. Brtnf -- Bernd Lentes Systemadministration Institute for Metabolism and Cell Death (MCD) Building 35.34 - Raum 208 HelmholtzZentrum münchen bernd.lentes@helmholtz-muenchen.de phone: +49 89 3187 1241 phone: +49 89 3187 3827 fax: +49 89 3187 2294 http://www.helmholtz-muenchen.de/mcd Perfekt ist wer keine Fehler macht Also sind Tote perfekt Helmholtz Zentrum München Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

----- On Feb 15, 2020, at 12:47 AM, Marc Roos M.Roos@f1-outsourcing.eu wrote:
Would you mind sharing your xml? I have strange high host load on idle windows guest/domain
<domain type='kvm'> <name>pathway</name> <uuid>8235e5ae-0756-4286-5407-9fa02d372046</uuid> <description>Pathway Studio Dietrich</description> <memory unit='KiB'>16146944</memory> <currentMemory unit='KiB'>4147456</currentMemory> <!-- maxMemory unit='KiB' slots='8'>16146944</maxMemory --> <vcpu placement='static' current='2'>4</vcpu> <vcpus> <vcpu id='0' enabled='yes' hotpluggable='no'/> <vcpu id='1' enabled='yes' hotpluggable='yes'/> <vcpu id='2' enabled='no' hotpluggable='yes'/> <vcpu id='3' enabled='no' hotpluggable='yes'/> </vcpus> <os> <type arch='x86_64' machine='pc-0.15'>hvm</type> <boot dev='hd'/> </os> <features> <acpi/> <apic/> <pae/> </features> <clock offset='localtime'> <timer name='hpet' present='no'/> </clock> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <pm> <suspend-to-mem enabled='yes'/> <suspend-to-disk enabled='yes'/> </pm> <devices> <emulator>/usr/bin/qemu-kvm</emulator> <disk type='file' device='disk'> <driver name='qemu' type='raw'/> <source file='/mnt/ocfs2/pathway.raw'/> <target dev='hda' bus='ide'/> <address type='drive' controller='0' bus='0' target='0' unit='0'/> </disk> <disk type='file' device='cdrom'> <driver name='qemu' type='raw'/> <target dev='hdc' bus='ide'/> <readonly/> <address type='drive' controller='0' bus='1' target='0' unit='0'/> </disk> <controller type='ide' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/> </controller> <controller type='usb' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/> </controller> <controller type='pci' index='0' model='pci-root'/> <interface type='bridge'> <mac address='52:54:00:37:92:af'/> <source bridge='br0'/> <model type='e1000'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/> </interface> <input type='tablet' bus='usb'/> <input type='mouse' bus='ps2'/> <graphics type='vnc' port='-1' autoport='yes'/> <sound model='ac97'> <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/> </sound> <video> <model type='cirrus' vram='9216' heads='1'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> <memballoon model='virtio'> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/> <stats period='5'/> </memballoon> </devices> </domain> Helmholtz Zentrum München Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

Thanks! Will compare it this weekend! -----Original Message----- Cc: libvirt-ML Subject: Re: can hotplug vcpus to running Windows 10 guest, but not unplug ----- On Feb 15, 2020, at 12:47 AM, Marc Roos M.Roos@f1-outsourcing.eu wrote:
Would you mind sharing your xml? I have strange high host load on idle
windows guest/domain
<domain type='kvm'> <name>pathway</name> <uuid>8235e5ae-0756-4286-5407-9fa02d372046</uuid> <description>Pathway Studio Dietrich</description> <memory unit='KiB'>16146944</memory> <currentMemory unit='KiB'>4147456</currentMemory> <!-- maxMemory unit='KiB' slots='8'>16146944</maxMemory --> <vcpu placement='static' current='2'>4</vcpu> <vcpus> <vcpu id='0' enabled='yes' hotpluggable='no'/> <vcpu id='1' enabled='yes' hotpluggable='yes'/> <vcpu id='2' enabled='no' hotpluggable='yes'/> <vcpu id='3' enabled='no' hotpluggable='yes'/> </vcpus> <os> <type arch='x86_64' machine='pc-0.15'>hvm</type> <boot dev='hd'/> </os> <features> <acpi/> <apic/> <pae/> </features> <clock offset='localtime'> <timer name='hpet' present='no'/> </clock> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <pm> <suspend-to-mem enabled='yes'/> <suspend-to-disk enabled='yes'/> </pm> <devices> <emulator>/usr/bin/qemu-kvm</emulator> <disk type='file' device='disk'> <driver name='qemu' type='raw'/> <source file='/mnt/ocfs2/pathway.raw'/> <target dev='hda' bus='ide'/> <address type='drive' controller='0' bus='0' target='0' unit='0'/> </disk> <disk type='file' device='cdrom'> <driver name='qemu' type='raw'/> <target dev='hdc' bus='ide'/> <readonly/> <address type='drive' controller='0' bus='1' target='0' unit='0'/> </disk> <controller type='ide' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/> </controller> <controller type='usb' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/> </controller> <controller type='pci' index='0' model='pci-root'/> <interface type='bridge'> <mac address='52:54:00:37:92:af'/> <source bridge='br0'/> <model type='e1000'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/> </interface> <input type='tablet' bus='usb'/> <input type='mouse' bus='ps2'/> <graphics type='vnc' port='-1' autoport='yes'/> <sound model='ac97'> <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/> </sound> <video> <model type='cirrus' vram='9216' heads='1'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> <memballoon model='virtio'> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/> <stats period='5'/> </memballoon> </devices> </domain> Helmholtz Zentrum München Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671
participants (5)
-
Gianluca Cecchi
-
Laine Stump
-
Lentes, Bernd
-
Marc Roos
-
Peter Krempa