]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr/cephadm: make drain adjust crush weight if not replacing
authorSage Weil <sage@newdream.net>
Wed, 17 Feb 2021 16:28:05 +0000 (10:28 -0600)
committerMichael Fritch <mfritch@suse.com>
Mon, 13 Jun 2022 16:31:37 +0000 (10:31 -0600)
commita46c2004218c5d7a30bcb1d2091f0e003e55aa95
tree5385e0969a9bcf00148a5ba457e6e474a5837430
parent6160011d37fdeb18f5497b65895e71ba275cf72e
mgr/cephadm: make drain adjust crush weight if not replacing

If we are replacing an OSD, we should mark it out and then back in
again when a new device shows up.  However, if we are going to
destroy an OSD, we should just weight it to 0 in crush, so that data
doesn't move again once the OSD is purged.

Signed-off-by: Sage Weil <sage@newdream.net>
(cherry picked from commit 4fc1309f281356db0a074da22aa6f2daa034df8d)
src/pybind/mgr/cephadm/services/osd.py