Ubuntu关闭图形界面

原创转载请注明出处:http://agilestyle.iteye.com/blog/2280880

 

针对16.04之前的版本

1. 修改 GRUB 配置文件

sudo vim /etc/default/grub


 

2. 保存后,更新grub

sudo update-grub


 

3.重启reboot

sudo reboot


 

4. 重启后,就进入了文字界面(之前更改过hostname,所以hostname不再是ubuntu)


 

针对Ubuntu16.04 关闭图形界面

查看Ubuntu版本

lsb_release -a


 

关掉图形界面启动

systemctl disable lightdm.service


 

重启

sudo reboot


 

重新回到图形界面,使用如下命令

sudo systemctl start lightdm.service

 

 

 

 

 

猜你喜欢

转载自agilestyle.iteye.com/blog/2280880