On 08/18/2015 02:05 PM, Jan Cholasta wrote:
On 18.8.2015 13:41, Martin Basti wrote:
On 08/18/2015 01:16 PM, Alexander Bokovoy wrote:
On Tue, 18 Aug 2015, Martin Babinsky wrote:
From d86aae6c3fef4dea1afbbdbacbc978afbbfa5fcf Mon Sep 17 00:00:00 2001
From: Martin Babinsky <mbabi...@redhat.com>
Date: Tue, 18 Aug 2015 12:47:46 +0200
Subject: [PATCH] ipa-restore: check whether DS is running before
ipaserver/install/ipa_restore.py | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/ipaserver/install/ipa_restore.py
@@ -410,6 +410,13 @@ class Restore(admintool.AdminTool):
Create an ldapi connection and bind to it using autobind as
+ instance_name = installutils.realm_to_serverid(api.env.realm)
+ if not
+ raise admintool.ScriptError(
+ "directory server instance is not running/configured"
if self._conn is not None:
I didn't try, but I'm pretty sure this patch breaks ipa-restore on
systems without IPA installed, which was not at all the point of the
ticket - the point was to replace the "Unable to get connection,
skipping disabling agreements: Unable to bind to LDAP server: [Errno 2]
No such file or directory" error message with something meaningful in
such a case.
I have just now tested ipa-restore without installed IPA master and it
works just fine.
The point of my patch was no not even try to connect to DS if the
instance is not running/configured and raise an error telling this fact
to the user, instead of timing out on connection and then raising a
So unless I missed something it should be ok.
Manage your subscription for the Freeipa-devel mailing list:
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code