590d18
From 908019639e5e0975d3cd73c3c851319224737dcd Mon Sep 17 00:00:00 2001
590d18
From: Martin Basti <mbasti@redhat.com>
590d18
Date: Thu, 10 Sep 2015 18:46:00 +0200
590d18
Subject: [PATCH] Server Upgrade: backup CS.cfg when dogtag is turned off
590d18
590d18
Is unable to made CS.cfg when dogtag is running.
590d18
590d18
https://fedorahosted.org/freeipa/ticket/5287
590d18
590d18
Reviewed-By: David Kupka <dkupka@redhat.com>
590d18
---
590d18
 ipaserver/install/server/upgrade.py | 5 ++++-
590d18
 1 file changed, 4 insertions(+), 1 deletion(-)
590d18
590d18
diff --git a/ipaserver/install/server/upgrade.py b/ipaserver/install/server/upgrade.py
590d18
index a57682a4bbdaab2a15b4e415223e2f5faa67ba73..5288f8fcc5fb56b13773e3bb8ea6a5a6c8c0e8a9 100644
590d18
--- a/ipaserver/install/server/upgrade.py
590d18
+++ b/ipaserver/install/server/upgrade.py
590d18
@@ -1354,10 +1354,13 @@ def upgrade_configuration():
590d18
         sub_dict['SUBJECT_BASE'] = subject_base
590d18
 
590d18
     ca = cainstance.CAInstance(api.env.realm, certs.NSS_DIR)
590d18
-    ca.backup_config()
590d18
 
590d18
     with installutils.stopped_service(configured_constants.SERVICE_NAME,
590d18
             configured_constants.PKI_INSTANCE_NAME):
590d18
+
590d18
+        # Dogtag must be stopped to be able to backup CS.cfg config
590d18
+        ca.backup_config()
590d18
+
590d18
         # migrate CRL publish dir before the location in ipa.conf is updated
590d18
         ca_restart = migrate_crl_publish_dir(ca)
590d18
 
590d18
-- 
590d18
2.4.3
590d18