5

systemd still maintains the general idea of runlevels with its "Targets", but how do I change the system runlevel through systemd?

I want to do something equivalent to the old init-script method of:

init 3 # Multi-user init 5 # Graphical 
3
  • That's because you are looking for something that in the systemd world is obsolete. Forget about runlevels, as I said in an answer to that very question. Commented Feb 2, 2019 at 0:50
  • Questions in other Answers are exactly what "Duplicates" are for. Commented Feb 5, 2019 at 16:10
  • Yes, the answer for that Question would have answered this Question, but the Question itself was different. Commented Feb 5, 2019 at 18:13

1 Answer 1

9

From freedesktop.org's own systemd FAQ, to change the (running) Target (system runlevel), use systemctl isolate TARGET.target:

systemctl isolate multi-user.target # or runlevel3.target systemctl isolate graphical.target # or runlevel5.target 

To change the default Target (default system runlevel, for the next reboot), use systemctl set-default TARGET:

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.