Update check_kernal.sh

This commit is contained in:
spiritLHLS 2023-04-25 14:31:00 +08:00 committed by GitHub
parent 28dc9f5307
commit 4588840fba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -34,7 +34,7 @@ else
fi
# 查询系统是否支持
if [ "$(cat /sys/module/kvm_intel/parameters/nested)" = "Y" ]; then
if [ -e "/sys/module/kvm_intel/parameters/nested" ] && [ "$(cat /sys/module/kvm_intel/parameters/nested | tr '[:upper:]' '[:lower:]')" = "y" ]; then
if lsmod | grep -q kvm; then
_green "本机系统支持KVM硬件嵌套虚拟化"
_green "本机符合要求可以使用PVE虚拟化KVM服务器并可以在开出来的KVM服务器选项中开启KVM硬件虚拟化"