栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 系统运维 > 运维 > Linux

win10安装子系统unbuntu18.04及图形界面

Linux 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

win10安装子系统unbuntu18.04及图形界面

1.启用“Windows Subsystem for Linux”

右击“开始菜单”,点击“Windows PowerShell (管理员)”,以管理员身份运行 PowerShell,依次执行以下命令:

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

后,重启电脑。

2.打开“Microsoft Store”,搜索并安装Ubuntu 18.04

等待自动下载安装完成,在开始菜单可以看到它

3.设置用户密码 4.换源

使用编辑器

sudo vim /etc/apt/sources.list

按"i",编辑。加入"#"注释原本的内容。

ubuntu 18.04(bionic) 配置如下:

deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

# deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
# deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

按"Esc"退出编辑,输入":wq"保存并退出 。

最后更新源和软件:

sudo apt-get update
sudo apt-get upgrade
5. 安装VcXsrv(开始弄图形界面)

VcXsrv是一个免费开源的软件,下载地址为https://sourceforge.net/projects/vcxsrv/

下载后安装,打开XLaunch,选择:“one large window”,Display number设置成0,其它默认即可,一路下一步。

 6. Ubuntu内安装桌面环境

三个包

sudo apt-get install ubuntu-desktop unity compizconfig-settings-manager

 然后配置显示方式:

export  DISPLAY=localhost:0
#执行下面这条命令之前,确保你上一步的XLaunch是开着的并且配置好了
ccsm

在XLaunch中,即会弹出ccsm的配置界面,按照网上推荐的方法点如下选项:

 

 

  然后close即可
7.开启桌面
sudo compiz

每次重启电脑之后,想继续看到桌面的话,直接打开配置好的XLaunch还是不够的,每次还需要输入如下两条命令: 

export DISPLAY=localhost:0
sudo compiz

 

参考引用:

Windows Subsystem for Linux(WSL)的安装、美化和增强 - 知乎

Win10安装Ubuntu子系统及图形化界面详细教程_leisp的博客-CSDN博客_ubuntu子系统 图形界面

ubuntu镜像-ubuntu下载地址-ubuntu安装教程-阿里巴巴开源镜像站

感谢。

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/973773.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号