Enable and start a service
Turn on start at boot and start the service now with one command
systemctl enable --now myapp.service
More systemd commands
-
systemctl list-units --state=failedList all units in the failed state
-
systemctl daemon-reload && systemctl restart myapp.serviceReload unit files and restart the service
-
systemctl edit myapp.serviceOpen /etc/systemd/system/myapp.service.d/override.conf in an editor for partial overrides
-
systemctl cat myapp.servicePrint the full unit file, including drop-ins
-
systemd-analyze blame | head -20Show the 20 units that took the longest to start