We may have log recovery *and* backfill to do, but cease to be degraded
as soon as the log recovery portion is done. If that's the case, clear
the DEGRADED bit so that the PG state is not misleading.
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit
3e91fda79d3be771f46394312a6b72ab75660012)
if (state_test(PG_STATE_RECOVERING)) {
state_clear(PG_STATE_RECOVERING);
state_clear(PG_STATE_FORCED_RECOVERY);
+ if (get_osdmap()->get_pg_size(info.pgid.pgid) <= acting.size()) {
+ state_clear(PG_STATE_DEGRADED);
+ }
if (needs_backfill()) {
dout(10) << "recovery done, queuing backfill" << dendl;
queue_peering_event(