summaryrefslogtreecommitdiffstats
path: root/pykolab/setup/setup_ldap.py
diff options
context:
space:
mode:
Diffstat (limited to 'pykolab/setup/setup_ldap.py')
-rw-r--r--pykolab/setup/setup_ldap.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/pykolab/setup/setup_ldap.py b/pykolab/setup/setup_ldap.py
index 1449a59..8dc6327 100644
--- a/pykolab/setup/setup_ldap.py
+++ b/pykolab/setup/setup_ldap.py
@@ -417,6 +417,7 @@ ServerAdminPwd = %(admin_pass)s
schema_error = True
if os.path.isfile('/bin/systemctl'):
+ subprocess.call(['/bin/systemctl', 'restart', 'dirsrv.target'])
subprocess.call(['/bin/systemctl', 'restart', 'dirsrv@' + _input['hostname']])
time.sleep(20)
elif os.path.isfile('/sbin/service'):
@@ -429,6 +430,7 @@ ServerAdminPwd = %(admin_pass)s
log.error(_("Could not start the directory server service."))
if os.path.isfile('/bin/systemctl'):
+ subprocess.call(['/bin/systemctl', 'enable', 'dirsrv.target'])
subprocess.call(['/bin/systemctl', 'enable', 'dirsrv@' + _input['hostname']])
elif os.path.isfile('/sbin/chkconfig'):
subprocess.call(['/sbin/chkconfig', 'dirsrv', 'on'])