diff options
Diffstat (limited to 'ipa-admintools/ipa-moddelegation')
-rw-r--r-- | ipa-admintools/ipa-moddelegation | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ipa-admintools/ipa-moddelegation b/ipa-admintools/ipa-moddelegation index 03b0dc4a8..103c0586d 100644 --- a/ipa-admintools/ipa-moddelegation +++ b/ipa-admintools/ipa-moddelegation @@ -32,6 +32,7 @@ import kerberos import krbV import ldap import copy +import errno aci_fields = ['*', 'aci'] @@ -142,8 +143,11 @@ def main(): aci_entry.setValue('aci', new_aci_str_list) client.update_entry(aci_entry) - except xmlrpclib.Fault, f: - print f.faultString + except xmlrpclib.Fault, fault: + if fault.faultCode == errno.ECONNREFUSED: + print "The IPA XML-RPC service is not responding." + else: + print fault.faultString return 1 except kerberos.GSSError, e: print "Could not initialize GSSAPI: %s/%s" % (e[0][0][0], e[0][1][0]) |