Uploaded image for project: 'Ambari (Retired)'
  1. Ambari (Retired)
  2. AMBARI-15506

Support for multiple Namservices in namenode_ha_utils.py

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • trunk
    • 2.4.0
    • ambari-agent
    • None
    • HDFS HA

    Description

      Currently Ambari does not support the definition of multiple Nameservices. It is always assumed hdfs_site['dfs.nameservices'] is just a string defining one nameservice.

      Multiple nameservices can be configured for exmaple to support seamless distcp between two HA clusters. The nameservices are defined as a comma separated list in hdfs_site['dfs.nameservices'].

      This patch introduces the method get_nameservice(hdfs_site), which splits the value into in an array and identifies the nameservice for the current cluster with what is set in hdfs_site['dfs.namenode.shared.edits.dir']. By default the first nameservice is returned or empty.

      To verify the current namservice it would be preferred to use fs.defaultFS in core-site, but getting this config into namenode_ha_utils.py seems more involved.

      Attachments

        1. AMBARI-15506
          3 kB
          Henning Kropp
        2. AMBARI-15506_1
          3 kB
          Henning Kropp
        3. AMBARI-15506_2
          3 kB
          Henning Kropp
        4. AMBARI-15506_3
          3 kB
          Henning Kropp
        5. AMBARI-15506_5
          3 kB
          Henning Kropp
        6. AMBARI-15506_regex
          3 kB
          Henning Kropp
        7. AMBARI-15506_regex_unit_tests-trunk_1.patch
          6 kB
          Dmytro Sen
        8. namenode_ha_utils.py
          8 kB
          Henning Kropp

        Issue Links

          Activity

            People

              hkropp Henning Kropp
              hkropp Henning Kropp
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: