switch-to-configuration: Assume that services that are auto-restarting are going to fail
This commit is contained in:
parent
27f496c1ce
commit
d33fd9a1f8
@ -124,10 +124,10 @@ if (scalar @stopped > 0) {
|
|||||||
system("@systemd@/bin/systemctl", "reload", "dbus.service");
|
system("@systemd@/bin/systemctl", "reload", "dbus.service");
|
||||||
|
|
||||||
# Print failed and new units.
|
# Print failed and new units.
|
||||||
my (@failed, @new);
|
my (@failed, @new, @restarting);
|
||||||
my $activeNew = getActiveUnits;
|
my $activeNew = getActiveUnits;
|
||||||
while (my ($unit, $state) = each %{$activeNew}) {
|
while (my ($unit, $state) = each %{$activeNew}) {
|
||||||
push @failed, $unit if $state->{state} eq "failed";
|
push @failed, $unit if $state->{state} eq "failed" || $state->{substate} eq "auto-restart";
|
||||||
push @new, $unit if $state->{state} ne "failed" && !defined $activePrev->{$unit};
|
push @new, $unit if $state->{state} ne "failed" && !defined $activePrev->{$unit};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user