Set cpu_mode = none for Qemu

Nova will set a default value for "cpu_mode" for Qemu/KVM which will be
"host-model" however this causes issues with QEMU 2.6.0:

https://bugzilla.redhat.com/show_bug.cgi?id=1404627

This patch allows the nova_cpu_model to be set, and is set for the qemu
libvirt_type to be "none" by default.

Change-Id: I1e1b0149efe3bfa069172fa99cde65566a8fe19e
This commit is contained in:
Andy McCrae 2017-07-03 14:55:08 +01:00
parent fe528783f9
commit a2f95e90ca
3 changed files with 10 additions and 3 deletions

View File

@ -163,6 +163,7 @@ nova_virt_types:
nova_firewall_driver: nova.virt.firewall.NoopFirewallDriver
nova_scheduler_use_baremetal_filters: False
nova_scheduler_tracks_instance_changes: True
nova_cpu_mode: "none"
powervm:
nova_compute_driver: powervm.driver.PowerVMDriver
nova_scheduler_host_manager: host_manager

View File

@ -1,6 +1,9 @@
---
deprecations:
- |
The ``nova_cpu_mode`` Ansible variable has been removed to allow
Nova to detect the default value automatically. Hard-coded values
can cause problems.
The ``nova_cpu_mode`` Ansible variable has been removed by default,
to allow Nova to detect the default value automatically. Hard-coded
values can cause problems. You can still set ``nova_cpu_mode`` to
enforce a ``cpu_mode`` for Nova.
Additionally, the default value for the ``qemu`` ``libvirt_type``
is set to ``none`` to avoid issues caused with ``qemu`` 2.6.0.

View File

@ -259,6 +259,9 @@ inject_key = {{ nova_libvirt_inject_key }}
use_virtio_for_bridges = True
virt_type = {{ nova_virt_type }}
remove_unused_resized_minimum_age_seconds = {{ nova_remove_unused_resized_minimum_age_seconds }}
{% if nova_cpu_mode is defined %}
cpu_mode = {{ nova_cpu_mode }}
{% endif %}
{% if nova_libvirt_images_rbd_pool is defined %}
# ceph rbd support