summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Kosek <mkosek@redhat.com>2012-12-18 13:22:40 +0100
committerMartin Kosek <mkosek@redhat.com>2012-12-18 17:49:20 +0100
commit03c15741e38a972803a3532514fabb1981203e27 (patch)
tree7d32592ea7a390d2f184c9ec3efe5a3a36e6639e
parent17615fafd2abe5ea7ea980462c85c11d9d4d8434 (diff)
downloadfreeipa.git-03c15741e38a972803a3532514fabb1981203e27.tar.gz
freeipa.git-03c15741e38a972803a3532514fabb1981203e27.tar.xz
freeipa.git-03c15741e38a972803a3532514fabb1981203e27.zip
Enable SSSD on client install
authconfig component changed its behavior. It no longer starts and enables SSSD daemon when --enablesssd and --enablesssdauth options are used. It only enables the PAM module and adds SSSD to nsswitch. Enable SSSD on new client/server installs manually. Also make sure that we stop&disable SSSD when we delete the configuration. https://fedorahosted.org/freeipa/ticket/3307
-rwxr-xr-xipa-client/ipa-install/ipa-client-install18
1 files changed, 18 insertions, 0 deletions
diff --git a/ipa-client/ipa-install/ipa-client-install b/ipa-client/ipa-install/ipa-client-install
index 7c329029..a38c8280 100755
--- a/ipa-client/ipa-install/ipa-client-install
+++ b/ipa-client/ipa-install/ipa-client-install
@@ -454,6 +454,18 @@ def uninstall(options, env):
root_logger.info("Redundant SSSD configuration file " +
"/etc/sssd/sssd.conf was moved to /etc/sssd/sssd.conf.deleted")
+ sssd = ipaservices.service('sssd')
+ try:
+ sssd.stop()
+ except CalledProcessError:
+ root_logger.warning("SSSD service could not be stopped")
+
+ try:
+ sssd.disable()
+ except CalledProcessError, e:
+ root_logger.warning(
+ "Failed to disable automatic startup of the SSSD daemon: %s", e)
+
if fstore.has_files():
root_logger.info("Restoring client configuration files")
ipaservices.restore_network_configuration(fstore, statestore)
@@ -1855,6 +1867,12 @@ def install(options, env, fstore, statestore):
except CalledProcessError:
root_logger.warning("SSSD service restart was unsuccessful.")
+ try:
+ sssd.enable()
+ except CalledProcessError, e:
+ root_logger.warning(
+ "Failed to enable automatic startup of the SSSD daemon: %s", e)
+
if not options.sssd:
#Modify pam to add pam_krb5 only when sssd is not in use
auth_config.reset()