Nathan March
2014-Aug-26 23:52 UTC
[CentOS-virt] Masking CPU flags via libvirt xml not working?
Hi,
Has anyone here managed to get cpu masking working via libvirt?
Intention to enable VM migrations between hosts of a different CPU
generation.
Inside my xml I'm providing the model as well as a list of features to
specifically disable, but none of it seems to take any effect. On
booting the VM I still see the disabled flags in /proc/cpuinfo
<cpu match='exact' mode='custom'>
<arch>x86_64</arch>
<model fallback='forbid'>Westmere</model>
<feature policy='disable' name='dtherm'/>
<feature policy='disable' name='erms'/>
<feature policy='disable' name='fsgsbase'/>
<feature policy='disable' name='pts'/>
<feature policy='disable' name='pln'/>
<feature policy='disable' name='rdrand'/>
<feature policy='disable' name='f16c'/>
<feature policy='disable' name='aes'/>
<feature policy='disable' name='tsc_deadline_timer'/>
<feature policy='disable' name='x2apic'/>
<feature policy='disable' name='dtherm'/>
<feature policy='disable' name='pclmulqdq'/>
</cpu>
Doing a dumpxml against the domU once it's booted leaves out the entire
<cpu> section, leading me to think maybe libvirt is dropping it for some
reason. I've got the above <cpu> just in the main <domain>
section.
Anyone have this working or able to offer some suggestions?
Thanks!
- Nathan
Nathan March
2014-Aug-27 18:08 UTC
[CentOS-virt] Masking CPU flags via libvirt xml not working?
On 8/26/2014 4:52 PM, Nathan March wrote:> > Has anyone here managed to get cpu masking working via libvirt? > Intention to enable VM migrations between hosts of a different CPU > generation. >To add to this, I've tried using the boot options to set the cpu mask instead: xen_commandline : dom0_mem=2048M,max:2048M loglvl=all guest_loglvl=all cpuid_mask_ecx=0x009ee3fd cpuid_mask_edx=0xbfebfbff Unfortunately still no luck. There's no errors in xm dmesg to indicate the settings were / weren't applied, it simply doesn't seem to do anything. - Nathan