File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -1941,6 +1941,10 @@ void PGMap::get_stuck_stats(
19411941 val = i->second .last_unstale ;
19421942 }
19431943
1944+ if ((types & STUCK_PEERING) && (i->second .state & PG_STATE_PEERING)) {
1945+ if (i->second .last_peered < val)
1946+ val = i->second .last_peered ;
1947+ }
19441948 // val is now the earliest any of the requested stuck states began
19451949 if (val < cutoff) {
19461950 stuck_pgs[i->first ] = i->second ;
@@ -1991,6 +1995,8 @@ int PGMap::dump_stuck_pg_stats(
19911995 stuck_types |= PGMap::STUCK_DEGRADED;
19921996 else if (*i == " stale" )
19931997 stuck_types |= PGMap::STUCK_STALE;
1998+ else if (*i == " peering" )
1999+ stuck_types |= PGMap::STUCK_PEERING;
19942000 else {
19952001 ds << " Unknown type: " << *i << std::endl;
19962002 return -EINVAL;
@@ -3852,6 +3858,7 @@ static void _try_mark_pg_stale(
38523858 newstat->state |= PG_STATE_STALE;
38533859 newstat->last_unstale = ceph_clock_now ();
38543860 }
3861+
38553862}
38563863
38573864void PGMapUpdater::check_down_pgs (
Original file line number Diff line number Diff line change @@ -359,7 +359,8 @@ class PGMap : public PGMapDigest {
359359 static const int STUCK_UNDERSIZED = (1 <<2 );
360360 static const int STUCK_DEGRADED = (1 <<3 );
361361 static const int STUCK_STALE = (1 <<4 );
362-
362+ static const int STUCK_PEERING = (1 <<5 );
363+
363364 PGMap ()
364365 : version(0 ),
365366 last_osdmap_epoch (0 ), last_pg_scan(0 )
You can’t perform that action at this time.
0 commit comments