Systemd
From BCCD 3.0
(Difference between revisions)
(→Links) |
m (fix arguments in example) |
||
Line 23: | Line 23: | ||
[Service] | [Service] | ||
- | ExecStart=/bin/bccd-passwd-wrapper | + | ExecStart=/bin/bccd-passwd-wrapper bccd |
Type=oneshot | Type=oneshot | ||
Revision as of 03:54, 15 December 2016
Contents |
Path cheat sheet
- Place custom units in
/etc/systemd/user
Command cheat sheet
- Print blocking portions of the boot tree:
systemd-analyze critical-chain
- Print all managed objects:
systemctl -a
- Print failed objects:
systemctl --failed
- Print jobs:
systemctl list-jobs
- Print all services:
systemctl list-units -t service --all
- Print service config:
systemctl show [ service-name ]
- Print service status:
systemctl status [ service-name ]
- Enable service, making symlinks:
systemctl enable /etc/systemd/user/bccd-passwd-wrapper.service
- Edit service, using EDITOR:
systemctl edit --full service-name>
- Get unit output:
journalctl -u unit-name
Example unit
[Unit] Description="Set BCCD user password" [Service] ExecStart=/bin/bccd-passwd-wrapper bccd Type=oneshot # This service is expected to exit completely even if it is successful RemainAfterExit=yes # Do not restart after everything exits Restart=no # This service requires user interaction via the TTY StandardInput=tty StandardOutput=tty [Install] WantedBy=multi-user.target