Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-13427

NAMENODE START failed with both NN's being passive

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.1.2
    • 2.2.0
    • ambari-server
    • None

    Description

      This is an inconsistent repro. Sometimes, Namenode start fails to start because both Namenode states come back as non-active.

      Fix:
      Adding retry logic with some logging.

      Traceback (most recent call last):
        File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/scripts/namenode.py", line 317, in <module>
          NameNode().execute()
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 219, in execute
          method(env)
        File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/scripts/namenode.py", line 82, in start
          namenode(action="start", rolling_restart=rolling_restart, env=env)
        File "/usr/lib/python2.6/site-packages/ambari_commons/os_family_impl.py", line 89, in thunk
          return fn(*args, **kwargs)
        File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py", line 142, in namenode
          create_hdfs_directories(is_active_namenode_cmd)
        File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py", line 199, in create_hdfs_directories
          only_if=check
        File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 154, in __init__
          self.env.run()
        File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 152, in run
          self.run_action(resource, action)
        File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 118, in run_action
          provider_action()
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/providers/hdfs_resource.py", line 394, in action_create_on_execute
          self.action_delayed("create")
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/providers/hdfs_resource.py", line 391, in action_delayed
          self.get_hdfs_resource_executor().action_delayed(action_name, self)
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/providers/hdfs_resource.py", line 240, in action_delayed
          main_resource.resource.security_enabled, main_resource.resource.logoutput)
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/providers/hdfs_resource.py", line 127, in __init__
          security_enabled, run_user)
        File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/namenode_ha_utils.py", line 124, in get_property_for_active_namenode
          raise Fail("There is no active namenodes.")
      resource_management.core.exceptions.Fail: There is no active namenodes.
      

      Attachments

        1. AMBARI-13427.patch
          3 kB
          Jayush Luniya

        Issue Links

          Activity

            People

              jluniya Jayush Luniya
              jluniya Jayush Luniya
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: