Change init level

General support questions
Post Reply
nobody
Posts: 66
Joined: 2012/04/13 00:53:49

Change init level

Post by nobody » 2014/07/18 12:27:13

Hi,

Seems CentOS 7 has no longer support run level setting in inittab, where can I change the boot level without X?

Thanks.

- j

User avatar
WhatsHisName
Posts: 1549
Joined: 2005/12/19 20:21:43
Location: /earth/usa/nj

Re: Change init level

Post by WhatsHisName » 2014/07/18 14:03:42

Code: Select all

# cat /etc/redhat-release

 Red Hat Enterprise Linux Server release 7.0 (Maipo)

# cat /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
 #

nbritton
Posts: 38
Joined: 2014/07/09 23:38:46

Re: Change init level

Post by nbritton » 2014/07/18 15:14:26

nobody wrote:Seems CentOS 7 has no longer support run level setting in inittab, where can I change the boot level without X?
Runlevel 3 is now multi-user.target and runlevel 5 is now graphical.target.

systemctl set-default multi-user.target;
systemctl set-default graphical.target;

To switch from graphical to multi-user:
systemctl isolate multi-user.target;

To switch from multi-user to graphical:
systemctl isolate graphical.target;

http://www.freedesktop.org/software/sys ... ecial.html

https://www.youtube.com/watch?v=jbYucYX1WwM

Zedrick
Posts: 1
Joined: 2015/03/05 09:44:33

Re: Change init level

Post by Zedrick » 2015/03/05 10:03:23

Reviving an old thread with a follow-up question.

How can I boot into "multi-user.target" from grub? I can't use systemctl if I can't start CentOS.

User avatar
TrevorH
Site Admin
Posts: 33191
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Change init level

Post by TrevorH » 2015/03/05 10:30:12

Appending the digit 3 to the end of the kernel command line still works to bring it up in the systemd equivalent of runlevel 3. You can also use the methods discussed in the upstream documentation https://access.redhat.com/documentation ... oader.html
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Post Reply