]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: do not path traverse a damaged dirfrag 61555/head
authorPatrick Donnelly <pdonnell@ibm.com>
Tue, 28 Jan 2025 18:06:36 +0000 (13:06 -0500)
committerPatrick Donnelly <pdonnell@ibm.com>
Tue, 28 Jan 2025 18:06:36 +0000 (13:06 -0500)
Fixes: https://tracker.ceph.com/issues/69695
Signed-off-by: Patrick Donnelly <pdonnell@ibm.com>
src/mds/MDCache.cc

index 04e1fd7111952eb39020368d53f2b6e5721222f1..e23412734173ec934300899f807b2451057fc9f2 100644 (file)
@@ -8452,6 +8452,13 @@ int MDCache::path_traverse(const MDRequestRef& mdr, MDSContextFactory& cf,
       }
     }
     ceph_assert(curdir);
+
+    if (mds->damage_table.is_dirfrag_damaged(curdir)) {
+      dout(4) << "traverse: stopped lookup at dirfrag "
+              << *curdir << "/" << path[depth] << " snap=" << snapid << dendl;
+      return -CEPHFS_EIO;
+    }
+
     if (pdir) {
       *pdir = curdir;
     }