summaryrefslogtreecommitdiffstats
path: root/units/reboot.target
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-10-28 01:49:39 +0100
committerLennart Poettering <lennart@poettering.net>2014-10-28 02:19:55 +0100
commit3898b80d409ae16b049d46f883bf763417bb4c8a (patch)
treed4b5f7aa2c7aeed720aebd5fa094c86622079e4d /units/reboot.target
parentjob: optionally, when a job timeout is hit, also execute a failure action (diff)
downloadsystemd-3898b80d409ae16b049d46f883bf763417bb4c8a.tar.xz
systemd-3898b80d409ae16b049d46f883bf763417bb4c8a.zip
units: define appropriate job timeout actions when boot or shutdown timeouts are hit
Using the new JobTimeoutAction= setting make sure we power off the machine after basic.target is queued for longer than 15min but not executed. Similar, if poweroff.target is queued for longer than 30min but does not complete, forcibly turn off the system. Similar, if reboot.target is queued for longer than 30min but does not complete, forcibly reboot the system.
Diffstat (limited to 'units/reboot.target')
-rw-r--r--units/reboot.target2
1 files changed, 2 insertions, 0 deletions
diff --git a/units/reboot.target b/units/reboot.target
index dec8f56796..668b98d9e4 100644
--- a/units/reboot.target
+++ b/units/reboot.target
@@ -12,6 +12,8 @@ DefaultDependencies=no
Requires=systemd-reboot.service
After=systemd-reboot.service
AllowIsolate=yes
+JobTimeoutSec=30min
+JobTimeoutAction=reboot-force
[Install]
Alias=ctrl-alt-del.target