From d3f870ebb8db6f5c9338bf5bff37a48239c4965a Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 31 Oct 2019 10:22:35 -0500 Subject: [PATCH] ceph-daemon: stop + reset-failed existing unit on daemon deploy Normally it won't exist, but it will on a re-deploy. Signed-off-by: Sage Weil --- src/ceph-daemon | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ceph-daemon b/src/ceph-daemon index e6aebed80c8b2..b37f0d212b615 100755 --- a/src/ceph-daemon +++ b/src/ceph-daemon @@ -503,6 +503,10 @@ def deploy_daemon_units(fsid, uid, gid, daemon_type, daemon_id, c, call_throws(['systemctl', 'daemon-reload']) unit_name = get_unit_name(fsid, daemon_type, daemon_id) + call(['systemctl', 'stop', unit_name], + verbose_on_failure=False) + call(['systemctl', 'reset-failed', unit_name], + verbose_on_failure=False) if enable: call_throws(['systemctl', 'enable', unit_name]) if start: -- 2.39.5