Hadoop High Availability
Also available as:
PDF
loading table of contents...

Testing ResourceManager HA on a Single Node

If you would like to test ResourceManager HA on a single node (launch more than one ResourceManager on a single node), you need to add the following settings in yarn-site.xml.

To enable ResourceManager "rm1" to launch:

<property>
 <name>yarn.resourcemanager.ha.id</name>
 <value>rm1</value>
 <description>If we want to launch more than one RM in single node, we need this configuration</description>
</property>

To enable ResourceManager rm2 to launch:

<property>
 <name>yarn.resourcemanager.ha.id</name>
 <value>rm2</value>
 <description>If we want to launch more than one RM in single node, we need this configuration</description>
</property>

You should also explicitly set values specific to each ResourceManager for the following properties separately in yarn-site.xml:

  • yarn.resourcemanager.address.<rm-id>

  • yarn.resourcemanager.scheduler.address.<rm-id>

  • yarn.resourcemanager.admin.address.<rm-id>

  • yarn.resourcemanager.resource#tracker.address.<rm-id>

  • yarn.resourcemanager.webapp.address.<rm-id>

For example:

<!-- RM1 Configs -->

<property>
 <name>yarn.resourcemanager.address.rm1</name>
 <value>localhost:23140</value>
</property>

<property>
 <name>yarn.resourcemanager.scheduler.address.rm1</name>
 <value>localhost:23130</value>
</property>

<property>
 <name>yarn.resourcemanager.webapp.address.rm1</name>
 <value>localhost:23188</value>
</property>

<property>
 <name>yarn.resourcemanager.resource-tracker.address.rm1</name>
 <value>localhost:23125</value>
</property>

<property>
 <name>yarn.resourcemanager.admin.address.rm1</name>
 <value>localhost:23141</value>
</property>

<!-- RM2 configs -->
<property>
 <name>yarn.resourcemanager.address.rm2</name>
 <value>localhost:33140</value>
</property>

<property>
 <name>yarn.resourcemanager.scheduler.address.rm2</name>
 <value>localhost:33130</value>
</property>

<property>
 <name>yarn.resourcemanager.webapp.address.rm2</name>
 <value>localhost:33188</value>
</property>

<property>
 <name>yarn.resourcemanager.resource-tracker.address.rm2</name>
 <value>localhost:33125</value>
</property>

<property>
 <name>yarn.resourcemanager.admin.address.rm2</name>
 <value>localhost:33141</value>
</property>