]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm: add "original_weight" parameter to OSD class 59410/head
authorAdam King <adking@redhat.com>
Mon, 19 Aug 2024 16:30:24 +0000 (12:30 -0400)
committerAdam King <adking@redhat.com>
Thu, 22 Aug 2024 17:59:47 +0000 (13:59 -0400)
Fixes: https://tracker.ceph.com/issues/67329
Signed-off-by: Adam King <adking@redhat.com>
(cherry picked from commit 04330f5df92994882efcd4879d5c37279138e97b)

src/pybind/mgr/cephadm/services/osd.py

index 75b3fc58c761e0a50544a2fe48adc8bdef9fbc05..9b09b8c9f492556c8ae19b116bfe8a923778d423 100644 (file)
@@ -621,7 +621,8 @@ class OSD:
                  force: bool = False,
                  hostname: Optional[str] = None,
                  zap: bool = False,
-                 no_destroy: bool = False):
+                 no_destroy: bool = False,
+                 original_weight: Optional[float] = None):
         # the ID of the OSD
         self.osd_id = osd_id
 
@@ -656,7 +657,7 @@ class OSD:
         # mgr obj to make mgr/mon calls
         self.rm_util: RemoveUtil = remove_util
 
-        self.original_weight: Optional[float] = None
+        self.original_weight: Optional[float] = original_weight
 
         # Whether devices associated with the OSD should be zapped (DATA ERASED)
         self.zap = zap