装完VMware虚拟机后,可能会遇到:VMware Workstation 与 Device/Credential Guard 不兼容.在禁用 Device/Credenti…
1. 添加gpedit.msc
复制下边代码到.txt文件里,然后修改.txt后缀为.bat,然后右击选管理员身份运行,等待操作完成即可。
@echo off
pushd "%~dp0"
dir /b C:\Windows\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientExtensions-Package~3*.mum >List.txt
dir /b C:\Windows\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientTools-Package~3*.mum >>List.txt
for /f %%i in ('findstr /i . List.txt 2^>nul') do dism /online /norestart /add-package:"C:\Windows\servicing\Packages\%%i"
pause
2. 添加Hyper-v
跟上边一样的操作,代码替换为下边的:
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
参考博客:https://blog.csdn.net/qq_40846862/article/details/121695136