From dfb6e891b95f0b2d6f446b112c532a95fb629d65 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 23 Aug 2012 11:11:14 -0400 Subject: [PATCH] switch-to-configuration: Don't restart systemd-user-sessions.service Restarting it causes all user sessions to be killed. --- modules/system/activation/switch-to-configuration.pl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/system/activation/switch-to-configuration.pl b/modules/system/activation/switch-to-configuration.pl index 1d2da3cbf8e0..eb5a7a690f05 100644 --- a/modules/system/activation/switch-to-configuration.pl +++ b/modules/system/activation/switch-to-configuration.pl @@ -130,7 +130,9 @@ while (my ($unit, $state) = each %{$activePrev}) { # FIXME: do something? } else { my $unitInfo = parseUnit($newUnitFile); - if (!boolIsTrue($unitInfo->{'X-RestartIfChanged'} // "true")) { + if (!boolIsTrue($unitInfo->{'X-RestartIfChanged'} // "true") + || $unit eq "systemd-user-sessions.service") + { push @unitsToSkip, $unit; } else { # Record that this unit needs to be started below. We