]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: do not try to diagnose cause of MDSMap removal
authorPatrick Donnelly <pdonnell@redhat.com>
Wed, 6 Nov 2019 08:26:51 +0000 (00:26 -0800)
committerVenky Shankar <vshankar@redhat.com>
Thu, 26 Mar 2020 02:45:13 +0000 (22:45 -0400)
The Monitors send an empty MDSMap to an MDS it is removing. The MDS
can't diagnose the cause. Instead suggest looking at the cluster/monitor
logs.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit c385178b0c04d09bc6774acf5bdb4537fa6803ad)

src/mds/MDSDaemon.cc

index 03e7b51c7fee028b20f4a5660c3d30733fe372bd..276d23268707b5dec05c62b0ced5328b4e654e4f 100644 (file)
@@ -827,25 +827,8 @@ void MDSDaemon::handle_mds_map(const MMDSMap::const_ref &m)
   using DS = MDSMap::DaemonState;
   if (old_state != DS::STATE_NULL && new_state == DS::STATE_NULL) {
     const auto& oldinfo = oldmap->get_info_gid(mygid);
-    const auto existing = mdsmap->find_mds_gid_by_name(name);
-    if (g_conf()->mds_enforce_unique_name && existing != MDS_GID_NONE) {
-      const auto& info = mdsmap->get_info_gid(existing);
-      dout(1) << "Map replaced me " << oldinfo
-              << " with another MDS of the same name: " << info
-              << "; quitting!" << dendl;
-
-      /* Monitors should never go backwards! */
-      ceph_assert(info.global_id > myid);
-
-      // Call suicide() rather than respawn() because if someone else has
-      // taken our ID, we don't want to keep restarting and fighting them for
-      // the ID.
-      suicide();
-      return;
-    }
-
     dout(1) << "Map removed me " << oldinfo
-            << " from cluster due to lost contact; respawning" << dendl;
+            << " from cluster; respawning! See cluster/monitor logs for details." << dendl;
     respawn();
   }