summaryrefslogtreecommitdiff
path: root/src/login
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2013-02-22 11:21:47 +0100
committerMichal Schmidt <mschmidt@redhat.com>2013-02-22 16:06:17 +0100
commitb85bdddafb321fa870b9250a2ff17040d6996061 (patch)
tree7063d5b8cb26bdf13575b1c54a484e08c563d212 /src/login
parent23ade460e5a118daa575a961b405d089f95e0617 (diff)
systemctl: make shutdown operations use irreversible jobs
Occasionally people report problem with reboot/poweroff operations hanging in the middle. One known cause is when a new transaction to start a unit is enqueued while the shutdown is going on. The start of the unit conflicts with the shutdown jobs, so they get cancelled. The failure case can be quite unpleasant, becase getty and sshd may already be stopped. Fix it by using irreversible jobs for shutdown (reboot/poweroff/...) actions. This applies to commands like "reboot", "telinit 6", "systemctl reboot". Should someone desire to use reversible jobs, they can say "systemctl start reboot.target".`
Diffstat (limited to 'src/login')
-rw-r--r--src/login/logind-dbus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c
index d235474a23..818f2fa808 100644
--- a/src/login/logind-dbus.c
+++ b/src/login/logind-dbus.c
@@ -1051,7 +1051,7 @@ static int execute_shutdown_or_sleep(
DBusError *error) {
_cleanup_dbus_message_unref_ DBusMessage *reply = NULL;
- const char *mode = "replace", *p;
+ const char *mode = "replace-irreversibly", *p;
int r;
char *c;