]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon/MDSMonitor: return zero when mds is absent for "mds fail" 37159/head
authorRishabh Dave <ridave@redhat.com>
Tue, 15 Sep 2020 19:40:31 +0000 (01:10 +0530)
committerRishabh Dave <ridave@redhat.com>
Wed, 16 Sep 2020 12:58:36 +0000 (18:28 +0530)
... instead of EINVAL.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
src/mon/MDSMonitor.cc

index 391c5c7c47bc0b068f7500f3c22b06401d5fbbbc..f00460e684aaa3b8cff42ba341bcf136af4c3703 100644 (file)
@@ -1456,7 +1456,9 @@ int MDSMonitor::filesystem_command(
     MDSMap::mds_info_t failed_info;
     mds_gid_t gid = gid_from_arg(fsmap, who, ss);
     if (gid == MDS_GID_NONE) {
-      return -EINVAL;
+      ss << "MDS named '" << who << "' does not exist, is not up or you "
+        << "lack the permission to see.";
+      return 0;
     }
     if(!fsmap.gid_exists(gid, op->get_session()->get_allowed_fs_names())) {
       ss << "MDS named '" << who << "' does not exist, is not up or you "