Description of problem: vdsm calculations to vcpu topology are creating topologies rejected by libvirt: ... <vcpu current="3">160</vcpu> ... <cpu match="exact"> <model>Westmere</model> <topology cores="3" sockets="53" threads="1"/> </cpu> ... Thread-34::ERROR::2014-07-18 16:33:27,746::vm::2286::vm.Vm::(_startUnderlyingVm) vmId=`a128612f-6ab0-4b8d-89ff-5585b5565605`::The vm start process failed Traceback (most recent call last): File "/usr/share/vdsm/vm.py", line 2246, in _startUnderlyingVm self._run() File "/usr/share/vdsm/vm.py", line 3186, in _run self._connection.createXML(domxml, flags), File "/usr/lib64/python2.6/site-packages/vdsm/libvirtconnection.py", line 92, in wrapper ret = f(*args, **kwargs) File "/usr/lib64/python2.6/site-packages/libvirt.py", line 2665, in createXML if ret is None:raise libvirtError('virDomainCreateXML() failed', conn=self) libvirtError: Maximum CPUs greater than topology limit Version-Release number of selected component (if applicable): vdsm-4.14.7-3.el6ev.x86_64 How reproducible: 100% Steps to Reproduce: 1. Create and set "cores" with a number that 160 is not multiple of. 2. Start VM 3. Even approved by the CPU filter (which limites the vCPUS up to the Host physical CPUs number), the VM creation will fail due the unnacepted topology by libvirt.
*** Bug 1122014 has been marked as a duplicate of this bug. ***
How to verify (after speaking with rgolan): 1. Max VM vcpu cores should be 16 2. Max VM vcpu sockets should be 16 3. The product of vcpu sockets*cores*threads should be equal or smaller than 160. 4. Check in engine-config the values of max vcpu cores, and max vcpu sockets. 5. Check in vdsm.log, VM xml, that following start VM, after setting, for example: cores = 16, sockets = 8, threads = 1, that the maximum vcpu in xml = 124 (the product of these 3 params).
Verified on vt6: 1. Max VM vcpu cores should be 16 - OK 2. Max VM vcpu sockets should be 16 - OK 3. The product of vcpu sockets*cores <=160 - OK 4. Check in engine-config the values of max vcpu cores, and max vcpu sockets. [root@dhcp160-207 ~]# engine-config -g MaxNumOfCpuPerSocket MaxNumOfCpuPerSocket: 16 version: 3.0 MaxNumOfCpuPerSocket: 16 version: 3.1 MaxNumOfCpuPerSocket: 16 version: 3.2 MaxNumOfCpuPerSocket: 16 version: 3.3 MaxNumOfCpuPerSocket: 16 version: 3.4 MaxNumOfCpuPerSocket: 16 version: 3.5 [root@dhcp160-207 ~]# engine-config -g MaxNumOfVmCpus MaxNumOfVmCpus: 160 version: 3.1 MaxNumOfVmCpus: 160 version: 3.2 MaxNumOfVmCpus: 160 version: 3.3 MaxNumOfVmCpus: 160 version: 3.4 MaxNumOfVmCpus: 160 version: 3.5 MaxNumOfVmCpus: 64 version: 3.0 5. Check in vdsm.log, VM xml, that following start VM, the maximum vcpu in xml = cores * sockets * threads
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, 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://rhn.redhat.com/errata/RHBA-2015-0159.html