Difference between revisions of "Systemd debian"

From Teknologisk videncenter
Jump to: navigation, search
m
m
Line 3: Line 3:
 
...:~$ sudo systemd-analyze verify YOUR_SERVICEFIL
 
...:~$ sudo systemd-analyze verify YOUR_SERVICEFIL
 
...:~$ sudo systemctl daemon-reload
 
...:~$ sudo systemctl daemon-reload
...:~$ sudosystemctl enable YOUR_SERVICEFILE
+
...:~$ sudo systemctl enable YOUR_SERVICEFILE
 
...:~$ sudo systemctl YOUR_SERICEFILE
 
...:~$ sudo systemctl YOUR_SERICEFILE
 
</source>
 
</source>

Revision as of 09:57, 13 February 2022

  • Scriptfiles in /lib/systemd/system - See exampels of servicefiles there - add your own new system service:
...:~$ sudo systemd-analyze verify YOUR_SERVICEFIL
...:~$ sudo systemctl daemon-reload
...:~$ sudo systemctl enable YOUR_SERVICEFILE
...:~$ sudo systemctl YOUR_SERICEFILE

Often used

# systemctl start [name.service]
# systemctl stop [name.service]
# systemctl restart [name.service]
# systemctl reload [name.service]
$ systemctl status [name.service]
# systemctl is-active [name.service]
$ systemctl list-units --type service --all

Links