From 057338937018d5a05e9c51c75c5fb352b2742499 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Wed, 14 Oct 2009 11:50:00 -0400 Subject: Be more forgiving when trying to replace older DS schema. We have to replace 05rfc2247.ldif because it contains some conflicting attributes with DNS in some older versions of 389-DS/RHDS. This fails on some newer versions of 389-DS/RHDS so this lets it continue installing if the new file is not needed. --- ipaserver/install/dsinstance.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'ipaserver/install/dsinstance.py') diff --git a/ipaserver/install/dsinstance.py b/ipaserver/install/dsinstance.py index ea9f26da..254c575c 100644 --- a/ipaserver/install/dsinstance.py +++ b/ipaserver/install/dsinstance.py @@ -274,10 +274,14 @@ class DsInstance(service.Service): schema_dirname(self.serverid) + "60basev2.ldif") shutil.copyfile(ipautil.SHARE_DIR + "60policyv2.ldif", schema_dirname(self.serverid) + "60policyv2.ldif") - shutil.move(schema_dirname(self.serverid) + "05rfc2247.ldif", - schema_dirname(self.serverid) + "05rfc2247.ldif.old") - shutil.copyfile(ipautil.SHARE_DIR + "05rfc2247.ldif", - schema_dirname(self.serverid) + "05rfc2247.ldif") + try: + shutil.move(schema_dirname(self.serverid) + "05rfc2247.ldif", + schema_dirname(self.serverid) + "05rfc2247.ldif.old") + shutil.copyfile(ipautil.SHARE_DIR + "05rfc2247.ldif", + schema_dirname(self.serverid) + "05rfc2247.ldif") + except IOError: + # Does not apply with newer DS releases + pass def __restart_instance(self): try: -- cgit