From 38c7bcf65517d75f79a5247debdabd8f54a215ac Mon Sep 17 00:00:00 2001 From: Kroese Date: Sat, 20 May 2023 03:01:15 +0200 Subject: [PATCH] KVM --- run/run.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/run/run.sh b/run/run.sh index dcd991d..eed122c 100755 --- a/run/run.sh +++ b/run/run.sh @@ -21,6 +21,7 @@ trap 'error "Status $? while: ${BASH_COMMAND} (line $LINENO/$BASH_LINENO)"' ERR STORAGE="/storage" KERNEL=$(uname -r | cut -b 1) +ARCH=$(dpkg --print-architecture) [ ! -d "$STORAGE" ] && error "Storage folder (${STORAGE}) not found!" && exit 13 @@ -42,7 +43,7 @@ KVM_OPTS="" if [ -e /dev/kvm ] && sh -c 'echo -n > /dev/kvm' &> /dev/null; then if ! grep -q -e vmx -e svm /proc/cpuinfo; then - KVM_ERR="(cpuinfo $(grep -c -e vmx -e svm /proc/cpuinfo))" + KVM_ERR="(vmx/svm disabled)" fi else [ -e /dev/kvm ] && KVM_ERR="(no write access)" || KVM_ERR="(device file missing)" @@ -50,7 +51,7 @@ fi if [ -n "${KVM_ERR}" ]; then error "KVM acceleration not detected ${KVM_ERR}, see the FAQ about this." - [[ "${DEBUG}" == [Yy1]* ]] && exit 88 + [[ "${DEBUG}" != [Yy1]* ]] && exit 88 else KVM_OPTS=",accel=kvm -enable-kvm -cpu host" fi