diff options
author | Rob Crittenden <rcritten@redhat.com> | 2010-12-13 14:28:11 -0500 |
---|---|---|
committer | Simo Sorce <ssorce@redhat.com> | 2010-12-17 17:31:19 -0500 |
commit | 1600146c942eedcbeb4f67537ee35d1e73c46b24 (patch) | |
tree | f3635700a6ba229b7cfed7fb135211629beeb248 /ipaserver | |
parent | 358b28398cad150d6aab873a2d998211bf31d335 (diff) | |
download | freeipa-1600146c942eedcbeb4f67537ee35d1e73c46b24.tar.gz freeipa-1600146c942eedcbeb4f67537ee35d1e73c46b24.tar.xz freeipa-1600146c942eedcbeb4f67537ee35d1e73c46b24.zip |
Verify that the replication plugin exists before setting up replicas.
ticket 502
Diffstat (limited to 'ipaserver')
-rw-r--r-- | ipaserver/install/replication.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ipaserver/install/replication.py b/ipaserver/install/replication.py index ed1badc1e..cdff50e7f 100644 --- a/ipaserver/install/replication.py +++ b/ipaserver/install/replication.py @@ -19,6 +19,7 @@ import time, logging +import os import ldap from ipaserver import ipaldap from ldap import modlist @@ -39,6 +40,19 @@ WINSYNC = 2 SASL_AUTH = ldap.sasl.sasl({}, 'GSSAPI') +def check_replication_plugin(): + """ + Confirm that the 389-ds replication is installed. + + Emit a message and return True/False + """ + if not os.path.exists('/usr/lib/dirsrv/plugins/libreplication-plugin.so') and \ + not os.path.exists('/usr/lib64/dirsrv/plugins/libreplication-plugin.so'): + print "The 389-ds replication plug-in was not found on this system" + return False + + return True + class ReplicationManager: """Manage replication agreements between DS servers, and sync agreements with Windows servers""" |