]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: add debugging when rejecting mksnap with EPERM 42199/head
authorPatrick Donnelly <pdonnell@redhat.com>
Tue, 6 Jul 2021 18:03:19 +0000 (11:03 -0700)
committerPatrick Donnelly <pdonnell@redhat.com>
Wed, 7 Jul 2021 13:42:25 +0000 (06:42 -0700)
Fixes: https://tracker.ceph.com/issues/51543
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
src/mds/Server.cc

index cc91705f87908a12412ac99080b345499c4137c0..89131f696545bd3735c575f0778b49c1c5757807 100644 (file)
@@ -10256,6 +10256,7 @@ void Server::handle_client_mksnap(MDRequestRef& mdr)
   }
   if (!mds->mdsmap->allows_snaps()) {
     // you can't make snapshots until you set an option right now
+    dout(5) << "new snapshots are disabled for this fs" << dendl;
     respond_to_request(mdr, -CEPHFS_EPERM);
     return;
   }
@@ -10271,6 +10272,7 @@ void Server::handle_client_mksnap(MDRequestRef& mdr)
   }
   if (diri->is_system() && !diri->is_root()) {
     // no snaps in system dirs (root is ok)
+    dout(5) << "is an internal system dir" << dendl;
     respond_to_request(mdr, -CEPHFS_EPERM);
     return;
   }
@@ -10304,6 +10306,7 @@ void Server::handle_client_mksnap(MDRequestRef& mdr)
 
   if (inodeno_t subvol_ino = diri->find_snaprealm()->get_subvolume_ino();
       (subvol_ino && subvol_ino != diri->ino())) {
+    dout(5) << "is a descendent of a subvolume dir" << dendl;
     respond_to_request(mdr, -CEPHFS_EPERM);
     return;
   }