确定电脑开启虚拟化

如果电脑没有开启 需要重启进入BIOS 选择 CPU设置 开启 虚拟化
这里参考 https://www.cnblogs.com/xianyulouie/p/11041837.html
打开"控制面板" > "程序">"程序和功能">"启用或关闭 windows功能"

如果没此选项 需要 安装功能
新建脚本 安装Hyper-V.bat 并以管理员运行
pushd "%~dp0"
dir /b %SystemRoot%\servicing\Packages\*Hyper-V*.mum >hyper-v.txt
for /f %%i in ('findstr /i . hyper-v.txt 2^>nul') do dism /online /norestart /add-package:"%SystemRoot%\servicing\Packages\%%i"
del hyper-v.txt
Dism /online /enable-feature /featurename:Microsoft-Hyper-V-All /LimitAccess /ALL
执行完重启电脑
点波关注 系统搭建(docker)
网友评论