From 6d34c2169fcd520cc726e58e01d008ae3637aad4 Mon Sep 17 00:00:00 2001 From: Jan Cholasta Date: Mon, 20 Feb 2017 08:24:47 +0100 Subject: [PATCH] server upgrade: uninstall ipa_memcached properly Make sure ipa_memcached is not running and no stale state is left in the sysupgrade state file on server upgrade. https://fedorahosted.org/freeipa/ticket/5959 Reviewed-By: Stanislav Laznicka --- ipaserver/install/server/upgrade.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/ipaserver/install/server/upgrade.py b/ipaserver/install/server/upgrade.py index 1acad5556..26f6b8ffe 100644 --- a/ipaserver/install/server/upgrade.py +++ b/ipaserver/install/server/upgrade.py @@ -79,14 +79,12 @@ def uninstall_ipa_memcached(): We can't use the full service uninstaller because that will attempt to stop and disable the service which by now doesn't exist. We just want to clean up sysrestore.state to remove all references to - ipa_kpasswd. + ipa_memcached. """ ipa_memcached = service.SimpleServiceInstance('ipa_memcached') - enabled = not ipa_memcached.restore_state("enabled") + ipa_memcached.uninstall() - if enabled is not None and not enabled: - ipa_memcached.remove() def backup_file(filename, ext): """Make a backup of filename using ext as the extension. Do not overwrite