https://fedorahosted.org/freeipa/ticket/5262

Patch attached, detailed description in the commit message.
From 4c674535fa994a2a7c4208d3382c41bc6692e04e Mon Sep 17 00:00:00 2001
From: Martin Basti <mba...@redhat.com>
Date: Thu, 14 Jan 2016 14:52:15 +0100
Subject: [PATCH] Fix: uninstall does not stop named-pkcs11 and
 ipa-ods-exporter

ipactl is not aware of new services installed later, if ipactl restart
or start has not been executed.

This commit is workaround, proper fix may need to improve ipactl.

https://fedorahosted.org/freeipa/ticket/5262
---
 install/tools/ipa-ca-install  | 3 +++
 install/tools/ipa-dns-install | 4 ++++
 2 files changed, 7 insertions(+)

diff --git a/install/tools/ipa-ca-install b/install/tools/ipa-ca-install
index f39847b9011fe801be48c40f44eb43f599c5bc90..83cf98ec6a34093c826470e06ad448e6033bc682 100755
--- a/install/tools/ipa-ca-install
+++ b/install/tools/ipa-ca-install
@@ -295,6 +295,9 @@ def main():
     else:
         install(safe_options, options, filename)
 
+    # execute ipactl to refresh services status
+    ipautil.run(['ipactl', 'start', '--ignore-service-failures'],
+                raiseonerr=False)
 
 fail_message = '''
 Your system may be partly configured.
diff --git a/install/tools/ipa-dns-install b/install/tools/ipa-dns-install
index 91f608941d2dcced898c7ea2e479382ef307490c..2eb1d0258bd6e323f9659da84692facef85a788d 100755
--- a/install/tools/ipa-dns-install
+++ b/install/tools/ipa-dns-install
@@ -149,6 +149,10 @@ def main():
     service.print_msg("Restarting the web server")
     http.restart()
 
+    # execute ipactl to refresh services status
+    ipautil.run(['ipactl', 'start', '--ignore-service-failures'],
+                raiseonerr=False)
+
     return 0
 
 if __name__ == '__main__':
-- 
2.5.0

-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to