Kategorija:Systemd

Iš Žinynas.
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
systemctl daemon-reload   
systemctl enable <name>.service
systemctl start <name>.service
journalctl -u <name> -f

All stopped services on the system

systemctl list-units -all --state=inactive

All failed services on the system

systemctl list-units -all --state=failed

Services status one-liner

for i in $(cd /etc/systemd/system/multi-user.target.wants && ls *.service); do script -q -c "systemctl status -n 0 --no-pager $i" |head -n 1; script -q -c "systemctl status -n 0 --no-pager $i" |grep --color=never "Active: "; done;

Tipai

[Service]
Type=

Systemd is able to handle various different service types specifically one of the following

  • simple - A long-running process that does not background its self and stays attached to the shell.
  • forking - A typical daemon that forks itself detaching it from the process that ran it, effectively backgrounding itself.
  • oneshot - A short-lived process that is expected to exit.
  • dbus - Like simple, but notification of processes startup finishing is sent over dbus.
  • notify - Like simple, but notification of processes startup finishing is sent over inotify.
  • idle - Like simple, but the binary is started after the job has been dispatched.

Puslapiai kategorijoje „Systemd“

Rodomi 6 šios kategorijos puslapiai (iš viso kategorijoje yra 6 puslapiai).