diff --git a/src/mds/MDSRankQuiesce.cc b/src/mds/MDSRankQuiesce.cc index 27425497b14..0b753865698 100644 --- a/src/mds/MDSRankQuiesce.cc +++ b/src/mds/MDSRankQuiesce.cc @@ -253,7 +253,8 @@ void MDSRank::quiesce_cluster_update() { for (auto&& [gid, info] : mdsmap->get_mds_info()) { // if it has a rank and state <= ACTIVE, it's good enough - if (info.rank != MDS_RANK_NONE && info.state <= MDSMap::STATE_ACTIVE) { + // if (info.rank != MDS_RANK_NONE && info.state <= MDSMap::STATE_ACTIVE) { + if (info.rank != MDS_RANK_NONE && info.state == MDSMap::STATE_ACTIVE) { member_info.push(&info); membership.members.insert(info.global_id); } diff --git a/src/pybind/mgr/mgr_module.py b/src/pybind/mgr/mgr_module.py index e75a5765902..16cad364182 100644 --- a/src/pybind/mgr/mgr_module.py +++ b/src/pybind/mgr/mgr_module.py @@ -1774,7 +1774,7 @@ class MgrModule(ceph_module.BaseMgrModule, MgrModuleLoggingMixin): state_ord = self.MDS_STATE_ORD.get(info['state']) leader_state_ord = self.MDS_STATE_ORD.get(leader_info['state']) - if state_ord <= self.MDS_STATE_ACTIVE_ORD and state_ord > leader_state_ord: + if state_ord == self.MDS_STATE_ACTIVE_ORD and state_ord > leader_state_ord: leader_info = info break