
Basic commands for WSL | Microsoft Learn
To set a default version of WSL 1 or WSL 2, replace <Version> with either the number 1 or 2. For example, wsl --set-default-version 2. The number represents the version of WSL to default to for new Linux distribution installations. Comparing WSL 1 and WSL 2. WSL 2 is only available in Windows 11 or Windows 10, Version 1903, Build 18362 or later.
WSL 的基本命令 | Microsoft Learn
2024年7月19日 · 查看安装在 Windows 计算机上的 Linux 发行版列表,其中包括状态(发行版是正在运行还是已停止)和运行发行版的 WSL 版本(WSL 1 或 WSL 2)。 比较 WSL 1 和 WSL 2。 此命令也可输入为: wsl -l -v。 可与 list 命令一起使用的其他选项包括: --all (列出所有发行版)、 --running (仅列出当前正在运行的发行版)或 --quiet (仅显示发行版名称)。 若要指定运行 Linux 发行版的 WSL 版本(1 或 2),请将 <distribution name> 替换为发行版的名称,并将 …
Install WSL | Microsoft Learn
2024年11月19日 · New Linux installations, installed using the wsl --install command, will be set to WSL 2 by default. The wsl --set-version command can be used to downgrade from WSL 2 to WSL 1 or to update previously installed Linux distributions from WSL 1 to WSL 2. To see whether your Linux distribution is set to WSL 1 or WSL 2, use the command: wsl -l -v.
Install Ubuntu on WSL2 - Ubuntu on WSL documentation
3 天之前 · Install Ubuntu on WSL2¶ What you will learn¶ How to enable and install WSL on Windows 10 and Windows 11. How to install Ubuntu 24.04 LTS using the Microsoft Store or WSL commands in the terminal. What you will need¶ Windows 10 or 11 running on either a physical device or virtual machine. All of the latest Windows updates installed. Install WSL¶
How do I open the WSL CLI on Windows 10? - Super User
2022年12月2日 · Run wsl.exe -l -v from a command prompt to determine exactly which ones you have installed. If you are using the latest version of WSL, it will also appear separately in the Start menu as Windows Subsystem for Linux. Clicking on …
Install Windows Subsystem for Linux (WSL 2) on Windows 10/11
2022年9月20日 · This command will automatically enable all the necessary Windows features required for WSL, install the Linux kernel update for WSL2, download the Ubuntu distribution (by default), and install it in WSL.
Getting started with WSL2 - Medium
2021年8月21日 · To confirm the installation open up PowerShell and run the following command: wsl.exe --list --all --verbose. We should expect to see one row for Ubuntu with the WSL2 Version set to 2. We can...
Develop with Ubuntu on WSL - Ubuntu on WSL documentation
3 天之前 · Install Ubuntu on WSL2 In a PowerShell terminal, run wsl --list --online to see all available distros and versions: The following is a list of valid distributions that can be installed.
使用 Arduino CLI + vscode + WSL2 配置 Arduino 开发环境 - 浩瀚 …
4 天之前 · 正好 Arduino 官方也提供了一个命令行工具,它就是我们的主角:Arduino CLI。 以下是我在 wsl2 里配置相关环境的大概步骤。 安装 Arduino CLI. 官网的教程里提供了很多种安装方法,比如直接用包管理器安装: brew update brew install arduino-cli
Enable WSL 2 on Windows 11 via CMD & PowerShell [Latest]
2024年12月10日 · This latest article will guide you through the steps on How to Enable WSL 2 (Windows Subsystem for Linux) on Windows 11 using the Command Prompt and Windows PowerShell (CLI Method). We also have covered an article that explains How to enable WSL 2 using Windows Features (GUI Method) .