summaryrefslogtreecommitdiffstats
path: root/patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch
diff options
context:
space:
mode:
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>2017-07-21 20:02:14 +0200
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>2017-07-21 20:03:23 +0200
commit5f29466a9eece85c13b53100ca4ef980f9e7660c (patch)
tree3fd21389dc3c601207ea05dee71b829094071a7a /patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch
parent28b86f89f750d93a4e7c995f4b931ad004f11f8e (diff)
p/fuel: lib.sh: Use host-passthrough CPU model
Fix libvirt 3.x compatibility issues by explicitly setting the CPU model to host-passthrough via virt-install. Change-Id: I0e52cbabb0bf42b36dd2b9b5045dc18878e21884 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
Diffstat (limited to 'patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch')
-rw-r--r--patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch b/patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch
new file mode 100644
index 00000000..88793337
--- /dev/null
+++ b/patches/opnfv-fuel/0008-lib.sh-Use-host-passthrough-when-spawning-VMs.patch
@@ -0,0 +1,29 @@
+From: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
+Date: Fri, 21 Jul 2017 19:59:33 +0200
+Subject: [PATCH] lib.sh: Use host-passthrough when spawning VMs
+
+virsh defaults to using "host-model" instead of "host-passthrough",
+which not only might lead to a small performance hit on x86, it is
+also causing compatibility issues with libvirt 3.x.
+
+Address this by explicitly requesting "host-passthrough" as the
+CPU model for virt-install.
+
+Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
+---
+ mcp/scripts/lib.sh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/mcp/scripts/lib.sh b/mcp/scripts/lib.sh
+index 7c4c46f..2be3e65 100644
+--- a/mcp/scripts/lib.sh
++++ b/mcp/scripts/lib.sh
+@@ -69,7 +69,7 @@ create_vms() {
+
+ # create vms with specified options
+ for node in "${vnodes[@]}"; do
+- virt-install --name ${node} --ram ${vnodes_ram[$node]} --vcpus ${vnodes_vcpus[$node]} --cpu host --accelerate \
++ virt-install --name ${node} --ram ${vnodes_ram[$node]} --vcpus ${vnodes_vcpus[$node]} --cpu host-passthrough --accelerate \
+ --network network:pxe,model=${virt_pxe_net_model} \
+ --network network:mgmt,model=${virt_net_model} \
+ --network network:internal,model=${virt_net_model} \