From: xie xingguo Date: Wed, 21 Aug 2019 02:33:42 +0000 (+0800) Subject: osd/PGLog: trigger full recovery for divergent missing objects X-Git-Tag: v15.1.0~1780^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=bea761df995759c264b1dc94cabb6dbe6769fbc2;p=ceph-ci.git osd/PGLog: trigger full recovery for divergent missing objects They might have a dirty/invalid log history (and hence an invalid clean_regions as well), and there is no easy way to deduce the complete clean_regions portion. For simplicity (and correctness), disable potential incremental recovery mode for these objects. Signed-off-by: xie xingguo --- diff --git a/src/osd/PGLog.h b/src/osd/PGLog.h index 2beb72de527..ae4c578b1b3 100644 --- a/src/osd/PGLog.h +++ b/src/osd/PGLog.h @@ -990,6 +990,7 @@ protected: ceph_assert(!missing.is_missing(hoid)); } missing.revise_have(hoid, eversion_t()); + missing.mark_fully_dirty(hoid); if (rollbacker) { if (!object_not_in_store) { rollbacker->remove(hoid); diff --git a/src/osd/osd_types.h b/src/osd/osd_types.h index 3e5e71ccdfa..ac981625bda 100644 --- a/src/osd/osd_types.h +++ b/src/osd/osd_types.h @@ -4514,6 +4514,14 @@ public: } } + void mark_fully_dirty(const hobject_t& oid) { + auto p = missing.find(oid); + if (p != missing.end()) { + tracker.changed(oid); + (p->second).clean_regions.mark_fully_dirty(); + } + } + void add(const hobject_t& oid, eversion_t need, eversion_t have, bool is_delete, bool make_dirty = true) { //if have== eversion_t() means that the object does not exist, we transfer new_object = true