[PATCH 2/2] fix systemd unit dependency cycle

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



backported from the following upstream commit:
https://git.launchpad.net/cloud-init/commit/?id=3705bb5964a2ff3f9a67265e6d090a112b35e40c

fixes the following bz:
https://bugzilla.redhat.com/show_bug.cgi?id=1393094
---
 cloud-init-0.7.8-systemd-loop.target | 37 ++++++++++++++++++++++++++++++++++++
 cloud-init.spec                      |  7 ++++++-
 2 files changed, 43 insertions(+), 1 deletion(-)
 create mode 100644 cloud-init-0.7.8-systemd-loop.target

diff --git a/cloud-init-0.7.8-systemd-loop.target b/cloud-init-0.7.8-systemd-loop.target
new file mode 100644
index 0000000..58ab3f8
--- /dev/null
+++ b/cloud-init-0.7.8-systemd-loop.target
@@ -0,0 +1,37 @@
+From 3705bb5964a2ff3f9a67265e6d090a112b35e40c Mon Sep 17 00:00:00 2001
+From: Scott Moser <smoser@xxxxxxxxxxxx>
+Date: Thu, 15 Sep 2016 09:30:50 -0400
+Subject: [PATCH] systemd: put cloud-init.target After multi-user.target
+
+When we moved cloud-final.service to run After multi-user.target it
+caused a dependency loop (as cloud-init.target was still implied to be
+Before multi-user.target).
+
+journalctl would either show:
+  cloud-init.target: Breaking ordering cycle by deleting job
+     cloud-final.service/start
+or
+  multi-user.target: Breaking ordering cycle by deleting job
+     cloud-init.target/start
+
+The fix here is to clearly state that cloud-init.target is also
+  After multi-user.target
+
+LP: #1623868
+---
+ systemd/cloud-init.target | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/systemd/cloud-init.target b/systemd/cloud-init.target
+index a63babb..d568458 100644
+--- a/systemd/cloud-init.target
++++ b/systemd/cloud-init.target
+@@ -4,3 +4,4 @@
+ #  b.) touch a file /etc/cloud/cloud-init.disabled
+ [Unit]
+ Description=Cloud-init target
++After=multi-user.target
+-- 
+2.7.4
+
+
diff --git a/cloud-init.spec b/cloud-init.spec
index 703c93b..c331091 100644
--- a/cloud-init.spec
+++ b/cloud-init.spec
@@ -1,6 +1,6 @@
 Name:           cloud-init
 Version:        0.7.8
-Release:        3%{?dist}
+Release:        4%{?dist}
 Summary:        Cloud instance init scripts
 
 Group:          System Environment/Base
@@ -57,6 +57,11 @@ Patch12:        cloud-init-0.7.8-enable-digitalocean.patch
 # Disable failing GCE tests
 Patch13: Delete-GCE-test-it-s-failing.patch
 
+# Get rid of dependency loop in systemd units
+# https://bugzilla.redhat.com/show_bug.cgi?id=1393094
+# https://git.launchpad.net/cloud-init/commit/?id=3705bb5964a2ff3f9a67265e6d090a112b35e40c
+Patch14:        cloud-init-0.7.8-systemd-loop.target
+
 BuildArch:      noarch
 
 BuildRequires:  pkgconfig
-- 
2.7.4
_______________________________________________
cloud mailing list -- cloud@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to cloud-leave@xxxxxxxxxxxxxxxxxxxxxxx




[Index of Archives]     [Fedora General Discussion]     [Older Fedora Users Archive]     [Fedora Advisory Board]     [Fedora Security]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Mentors]     [Fedora Package Announce]     [Fedora Package Review]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Coolkey]     [Yum Users]     [Big List of Linux Books]     [Yosemite News]     [Linux Apps]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]

  Powered by Linux