From: Milind Changire Date: Mon, 25 Sep 2023 12:49:50 +0000 (+0530) Subject: mds: do not simplify fragset X-Git-Tag: v18.2.4~303^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=b388fbd46f47f41012e0bbb72494d25ae691ec1e;p=ceph.git mds: do not simplify fragset Problem: Frags in simplified fragset aren't found as is on the replica during scrub. fragset::simplify() computes the bit representation of the least common ancestor of the frags. When this representation is forwarded to the replicas, the ScrubStack::handle_scrub() method in the OP_QUEUEDIR case simply searches this simplified representation in the list of (unsimplified) frags ... which it fails to find. Hence we get to see the "no frag 10*" type of logs. Solution: Do not simplify fragset when forwarding fragset to replica for scrub. Fixes: https://tracker.ceph.com/issues/62658 Signed-off-by: Milind Changire (cherry picked from commit f3c0424bb583423db80009c29f73e484aad840b4) --- diff --git a/src/mds/ScrubStack.cc b/src/mds/ScrubStack.cc index 6d799343f1496..742c464f4d37a 100644 --- a/src/mds/ScrubStack.cc +++ b/src/mds/ScrubStack.cc @@ -320,7 +320,7 @@ void ScrubStack::scrub_dir_inode(CInode *in, bool *added_children, bool *done) frag_vec_t frags; in->dirfragtree.get_leaves(frags); - dout(20) << __func__ << "recursive mode, frags " << frags << dendl; + dout(20) << __func__ << " recursive mode, frags " << frags << dendl; for (auto &fg : frags) { if (queued.contains(fg)) continue; @@ -366,7 +366,6 @@ void ScrubStack::scrub_dir_inode(CInode *in, bool *added_children, bool *done) scrub_r.tag = header->get_tag(); for (auto& p : scrub_remote) { - p.second.simplify(); dout(20) << __func__ << " forward " << p.second << " to mds." << p.first << dendl; auto r = make_message(MMDSScrub::OP_QUEUEDIR, in->ino(), std::move(p.second), header->get_tag(),