Kategorija:Systemd: Skirtumas tarp puslapio versijų

Iš Žinynas.
Jump to navigation Jump to search
(Naujas puslapis: systemctl daemon-reload systemctl enable <name>.service systemctl start <name>.service {{Template:Distributions}})
 
 
(nerodoma 2 tarpinės versijos, sukurtos to paties naudotojo)
2 eilutė: 2 eilutė:
 
  systemctl enable <name>.service
 
  systemctl enable <name>.service
 
  systemctl start <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.
  
 
{{Template:Distributions}}
 
{{Template:Distributions}}

Dabartinė 14:55, 9 liepos 2021 versija

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[keisti]

[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).