Skip to content

Commit

Permalink
mon/OSDMonitor: don't create pgs if pool was deleted
Browse files Browse the repository at this point in the history
A pool may be deleted while in the process of creating pgs. If that
happens, we should not queue additional pgs from that pool to be
created.

Fixes: http://tracker.ceph.com/issues/21309

Signed-off-by: Joao Eduardo Luis <[email protected]>
  • Loading branch information
jecluis committed Sep 8, 2017
1 parent bc5fe2e commit 7a8a880
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/mon/CreatingPGs.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ struct creating_pgs_t {
auto last = pgs.lower_bound(pg_t{0, (uint64_t)removed_pool + 1});
pgs.erase(first, last);
created_pools.erase(removed_pool);
queue.erase(removed_pool);
return total - pgs.size();
}
void encode(bufferlist& bl) const {
Expand Down

0 comments on commit 7a8a880

Please sign in to comment.