Hyper-V使用

1.Enable hyper-v on windows

安装好的正版windows10没有hyper-v的虚拟环境怎么办?

Copy 如下代码到 Hyper-V.cmd

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

然后右击管理员身份执行Hyper-V.cmd

等待安装完成后重新打开"启用或关闭windows供能",勾选Hyper-V,确定,之后在重启一下

 

 

 重启后搜索,就可以找到windows10自带的虚拟机了

 2.设置hyper-v里ubantu的网络连接

4 这里的driver可以在device manager里找到,这是电脑网卡驱动

 

posted @ 2022-02-09 22:50  腹肌猿  阅读(248)  评论(0编辑  收藏  举报