Incorrect Max CPU's per VM in libvirt if cluster compatibility 4.6 or 4.7

Hello, I recently upgraded our cluster from 4.3 to 4.5 (4.5.1.3-1.el8), I raised the cluster compatibility afterwards to 4.7 as well. I noticed that the CPU hot plugging does not work above 16 CPU's if cluster compatibility is set to 4.6 or 4.7. Error I get is: Failed to hot set number of CPUS to VM testVM-3. Underlying error message: invalid argument: requested vcpus is greater than max allowable vcpus for the live domain: 32 > 16 Issue here I believe is that the MaxNumOfVmSockets values set on the engine per cluster version is not correctly set on libvirt when VM is started. My values on the engine: MaxNumOfVmSockets: 32 version: 4.2 MaxNumOfVmSockets: 32 version: 4.3 MaxNumOfVmSockets: 32 version: 4.4 MaxNumOfVmSockets: 32 version: 4.5 MaxNumOfVmSockets: 64 version: 4.6 MaxNumOfVmSockets: 10000 version: 4.7 Values on libvirt for VM's for all cluster compatibility versions: 4.3 <vcpu placement='static' current='4'>32</vcpu> 4.4 <vcpu placement='static' current='4'>32</vcpu> 4.5 <vcpu placement='static' current='4'>32</vcpu> 4.6 <vcpu placement='static' current='4'>16</vcpu> 4.7 <vcpu placement='static' current='4'>16</vcpu> Is anyone else experiencing this issue (possible BUG)? Regards, David

"David Sekne" <david.sekne@gmail.com> writes:
Hello,
I recently upgraded our cluster from 4.3 to 4.5 (4.5.1.3-1.el8), I raised the cluster compatibility afterwards to 4.7 as well. I noticed that the CPU hot plugging does not work above 16 CPU's if cluster compatibility is set to 4.6 or 4.7.
Error I get is: Failed to hot set number of CPUS to VM testVM-3. Underlying error message: invalid argument: requested vcpus is greater than max allowable vcpus for the live domain: 32 > 16
Issue here I believe is that the MaxNumOfVmSockets values set on the engine per cluster version is not correctly set on libvirt when VM is started.
My values on the engine: MaxNumOfVmSockets: 32 version: 4.2 MaxNumOfVmSockets: 32 version: 4.3 MaxNumOfVmSockets: 32 version: 4.4 MaxNumOfVmSockets: 32 version: 4.5 MaxNumOfVmSockets: 64 version: 4.6 MaxNumOfVmSockets: 10000 version: 4.7
Values on libvirt for VM's for all cluster compatibility versions:
4.3 <vcpu placement='static' current='4'>32</vcpu>
4.4 <vcpu placement='static' current='4'>32</vcpu>
4.5 <vcpu placement='static' current='4'>32</vcpu>
4.6 <vcpu placement='static' current='4'>16</vcpu>
4.7 <vcpu placement='static' current='4'>16</vcpu>
Is anyone else experiencing this issue (possible BUG)?
It's most likely a feature. Starting with 4.6, the maximum number of vCPUs is limited because it consumes resources even if the CPUs are not plugged in. Adjusting sockets/cores/threads configuration of the VM to put more than one vCPU on a socket or changing MaxNumOfCpusCoefficient config value should help in your case. Regards, Milan

Hello, Not sure about the feature part. I additionally tested this on oVirt 4.4.10.7-1.el8 and it works fine even if cluster compatibility there is set to 4.6. Engine: MaxNumOfVmSockets: 32 version: 4.2 MaxNumOfVmSockets: 32 version: 4.3 MaxNumOfVmSockets: 32 version: 4.4 MaxNumOfVmSockets: 32 version: 4.5 MaxNumOfVmSockets: 32 version: 4.6 VM: <vcpu placement='static' current='4'>32</vcpu> Regards, David

"David Sekne" <david.sekne@gmail.com> writes:
Hello,
Not sure about the feature part. I additionally tested this on oVirt 4.4.10.7-1.el8 and it works fine even if cluster compatibility there is set to 4.6.
Before oVirt 4.5, MaxNumOfCpusCoefficient was applied only if the maximum number of the VM vCPU sockets was higher than 16. Now, it is applied more strictly (although there are still some exceptions, which is probably why you see 16 max vCPUs rather than 8). This means MaxNumOfCpusCoefficient value cannot be ignored anymore in some scenarios. If you need to hot plug more vCPUs than the number of the initial vCPUs, you should change MaxNumOfCpusCoefficient. Regards, Milan
Engine: MaxNumOfVmSockets: 32 version: 4.2 MaxNumOfVmSockets: 32 version: 4.3 MaxNumOfVmSockets: 32 version: 4.4 MaxNumOfVmSockets: 32 version: 4.5 MaxNumOfVmSockets: 32 version: 4.6
VM: <vcpu placement='static' current='4'>32</vcpu>
Regards, David _______________________________________________ Users mailing list -- users@ovirt.org To unsubscribe send an email to users-leave@ovirt.org Privacy Statement: https://www.ovirt.org/privacy-policy.html oVirt Code of Conduct: https://www.ovirt.org/community/about/community-guidelines/ List Archives: https://lists.ovirt.org/archives/list/users@ovirt.org/message/MBRDAXKCA5GFRR...

Hello, To confirm, changing MaxNumOfCpusCoefficient solved my issue. <vcpu placement='static' current='4'>64</vcpu> Thank you for the help. Regards, David
participants (2)
-
David Sekne
-
Milan Zamazal