diff options
author | Rob Crittenden <rcritten@redhat.com> | 2008-11-12 10:08:05 -0500 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2008-11-12 15:54:54 -0500 |
commit | 865b73e80369bdd8a7b44c723654984de36dd4e1 (patch) | |
tree | 3061423f97248a5b3bf83a73b6fd210b6ded08ce | |
parent | 2fb4df504cdc9fe196ce8b13634736a53f7837f8 (diff) | |
download | freeipa-865b73e80369bdd8a7b44c723654984de36dd4e1.tar.gz freeipa-865b73e80369bdd8a7b44c723654984de36dd4e1.tar.xz freeipa-865b73e80369bdd8a7b44c723654984de36dd4e1.zip |
Present a less-cryptic error if the replication agreement doesn't exist
-rwxr-xr-x | ipa-server/ipa-install/ipa-replica-manage | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ipa-server/ipa-install/ipa-replica-manage b/ipa-server/ipa-install/ipa-replica-manage index c0051c7f..fdd803f6 100755 --- a/ipa-server/ipa-install/ipa-replica-manage +++ b/ipa-server/ipa-install/ipa-replica-manage @@ -95,7 +95,10 @@ def list_masters(replman, verbose): print " last update ended: %s" % str(ipautil.parse_generalized_time(entry.nsds5replicalastupdateend)) def del_master(replman, hostname): - t = replman.get_agreement_type(hostname) + try: + t = replman.get_agreement_type(hostname) + except ipaerror.exception_for(ipaerror.LDAP_NOT_FOUND): + print "No replication agreement found for %s" % hostname if t == replication.IPA_REPLICA: dirman_passwd = getpass.getpass("Directory Manager password (%s): " % hostname) |