Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-8277

Safemode enter fails when Standby NameNode is down

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • 2.6.0
    • None
    • ha, namenode
    • None
    • HDP 2.2.0

    Description

      HDFS fails to enter safemode when the Standby NameNode is down (eg. due to AMBARI-10536).

      hdfs dfsadmin -safemode enter
      safemode: Call From nn2/x.x.x.x to nn1:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused

      This appears to be a bug in that it's not trying both NameNodes like the standard hdfs client code does, and is instead stopping after getting a connection refused from nn1 which is down. I verified normal hadoop fs writes and reads via cli did work at this time, using nn2. I happened to run this command as the hdfs user on nn2 which was the surviving Active NameNode.

      After I re-bootstrapped the Standby NN to fix it the command worked as expected again.

      Attachments

        1. HDFS-8277-safemode-edits.patch
          15 kB
          Surendra Singh Lilhore
        2. HDFS-8277.patch
          1 kB
          Surendra Singh Lilhore
        3. HDFS-8277_5.patch
          6 kB
          Jianfei Jiang
        4. HDFS-8277_4.patch
          2 kB
          Surendra Singh Lilhore
        5. HDFS-8277_3.patch
          2 kB
          Surendra Singh Lilhore
        6. HDFS-8277_2.patch
          3 kB
          Surendra Singh Lilhore
        7. HDFS-8277_1.patch
          1 kB
          Surendra Singh Lilhore

        Issue Links

          Activity

            People

              jiangjianfei Jianfei Jiang
              harisekhon Hari Sekhon
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated: