标签:redhat 7如何修改默认运行级别 rhel7修改默认级别的方法
今天装了下正式版的RHEL7,发现熟悉的inittab中没有了修改默认运行级别,打开inittab如下
[root@localhost init.d]# vi /etc/inittab # inittab is no longer used when using systemd. # # ADDING CONFIGURATION HERE WILL HAVE NO EFFECT ON YOUR SYSTEM. # # Ctrl-Alt-Delete is handled by /etc/systemd/system/ctrl-alt-del.target # # systemd uses 'targets' instead of runlevels. By default, there are two main targets: # # multi-user.target: analogous to runlevel 3 # graphical.target: analogous to runlevel 5 # # To set a default target, run: # # ln -sf /lib/systemd/system/<target name>.target /etc/systemd/system/default.target
RHEL7 使用systemd创建符号链接指向默认运行级别。
修改方法为:
1.首先删除已经存在的符号链接
----------------------------------------------------------------------------------
rm /etc/systemd/system/default.target
----------------------------------------------------------------------------------
2.默认级别转换为3(文本模式)
----------------------------------------------------------------------------------
ln -sf /lib/systemd/system/multi-user.target /etc/systemd/system/default.target
----------------------------------------------------------------------------------
或者默认级别转换为5(图形模式)
----------------------------------------------------------------------------------
ln -sf /lib/systemd/system/graphical.target /etc/systemd/system/default.target
----------------------------------------------------------------------------------
3.重启
----------------------------------------------------------------------------------
reboot
----------------------------------------------------------------------------------
Redhat 7修改默认运行级别方法 --RHEL7使用systemd创建符号链接指向默认运行级别,布布扣,bubuko.com
Redhat 7修改默认运行级别方法 --RHEL7使用systemd创建符号链接指向默认运行级别
标签:redhat 7如何修改默认运行级别 rhel7修改默认级别的方法
原文地址:http://blog.csdn.net/wjx515628/article/details/36931235