From a2a0251a63d036c600d67754d1be6ff483c106a5 Mon Sep 17 00:00:00 2001 From: myoungwon oh Date: Wed, 3 Mar 2021 23:29:55 +0900 Subject: [PATCH] osd: add manifest info when duplicating head upon manifest object Signed-off-by: Myoungwon Oh --- src/osd/PrimaryLogPG.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/osd/PrimaryLogPG.cc b/src/osd/PrimaryLogPG.cc index 0d3dc384166..68e00ead2b4 100644 --- a/src/osd/PrimaryLogPG.cc +++ b/src/osd/PrimaryLogPG.cc @@ -8329,6 +8329,12 @@ int PrimaryLogPG::_rollback_to(OpContext *ctx, ceph_osd_op& op) else obs.oi.clear_omap_digest(); + if (rollback_to->obs.oi.has_manifest() && rollback_to->obs.oi.manifest.is_chunked()) { + obs.oi.set_flag(object_info_t::FLAG_MANIFEST); + obs.oi.manifest.type = rollback_to->obs.oi.manifest.type; + obs.oi.manifest.chunk_map = rollback_to->obs.oi.manifest.chunk_map; + } + if (rollback_to->obs.oi.is_omap()) { dout(10) << __func__ << " setting omap flag on " << obs.oi.soid << dendl; obs.oi.set_flag(object_info_t::FLAG_OMAP); -- 2.39.5