Removed dependency and ordering on unbound-anchor.service in unbound.service

Once ntpdate.service is fixed to order itself After nss-lookup.target,
there will be an ordering loop. To reproduce this do:

[root@notas ~]# yum -y install unbound ntpdate chrony
[root@notas ~]# systemctl enable ntpdate.service chronyd.service unbound-anchor.timer unbound.service unbound-anchor.service
[root@notas ~]# systemd-analyze verify /usr/lib/systemd/system/*

And then in the output you can find:
Found ordering cycle on ntpdate.service/stop
Found dependency on nss-lookup.target/start
Found dependency on unbound.service/start
Found dependency on unbound-anchor.service/start
Found dependency on unbound-anchor.timer/start
Found dependency on time-sync.target/start
Found dependency on chrony-wait.service/stop
Found dependency on chronyd.service/stop
Found dependency on ntpdate.service/stop

Signed-off-by: Tomas Hozza <thozza@redhat.com>
This commit is contained in:
Tomas Hozza 2015-09-15 14:44:53 +02:00
parent 61d5f48558
commit bbc56d0b27
2 changed files with 5 additions and 3 deletions

View File

@ -3,8 +3,6 @@ Description=Unbound recursive Domain Name Server
After=network.target After=network.target
After=unbound-keygen.service After=unbound-keygen.service
Wants=unbound-keygen.service Wants=unbound-keygen.service
After=unbound-anchor.service
Wants=unbound-anchor.service
Wants=unbound-anchor.timer Wants=unbound-anchor.timer
Before=nss-lookup.target Before=nss-lookup.target
Wants=nss-lookup.target Wants=nss-lookup.target
@ -13,6 +11,7 @@ Wants=nss-lookup.target
Type=simple Type=simple
EnvironmentFile=-/etc/sysconfig/unbound EnvironmentFile=-/etc/sysconfig/unbound
ExecStartPre=/usr/sbin/unbound-checkconf ExecStartPre=/usr/sbin/unbound-checkconf
ExecStartPre=-/usr/sbin/unbound-anchor -a /var/lib/unbound/root.key -c /etc/unbound/icannbundle.pem
ExecStart=/usr/sbin/unbound -d $UNBOUND_OPTIONS ExecStart=/usr/sbin/unbound -d $UNBOUND_OPTIONS
ExecReload=/usr/sbin/unbound-control reload ExecReload=/usr/sbin/unbound-control reload

View File

@ -21,7 +21,7 @@
Summary: Validating, recursive, and caching DNS(SEC) resolver Summary: Validating, recursive, and caching DNS(SEC) resolver
Name: unbound Name: unbound
Version: 1.5.4 Version: 1.5.4
Release: 4%{?extra_version:.%{extra_version}}%{?dist} Release: 5%{?extra_version:.%{extra_version}}%{?dist}
License: BSD License: BSD
Url: http://www.nlnetlabs.nl/unbound/ Url: http://www.nlnetlabs.nl/unbound/
Source: http://www.unbound.net/downloads/%{name}-%{version}%{?extra_version}.tar.gz Source: http://www.unbound.net/downloads/%{name}-%{version}%{?extra_version}.tar.gz
@ -430,6 +430,9 @@ popd
%changelog %changelog
* Tue Sep 15 2015 Tomas Hozza <thozza@redhat.com> - 1.5.4-5
- Removed dependency and ordering on unbound-anchor.service in unbound.service
* Thu Sep 03 2015 Tomas Hozza <thozza@redhat.com> - 1.5.4-4 * Thu Sep 03 2015 Tomas Hozza <thozza@redhat.com> - 1.5.4-4
- Prefer Python3 build over Python2 build for now (#1254566) - Prefer Python3 build over Python2 build for now (#1254566)