daandemeyer / rpms / systemd

Forked from rpms/systemd 2 years ago
Clone
661545
From 9335b508002f0d10c64011a90d81b515b53f0ac3 Mon Sep 17 00:00:00 2001
661545
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
661545
Date: Tue, 31 Jan 2017 00:34:33 -0500
661545
Subject: [PATCH] units: restore Before dependencies for
661545
 systemd-vconsole-setup.service
661545
661545
When the service is run in the initramfs, it is possible for it to get started
661545
and not be fast enough to exit before the root switch happens. It is started
661545
multiple times (depending on the consoles being detected), and runs
661545
asynchronously, so this is quite likely. It'll then get killed by killall(),
661545
and systemd will consider the service failed. To avoid all this, just wait
661545
for the service to terminate on it's own.
661545
661545
Before=initrd-switch-root.target should be good for the initramfs, and
661545
Before=shutdown.tuarget should be good for the real system, although it's
661545
unlikely to make any difference there.
661545
661545
(cherry picked from commit 750e550eba362096d56a35104c6a32631aa67b8e)
661545
661545
Related: #1754053
661545
---
661545
 units/systemd-vconsole-setup.service.in | 2 +-
661545
 1 file changed, 1 insertion(+), 1 deletion(-)
661545
661545
diff --git a/units/systemd-vconsole-setup.service.in b/units/systemd-vconsole-setup.service.in
661545
index 18faa63f28..8aba67b393 100644
661545
--- a/units/systemd-vconsole-setup.service.in
661545
+++ b/units/systemd-vconsole-setup.service.in
661545
@@ -11,7 +11,7 @@ Documentation=man:systemd-vconsole-setup.service(8) man:vconsole.conf(5)
661545
 DefaultDependencies=no
661545
 Conflicts=shutdown.target
661545
 After=systemd-readahead-collect.service systemd-readahead-replay.service
661545
-Before=sysinit.target shutdown.target
661545
+Before=sysinit.target initrd-switch-root.target shutdown.target
661545
 ConditionPathExists=/dev/tty0
661545
 
661545
 [Service]