From: myoungwon oh Date: Mon, 22 Feb 2021 03:35:46 +0000 (+0900) Subject: osd: clear chunk_map if the object is whiteouted X-Git-Tag: v17.1.0~2307^2~21 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=a6767d0991a90e7b989136fa1ad848846d4874d8;p=ceph.git osd: clear chunk_map if the object is whiteouted Signed-off-by: Myoungwon Oh --- diff --git a/src/osd/PrimaryLogPG.cc b/src/osd/PrimaryLogPG.cc index 7ab35bc0e17a4..a76895abd397f 100644 --- a/src/osd/PrimaryLogPG.cc +++ b/src/osd/PrimaryLogPG.cc @@ -8136,6 +8136,14 @@ inline int PrimaryLogPG::_delete_oid( oi.set_flag(object_info_t::FLAG_WHITEOUT); ctx->delta_stats.num_whiteouts++; t->create(soid); + if (oi.has_manifest()) { + // make no references + dec_all_refcount_manifest(oi, ctx); + oi.manifest.clear(); + oi.manifest.type = object_manifest_t::TYPE_NONE; + oi.clear_flag(object_info_t::FLAG_MANIFEST); + ctx->delta_stats.num_objects_manifest--; + } osd->logger->inc(l_osd_tier_whiteout); return 0; }