From 42eb0b4c5f6cd54c98cc53023602ebe43a239609 Mon Sep 17 00:00:00 2001 From: Gabriel Date: Mon, 12 Dec 2022 18:53:25 -0300 Subject: [PATCH] Fix QEMU Version for compatibility with PVE 7.3 --- setup | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/setup b/setup index 73a560e..7099524 100755 --- a/setup +++ b/setup @@ -334,7 +334,7 @@ do --ide2 local:iso/recovery-highsierra.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+bmi2,+xsave,+xsaveopt,check/+bmi2,+xsave,+xsaveopt,check -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -374,7 +374,7 @@ do --ide2 local:iso/recovery-highsierra.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -525,7 +525,7 @@ do --ide2 local:iso/recovery-mojave.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+bmi2,+xsave,+xsaveopt,check/+bmi2,+xsave,+xsaveopt,check -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -565,7 +565,7 @@ do --ide2 local:iso/recovery-mojave.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -716,7 +716,7 @@ do --ide2 local:iso/recovery-catalina.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+bmi2,+xsave,+xsaveopt,check/+bmi2,+xsave,+xsaveopt,check -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -756,7 +756,7 @@ do --ide2 local:iso/recovery-catalina.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -907,7 +907,7 @@ do --ide2 local:iso/recovery-bigsur.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+bmi2,+xsave,+xsaveopt,check/+bmi2,+xsave,+xsaveopt,check -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -947,7 +947,7 @@ do --ide2 local:iso/recovery-bigsur.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -1098,7 +1098,7 @@ do --ide2 local:iso/recovery-monterey.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+bmi2,+xsave,+xsaveopt,check/+bmi2,+xsave,+xsaveopt,check -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -1138,7 +1138,7 @@ do --ide2 local:iso/recovery-monterey.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -1289,7 +1289,7 @@ do --ide2 local:iso/recovery-ventura.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+invtsc,-pcid,-hle,-rtm,-avx512f,-avx512dq,-avx512cd,-avx512bw,-avx512vl,-avx512vnni,kvm=on,vmware-cpuid-freq=on/+invtsc,-pcid,-hle,-rtm,-avx512f,-avx512dq,-avx512cd,-avx512bw,-avx512vl,-avx512vnni,kvm=on,vmware-cpuid-freq=on -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi @@ -1329,7 +1329,7 @@ do --ide2 local:iso/recovery-ventura.iso,cache=unsafe,size=800M > ${LOGFILE} 2>> ${LOGFILE} ## Fix for QEMU 6.1 for PCI Passthrough - if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" | wc -l` -eq 1 ] + if [ `qemu-system-x86_64 --version | grep -e "6.1" -e "6.2" -e "7.1" | wc -l` -eq 1 ] then sed -i 's/+kvm_pv_eoi,+hypervisor,+invtsc/+kvm_pv_eoi,+hypervisor,+invtsc -global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off/g' /etc/pve/qemu-server/${VM_ID}.conf fi