diff --git a/server/schedule/checker/rule_checker.go b/server/schedule/checker/rule_checker.go index da707488ea36..33156d181aeb 100644 --- a/server/schedule/checker/rule_checker.go +++ b/server/schedule/checker/rule_checker.go @@ -462,7 +462,7 @@ func (c *RuleChecker) fixOrphanPeers(region *core.RegionInfo, fit *placement.Reg if pinDownPeer.GetIsWitness() || orphanPeer.GetIsWitness() { continue } - // down peer's store should be disconnected + // pinDownPeer's store should be disconnected, because we use more strict judge before. if !isDisconnectedPeer(pinDownPeer) { continue } @@ -497,10 +497,6 @@ func (c *RuleChecker) fixOrphanPeers(region *core.RegionInfo, fit *placement.Reg checkerCounter.WithLabelValues("rule_checker", "remove-orphan-peer").Inc() return operator.CreateRemovePeerOperator("remove-unhealthy-orphan-peer", c.cluster, 0, region, orphanPeer.StoreId) } - if isDisconnectedPeer(orphanPeer) { - checkerCounter.WithLabelValues("rule_checker", "remove-orphan-peer").Inc() - return operator.CreateRemovePeerOperator("remove-disconnected-orphan-peer", c.cluster, 0, region, orphanPeer.StoreId) - } if hasHealthPeer { // there already exists a healthy orphan peer, so we can remove other orphan Peers. checkerCounter.WithLabelValues("rule_checker", "remove-orphan-peer").Inc()