Skip to content

Commit

Permalink
PG::build_might_have_unfound: check pg_whomai, not osd whoami
Browse files Browse the repository at this point in the history
Otherwise, we might skip (2,0) when we are (2,1).

Fixes: ceph#7732
Signed-off-by: Samuel Just <[email protected]>
  • Loading branch information
Samuel Just committed Mar 15, 2014
1 parent 35f1b04 commit 979e8b4
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/osd/PG.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1360,11 +1360,9 @@ void PG::build_might_have_unfound()
std::vector<int>::const_iterator a = interval.acting.begin();
std::vector<int>::const_iterator a_end = interval.acting.end();
for (; a != a_end; ++a, ++i) {
if (*a != CRUSH_ITEM_NONE && *a != osd->whoami)
might_have_unfound.insert(
pg_shard_t(
*a,
pool.info.ec_pool() ? i : ghobject_t::NO_SHARD));
pg_shard_t shard(*a, pool.info.ec_pool() ? i : ghobject_t::NO_SHARD);
if (*a != CRUSH_ITEM_NONE && shard != pg_whoami)
might_have_unfound.insert(shard);
}
}

Expand Down

0 comments on commit 979e8b4

Please sign in to comment.