Skip to content

Commit

Permalink
PGMonitor: acting primary diff with cur_stat, should not set pg to st…
Browse files Browse the repository at this point in the history
…ale.

Signed-off-by: Xiaowei Chen <chen.xiaowei@h3c.com>
  • Loading branch information
shawn committed Jan 5, 2016
1 parent 4dd0d1b commit beb99d7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/mon/PGMonitor.cc
Expand Up @@ -1275,8 +1275,10 @@ void PGMonitor::_mark_pg_stale(pg_t pgid, const pg_stat_t& cur_stat)
} else {
stat = &q->second;
}
stat->state |= PG_STATE_STALE;
stat->last_unstale = ceph_clock_now(g_ceph_context);
if (stat->acting_primary == cur_stat.acting_primary) {
stat->state |= PG_STATE_STALE;
stat->last_unstale = ceph_clock_now(g_ceph_context);
}
}

bool PGMonitor::check_down_pgs()
Expand Down

0 comments on commit beb99d7

Please sign in to comment.