Systemctl cheat sheet: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
(6 intermediate revisions by the same user not shown) | |||
Line 5: | Line 5: | ||
systemd-analyze blame | systemd-analyze blame | ||
systemd-analyze time | systemd-analyze time | ||
systemctl reload-daemon | |||
*Watch | |||
watch systemctl list-jobs | |||
*Start X from shell | |||
systemctl start graphical.target | |||
*List targets | |||
root@vm:~# '''ls -l /lib/systemd/system/runlevel*.target''' | |||
lrwxrwxrwx 1 root root 15 Jun 7 12:49 /lib/systemd/system/runlevel0.target -> poweroff.target | |||
lrwxrwxrwx 1 root root 13 Jun 7 12:49 /lib/systemd/system/runlevel1.target -> rescue.target | |||
lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel2.target -> multi-user.target | |||
lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel3.target -> multi-user.target | |||
lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel4.target -> multi-user.target | |||
lrwxrwxrwx 1 root root 16 Jun 7 12:49 /lib/systemd/system/runlevel5.target -> graphical.target | |||
lrwxrwxrwx 1 root root 13 Jun 7 12:49 /lib/systemd/system/runlevel6.target -> reboot.target | |||
*Targets | |||
systemctl get-default (graphical.target / multi-user.target) | systemctl get-default (graphical.target / multi-user.target) | ||
systemctl set-default multi-user.target | systemctl set-default multi-user.target |
Latest revision as of 17:24, 18 March 2023
Systemctl
systemctl cat service systemctl cat rc-local.service systemd-analyze blame systemd-analyze time systemctl reload-daemon
- Watch
watch systemctl list-jobs
- Start X from shell
systemctl start graphical.target
- List targets
root@vm:~# ls -l /lib/systemd/system/runlevel*.target lrwxrwxrwx 1 root root 15 Jun 7 12:49 /lib/systemd/system/runlevel0.target -> poweroff.target lrwxrwxrwx 1 root root 13 Jun 7 12:49 /lib/systemd/system/runlevel1.target -> rescue.target lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel2.target -> multi-user.target lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel3.target -> multi-user.target lrwxrwxrwx 1 root root 17 Jun 7 12:49 /lib/systemd/system/runlevel4.target -> multi-user.target lrwxrwxrwx 1 root root 16 Jun 7 12:49 /lib/systemd/system/runlevel5.target -> graphical.target lrwxrwxrwx 1 root root 13 Jun 7 12:49 /lib/systemd/system/runlevel6.target -> reboot.target
- Targets
systemctl get-default (graphical.target / multi-user.target) systemctl set-default multi-user.target