wsl===windows下安装Linux系统

新近版本的windows都支持了Linux,操作如下:

控制面板中启用对应的功能

2. 打开powershell,以安装Ubuntu为例,然后执行

PS C:\Users\steven.wang> wsl.exe --update
正在安装: 适用于 Linux 的 Windows 子系统
已安装 适用于 Linux 的 Windows 子系统。
PS C:\Users\steven.wang> wsl --set-default-version 2
有关与 WSL 2 关键区别的信息,请访问 https://aka.ms/wsl2

操作成功完成。
PS C:\Users\steven.wang> wsl --install -d Ubuntu-18.04
Ubuntu 18.04 LTS 已安装。
正在启动 Ubuntu 18.04 LTS...
Installing, this may take a few minutes...
Please create a default UNIX user account. The username does not need to match your Windows username.
For more information visit: https://aka.ms/wslusers
Enter new UNIX username: root
adduser: The user `root' already exists.
Enter new UNIX username: apps
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
操作成功完成。
Installation successful!
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.

apps@steven:~$ ls
apps@steven:~$ pwd
/home/apps

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值