Nag*_*gev 12 windows-subsystem-for-linux windows-11
我有 Windows 11,WSL 工作正常,直到我必须进行PC 重置,现在尝试从头开始重新安装。这是我现在得到的(在多次 WSL 安装尝试之后):
PS > wsl --install
Windows Subsystem for Linux is already installed.
The following is a list of valid distributions that can be installed.
Install using 'wsl.exe --install <Distro>'.
NAME FRIENDLY NAME
Ubuntu Ubuntu
Debian Debian GNU/Linux
kali-linux Kali Linux Rolling
SLES-12 SUSE Linux Enterprise Server v12
SLES-15 SUSE Linux Enterprise Server v15
Ubuntu-18.04 Ubuntu 18.04 LTS
Ubuntu-20.04 Ubuntu 20.04 LTS
OracleLinux_8_5 Oracle Linux 8.5
OracleLinux_7_9 Oracle Linux 7.9
PS > wsl --install Ubuntu-20.04
Installing: Ubuntu 20.04 LTS
Ubuntu 20.04 LTS has been installed.
Launching Ubuntu 20.04 LTS...
PS > wsl list
Windows Subsystem for Linux has no installed distributions.
Use 'wsl.exe --list --online' to list available distributions
and 'wsl.exe --install <Distro>' to install.
Distributions can also be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
Error code: Wsl/Service/CreateInstance/GetDefaultDistro/WSL_E_DEFAULT_DISTRO_NOT_FOUND
Run Code Online (Sandbox Code Playgroud)
如果我运行 Ubuntu 应用程序,我会得到:
Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80370114
Error: 0x80370114 The operation could not be started because a required feature is not installed.
Press any key to continue...
Run Code Online (Sandbox Code Playgroud)
在“打开或关闭 Windows 功能”下,我已启用:
[x] Virtual Machine Platform
[x] Windows Hypervisor Platform
[x] Windows Subsystem for Linux
Run Code Online (Sandbox Code Playgroud)
顺便说一句,我后来才打开“Windows Hypervisor Platform”,作为实验。我在GitHub和其他相关的地方看到了答案vmcompute.exe,但我的系统上没有这个,我是否需要安装它,如果需要,如何安装?
PS > ls C:\Windows\System32\vm*
Directory: C:\Windows\System32
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a---- 07/05/2022 06:20 50528 VmApplicationHealthMonitorProxy.dll
-a---- 21/11/2022 19:41 79896 vmbuspipe.dll
-a---- 07/05/2022 06:20 270336 vmdevicehost.dll
-a---- 07/05/2022 06:20 87400 vmictimeprovider.dll
-a---- 07/05/2022 06:20 487424 vmrdvcore.dll
Run Code Online (Sandbox Code Playgroud)
即使已经启用,也尝试了类似问题上接受的答案,但没有区别:
PS > dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
Deployment Image Servicing and Management tool
Version: 10.0.22621.1
Image Version: 10.0.22621.819
Enabling feature(s)
[==========================100.0%==========================]
The operation completed successfully.
PS > dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
Deployment Image Servicing and Management tool
Version: 10.0.22621.1
Image Version: 10.0.22621.819
Enabling feature(s)
[==========================100.0%==========================]
The operation completed successfully.
Run Code Online (Sandbox Code Playgroud)
那么这里的解决方案是什么呢?论坛的答案对我没有帮助,而且MS 文档听起来需要的只是一个 magic wsl --install。
系统信息:
Edition Windows 11 Home
Version 22H2
OS build 22621.819
Experience Windows Feature Experience Pack 1000.22636.1000.0
Run Code Online (Sandbox Code Playgroud)
如有任何建议,我们将不胜感激,否则我将在稍后分享我找到的解决方案。现在要安装一些更新,看看是否有帮助。
安装了 Windows 更新,重新启动后 Ubuntu 安装恢复。现在 WSL 可以运行了!
现在我有:
PS > ls C:\Windows\System32\vmcompute*
Directory: C:\Windows\System32
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a---- 21/11/2022 19:41 796000 vmcompute.dll
-a---- 21/11/2022 19:41 4158848 vmcompute.exe
-a---- 07/05/2022 08:16 42344 vmcomputeeventlog.dll
Run Code Online (Sandbox Code Playgroud)
真的很简单,但我很高兴,并希望它对某人有帮助。
| 归档时间: |
|
| 查看次数: |
109972 次 |
| 最近记录: |