Hi, we had a similar request from a customer this year, they have three different CPU types in their compute infrastructure. We currently have two CPU models defined in nova-compute.conf: cpu_mode=custom cpu_models = IvyBridge-IBRS,{{ output from virsh capabilities}} IvyBridge-IBRS is the most common one, present on all of the older compute nodes, while the newer ones have either Cascadelake or Broadwell. From the docs [0] I got this statement:
When more than one CPU model is provided, it is expected that the list will be ordered so that the more common and less advanced CPU models are listed first. In selecting the custom mode, along with a named CPU model that matches the oldest of your compute node CPUs, you can ensure that live migration between compute nodes will always be possible. However, you should ensure that the CPU model you select passes the correct CPU feature flags to the guest.
This has been working well for them, they were able to live-migrate between older and newer compute nodes without any issues. Hope this helps! Eugen [0] https://docs.openstack.org/nova/latest/admin/cpu-models.html Zitat von Kees Meijs | Nefos <keesm@nefos.nl>:
Hi,
I'd say take kvm64 as a basis using the custom mode, and then add flags being a common ground over your various CPUs.
We're on a mixed Intel / AMD environment and came up with something like (looking /proc/cpuinfo):
[libvirt] cpu_mode=custom cpu_models=kvm64 cpu_model_extra_flags=various,flags,xsave
Meanwhile xsave seemed to be turned off in some CPU microcode updates, so I suggest leaving that out.
Hope it helps.
Cheers, Kees
__
Kees Meijs BICT
Nefos Cloud & IT <https://nefos.nl/contact>
Nefos IT bv Burgemeester Mollaan 34a 5582 CK Waalre - NL kvk 66494931
+31 (0)88 2088 188 <tel:+31882088188> nefos.nl <https://nefos.nl/contact>
The information contained in this message is intended for the addressee only and may contain classified information. If you are not the addressee, please delete this message and notify the sender; you should not copy or distribute this message or disclose its contents to anyone. Any views or opinions expressed in this message are those of the individual(s) and not necessarily of the organization. No reliance may be placed on this message without written confirmation from an authorised representative of its contents. No guarantee is implied that this message or any attachment is virus free or has not been intercepted and amended.
General terms and conditions ("The NLdigital Terms") apply to all our products and services.
On 29-10-2024 16:44, Andy Speagle wrote:
Hey Folks,
I have some wildly disparate CPUs throughout my nova-compute environment and I'm trying to figure out the best way to find the correct cpu_model and any "extra_flags" that might need to be passed.
According to "virsh capabilities" I have Broadwell-IBRS, Skylake- Server-IBRS and SapphireRapids-noTSX ...
And... my attempts at finding a compatible model/flags has failed miserably.
I tried getting all of the "capabilities" in one file and passing that through "virsh cpu-baseline" but that returned something completely incompatible with the Broadwell ... I looked at "virsh domcapabilities" and found that they all support "Broadwell-noTSX-IBRS" ... and nova- compute will start up using that... but, live migrations between the Broadwell and Skylake CPUs to the SapphireRapids doesn't work properly.
tl;dr ... any tips on making this work with wildly disparate CPUs?