468b03e0ee
The older libvirt API compareCPU() does not take into account the capabilities of the "host hypervisor" (KVM, QEMU and the details libvirt knows about the host) when comparing CPUs. This is causing unwanted failures during CPU compatibility checks. To fix this and other related problems, libvirt has introduced (in v4.4.0) a newer API, compareHypervisorCPU(), which _does_ take into account the host hypervisor's capabilities before comparing CPUs. This will help fix a range of problems, such as[1][2]. So let's switch to the newer API, which is largely a drop-in replacement. In this patch: - Introduce a wrapper method, compare_hypervisor_cpu() for libvirt's compareHypervisorCPU() API. - Update the _compare_cpu() method to use the wrapper method, compare_hypervisor_cpu(). - Update the unit tests to use the newer API, compareHypervisorCPU(). [1] https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1978064 [2] https://bugzilla.redhat.com/show_bug.cgi?id=2138381 Change-Id: Ib523753f52993cfe72e35e0309e429ca879c125c Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com>
13 lines
527 B
YAML
13 lines
527 B
YAML
---
|
|
fixes:
|
|
- |
|
|
Nova's use of libvirt's compareCPU() API has become error-prone as
|
|
it doesn't take into account host hypervisor's capabilities. With
|
|
QEMU >=2.9 and libvirt >= 4.4.0, libvirt will do the right thing in
|
|
terms of CPU comparison checks via a new replacement API,
|
|
compareHypervisorCPU(). Nova satisfies the said minimum version
|
|
requirements of QEMU and libvirt by a good margin.
|
|
|
|
This change replaces the usage of older API, compareCPU(), with the
|
|
new one, compareHypervisorCPU().
|