]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm: don't redeploy osds seen in raw list if cephadm knows them 46545/head
authorAdam King <adking@redhat.com>
Mon, 6 Jun 2022 21:39:31 +0000 (17:39 -0400)
committerAdam King <adking@redhat.com>
Mon, 6 Jun 2022 21:39:31 +0000 (17:39 -0400)
As is already done when checking the lvm list
results and should also be done for checking raw
list but is missing do ot a backporting mistake

Tachnically a partial backport of #44228 that
was not included in #44627 because raw osd support
was not in pacific then

Signed-off-by: Adam King <adking@redhat.com>
src/pybind/mgr/cephadm/services/osd.py

index e00ca76224012960963155c27aa51562caf93e7c..5899ba49a98e2b7a9182ba26312b2bd3135eb9e8 100644 (file)
@@ -162,6 +162,10 @@ class OSDService(CephService):
             if osd_id in before_osd_uuid_map and osd_id not in replace_osd_ids:
                 # if it exists but is part of the replacement operation, don't skip
                 continue
+            if self.mgr.cache.has_daemon(f'osd.{osd_id}', host):
+                # cephadm daemon instance already exists
+                logger.debug(f'osd id {osd_id} daemon already exists')
+                continue
             if osd_id not in osd_uuid_map:
                 logger.debug('osd id {} does not exist in cluster'.format(osd_id))
                 continue