After cluster creation, we have no full map stored and first_committed ==
1. In that case, there is no need for a full map, since we can get there
from OSDMap() and the incrementals.
Backport: cuttlefish
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Joao Eduardo Luis <joao@inktank.com>
(cherry picked from commit
e807770784175b05130bba938113fdbf874f152e)
if (latest_full == 0 && get_first_committed() > 1)
latest_full = get_first_committed();
- if (latest_full < get_first_committed()) {
+ if (get_first_committed() > 1 &&
+ latest_full < get_first_committed()) {
/* a bug introduced in 7fb3804fb860dcd0340dd3f7c39eec4315f8e4b6 would lead
* us to not update the on-disk latest_full key. Upon trim, the actual
* version would cease to exist but we would still point to it. This