Description of problem: Due to libvirt Bug 1017858 an attempt to unplug a CPU will return an error although the actual CPUs will be unplugged. this causes an inconsistency in the engine view of the CPU count of the VM. To reflect this inconsistency we would provide the "Actual CPU count" under the static provisioned CPU count which today consist of Cores/Sockets and Sockets example: After setting the number of sockets to 1 we get a failure. After the report has been collected from the VM we should see: VMs -> General subtab Sockets: 2 Cores Per Sockets: 2 Actual CPU allocation: 2 vCpus -> tooltip: "2/1/1 2 cores 1 socket 1 thread"
Tested on av9.1, guest: rhel6.5, kernel 2.6.32-431.17.1.el6.x86_64. As rhevm-guest-image version yet support cpu guest reporting, I used this special rhem-guest-image version, rhevm-guest-agent-1.0.9-2.el6ev.src.rpm, x86_64: https://brewweb.devel.redhat.com/taskinfo?taskID=7461052 UI "Guest CPU Count" field indeed reflect the actual cpu number, same as seen using 'lscpu' on a rhel6.5 guest. For cpu hot Plug via UI & via vdsm ('vdsClient -s 0 setNumberOfCpus {vmId} , {number}') "Guest CPU Count" field was updated correctly. For cpu hot Unplug via 'vdsClient -s 0 setNumberOfCpus {vmId} {number}' , "Guest CPU Count" field was updated correctly. Te cpu hot unplug is blocked vi UI for av9.1, and thus used here the vdsm command instead. Important to mention here that for a kernel from lower version (kernel 2.6.32-431) the cpu hot unplug gives an error: "Operation not supported: qemu didn't unplug the vCPUs properly".
Closing as part of 3.4.0