Details

    • Type: Sub-task
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.10.0, 3.2.0, 3.1.1, 2.9.2, 3.0.4
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      To reproduce the issue: 

      $ bin/hdfs dfsrouteradmin -safemode enter
      Successfully enter safe mode.
      $ bin/hdfs dfsrouteradmin -safemode get
      Safe Mode: true

      And then, 

      $ bin/hdfs dfsrouteradmin -safemode get
      Safe Mode: false

      From the code, it looks like the periodicInvoke triggers the leave.

      public void periodicInvoke() {
      ......
        // Always update to indicate our cache was updated
        if (isCacheStale) {
          if (!rpcServer.isInSafeMode()) {
            enter();
          }
        } else if (rpcServer.isInSafeMode()) {
          // Cache recently updated, leave safe mode
          leave();
        }
      }
      

       

       

        Attachments

        1. HDFS-13475.003.patch
          18 kB
          Chao Sun
        2. HDFS-13475.002.patch
          16 kB
          Chao Sun
        3. HDFS-13475.001.patch
          16 kB
          Chao Sun
        4. HDFS-13475.000.patch
          8 kB
          Chao Sun

          Issue Links

            Activity

              People

              • Assignee:
                csun Chao Sun
                Reporter:
                ywskycn Wei Yan
              • Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: