From: Sage Weil Date: Sat, 22 Feb 2020 15:41:30 +0000 (-0600) Subject: mgr/cephadm: upgrade: handle stopped daemons X-Git-Tag: v15.1.1~280^2~1 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=5649d5571c14e6f739e5e6e75dcf28ea7c9fb6c1;p=ceph-ci.git mgr/cephadm: upgrade: handle stopped daemons A stopped daemon should have the correct target_name, and we should ensure that the host has an up-to-date image, so that when it does start it comes up with the new image. If it has an old image name, we should redeploy as per usual. Signed-off-by: Sage Weil --- diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py index 0a5ea3b0669..1feb7911545 100644 --- a/src/pybind/mgr/cephadm/module.py +++ b/src/pybind/mgr/cephadm/module.py @@ -706,6 +706,10 @@ class CephadmOrchestrator(MgrModule, orchestrator.OrchestratorClientMixin): self._update_upgrade_progress(done / len(daemons)) + if d.status <= 0: + if d.container_image_name == target_name: + self.log.debug('daemon %s is stopped but has correct image name' % (d.name())) + continue if not self._wait_for_ok_to_stop(d): return None self.log.info('Upgrade: Redeploying %s.%s' %