ubuntu14修改启动模式关闭启动图形界面


Ubuntu的默认开机的runlevel是2,可以用runlevel来查看当前的默认运行级别。

runlevel级别定义如下: 0 – Halt,关机模式 1 – Single,单用户模式 2 - Full multi-user with display manager (GUI) 3 - Full multi-user with display manager (GUI) 4 - Full multi-user with display manager (GUI) 5 - Full multi-user with display manager (GUI) 6 – Reboot,重启 可以发现2~5级是没有任何区别的。区别于redhat内核的linux

ubuntu 的默认运行级别文件是/etc/init/rc-sysinit.conf。

阻止默认图形桌面启动 ubuntu 12.04默认的开机会进入一个图形界面,他是由lightdm进程来实现的。 首先要做的,就是阻止这个lightdm的进程开机启动。 做法: (1)、查看文件/etc/init/rc-sysinit.conf,在第14行附近:确认“env DEFAULT_RUNLEVEL=2”。2是新装系统默认的,确保不被修改。 (2)、编辑文件 /etc/init/lightdm.conf,在第12行附近,原句“ and runlevel [!06]” 改为“ and runlevel [!026]”。


相关内容