From 4215a9d83ee6e525e0b528d60b5d883ef1a8c4e2395489c57bf8745d9fea0420 Mon Sep 17 00:00:00 2001 From: OBS User mrdocs Date: Mon, 3 Jul 2017 22:11:50 +0000 Subject: [PATCH] Accepting request 507735 from home:dimstar:Factory - Run systemctl daemon-reload even when this is not build with systemd support: if installing bind on a systemd service and not reloading systemd daemon, then the service 'named' is not known right after package installation, causing confusion. OBS-URL: https://build.opensuse.org/request/show/507735 OBS-URL: https://build.opensuse.org/package/show/network/bind?expand=0&rev=212 --- bind.changes | 8 ++++++++ bind.spec | 7 +++++++ 2 files changed, 15 insertions(+) diff --git a/bind.changes b/bind.changes index e63ed24..03f48ce 100644 --- a/bind.changes +++ b/bind.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Mon Jul 3 08:47:39 UTC 2017 - dimstar@opensuse.org + +- Run systemctl daemon-reload even when this is not build with + systemd support: if installing bind on a systemd service and not + reloading systemd daemon, then the service 'named' is not known + right after package installation, causing confusion. + ------------------------------------------------------------------- Fri Jun 30 07:12:50 UTC 2017 - sflees@suse.de diff --git a/bind.spec b/bind.spec index 3a2f7f6..744bdd3 100644 --- a/bind.spec +++ b/bind.spec @@ -734,6 +734,13 @@ if [ -f ${NAMED_ACTIVE_FILE} ]; then sbin/insserv named test ! -s ${NAMED_ACTIVE_FILE} && rm -f ${NAMED_ACTIVE_FILE} fi +if [ -x %{_bindir}/systemctl ]; then +# make sure systemctl knows about the service even though it's not a systemd service +# Without this, systemctl status named would return +# Unit named.service could not be found. +# until systemctl daemon-reload has been executed + %{_bindir}/systemctl daemon-reload || : +fi %endif %postun