Bug #11493

Updated by Sage Weil about 6 years ago

1. images had snapshots (and removed_snaps)

2. images was added as a tier *of* img, and img's removed_snaps was copied
to images, clobbering the removed_snaps value (see

3. tiering relation was undone, but removed_snaps was still gone

4. on OSD startup, when we load the PG, removed_snaps is initialized with
the older map. later, in PGPool::update(), we assume that removed_snaps
alwasy grows (never shrinks) and we trigger an assert.

To fix this I think we need to do 2 things:

1. make the OSD forgiving out removed_snaps getting smaller. This is
probably a good thing anyway: once we know snaps are removed on all OSDs
we can prune the interval_set in the OSDMap. Maybe.

2. Fix the mon to prevent this from happening, *even* when
--force-nonempty is specified. (This is the root cause.)