systemd

systemd is a system and service manager. systemctl is a main command of systemd

Basics

$ journalctl
list all running services, sockets, etc. (units).

Change Runlevel, Shutdown

# systemctl isolate graphical.target   analog to runlevel5 of SysV
# systemctl isolate multi-user.target   ... level3
# systemctl isolate rescue.target   ... level1

$ systemctl poweroff
$ systemctl reboot

Change Display Manager

# systemctl disable gdm
# systemctl enable xdm

List of Processes

$ systemd-cgls
$ ps xawf -eo pid,user,cgroup,args
tree view of processes belonging to services and logged-in user.

List of Units

$ tree /etc/systemd/   currently used units
$ tree /lib/systemd/   all available units

3 Levels of OFF

# systemctl stop
terminates the running unit.

# systemctl disable
prevents activation of unit on boot, by socket or bus (or by other triggers) activation. Howerver, the unit can be started manually.

# systemct mask
or
# ln -s /dev/null /etc/systemd/system/example.service
# systemctl daemon-reload
disable unit completely (can not be started anymore).

Analyze Boot-Up Performance

systemd-analyze
or
journalctl --since=today | grep userspace
show the boot-up time (the time spent in the kernel before userspace has been reached).

systemd-analyze blame
print a list of all running units, ordered by the time they took to initialize.

References

•   freedesktop.org Wiki
•   Fedora Docs
•   Arch Wiki