Windows Subsystem for Linux

Posted chucklu

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Windows Subsystem for Linux相关的知识,希望对你有一定的参考价值。

https://docs.microsoft.com/en-us/windows/wsl/about

https://docs.microsoft.com/en-us/windows/wsl/install-win10

Windows Subsystem for Linux Installation Guide for Windows 10

Install the Windows Subsystem for Linux

Before installing any Linux distros for WSL, you must ensure that the "Windows Subsystem for Linux" optional feature is enabled:

  1. Open PowerShell as Administrator and run:

    Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
    
  2. Restart your computer when prompted.

Install your Linux Distribution of Choice

To download and install your preferred distro(s), you have three choices:

  1. Download and install from the Windows Store (see below)
  2. Download and install from the Command-Line/Script (read the manual installation instructions)
  3. Download and manually unpack and install (for Windows Server - instructions here)

 在windows store里面搜索wsl,然后找到Ubuntu版本

安装完启动,需要创建Ubuntu的账号https://docs.microsoft.com/en-us/windows/wsl/user-support技术图片

创建用户成功后,提示

Installation successful!
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.

 

以上是关于Windows Subsystem for Linux的主要内容,如果未能解决你的问题,请参考以下文章

Windows Subsystem For Linux

Windows Subsystem for Linux(wsl)使用

Windows Subsystem for Linux 环境变量

Where windows subsystem for linux (WSL) File/Directory Location?

使用WSL(Windows Subsystem for Linux)挂载usb设备

wsl(Windows Subsystem for Linux)安装简易指南