MOXUY

May 31, 2022

在Windows11家庭版中开启Hyper-V

新建一个后缀为cmd的文件,写入如下代码

1
2
3
4
5
6
7
8
9
10
11
pushd "%~dp0"

dir /b %SystemRoot%\servicing\Packages\*Hyper-V*.mum >hv.txt

for /f %%i in ('findstr /i . hv.txt 2^>nul') do dism /online /norestart /add-package:"%SystemRoot%\servicing\Packages\%%i"

del hv.txt

Dism /online /enable-feature /featurename:Microsoft-Hyper-V -All /LimitAccess /ALL

Pause

保存后以管理员身份运行即可

tags: Windows
OLDER > < NEWER