diff --git a/src/mon/OSDMonitor.cc b/src/mon/OSDMonitor.cc index 3edacd2ea58..829776e05f4 100644 --- a/src/mon/OSDMonitor.cc +++ b/src/mon/OSDMonitor.cc @@ -3181,8 +3181,9 @@ bool OSDMonitor::check_failures(utime_t now) auto p = failure_info.begin(); while (p != failure_info.end()) { auto& [target_osd, fi] = *p; - if (can_mark_down(target_osd)) { - found_failure |= check_failure(now, target_osd, fi); + if (can_mark_down(target_osd) && + check_failure(now, target_osd, fi)) { + found_failure = true; ++p; } else if (is_failure_stale(now, fi)) { dout(10) << " dropping stale failure_info for osd." << target_osd