我正在关注此处的教程:https://www.youtube.com/watch?v =ZMfHaUkhfc0 我大约在 15:00 左右。我已在管理员帐户的 PowerShell 中安装了 WSL2。我以普通用户身份登录。我安装了 Docker Desktop 和 Ubuntu。我重新启动。然后我再次以管理员帐户打开 Powershell,但它没有看到我安装的 Ubuntu 发行版或我安装的 Docker Desktop。
PS C:\windows\system32> wsl -l -v
Windows Subsystem for Linux has no installed distributions.
Distributions can be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
PS C:\windows\system32> wsl.exe -d Ubuntu
There is no distribution with the supplied name.
PS C:\windows\system32> wsl.exe --install Ubuntu
Copyright (c) Microsoft Corporation. All rights reserved.
Usage: wsl.exe [Argument] [Options...] [CommandLine]
Arguments for running Linux binaries:
If no command line is provided, wsl.exe launches the default shell.
--exec, -e <CommandLine>
Execute the specified command without using the default Linux shell.
--
Pass the remaining command line as is.
同样,我使用常规(非管理员)帐户,并且能够在 Windows 中打开 Ubuntu 应用程序和 Docker 桌面应用程序,但我以管理员身份运行的 Powershell 会话也看不到。我该如何解决?为什么wsl.exe --install Ubuntu
调用失败并显示简单的使用消息?