lnbest0707 opened a new pull request, #5279:
URL: https://github.com/apache/hadoop/pull/5279
<!--
Thanks for sending a pull request!
1. If this is your first time, please read our contributor guidelines:
https://cwiki.apache.org/confluence/display/HADOOP/How+To+Contribute
2. Make sure your PR title starts with JIRA issue id, e.g.,
'HADOOP-17799. Your PR title ...'.
-->
### Description of PR
The patch reuses the resolver introduced from the HDFS side and apply
similar logic to YARN RM service addresses resolving.
To utilize the YARN DNS support and use DNS as endpoint, simply upgrade the
hadoop binary and revise configs from, for example:
```
<property>
<name>yarn.resourcemanager.address.rm1</name>
<value>rm1_address:8032</value>
</property>
<property>
<name>yarn.resourcemanager.scheduler.address.rm1</name>
<value>rm1_address:8030</value>
</property>
<property>
<name>yarn.resourcemanager.resource-tracker.address.rm1</name>
<value>rm1_address:8031</value>
</property>
<property>
<name>yarn.resourcemanager.admin.address.rm1</name>
<value>rm1_address:8033</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.address.rm1</name>
<value>rm1_address:8088</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.https.address.rm1</name>
<value>rm1_address:8090</value>
</property>
<property>
<name>yarn.resourcemanager.address.rm2</name>
<value>rm2_address:8032</value>
</property>
<property>
<name>yarn.resourcemanager.scheduler.address.rm2</name>
<value>rm2_address:8030</value>
</property>
<property>
<name>yarn.resourcemanager.resource-tracker.address.rm2</name>
<value>rm2_address:8031</value>
</property>
<property>
<name>yarn.resourcemanager.admin.address.rm2</name>
<value>rm2_address:8033</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.address.rm2</name>
<value>rm2_address:8088</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.https.address.rm2</name>
<value>rm2_address:8090</value>
</property>
<property>
<name>yarn.resourcemanager.ha.rm-ids</name>
<value>rm1,rm2</value>
</property>
```
to:
```
<property>
<name>yarn.resourcemanager.address.rm1</name>
<value>rm_multi_a_dns:8032</value>
</property>
<property>
<name>yarn.resourcemanager.scheduler.address.rm1</name>
<value>rm_multi_a_dns:8030</value>
</property>
<property>
<name>yarn.resourcemanager.resource-tracker.address.rm1</name>
<value>rm_multi_a_dns:8031</value>
</property>
<property>
<name>yarn.resourcemanager.admin.address.rm1</name>
<value>rm_multi_a_dns:8033</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.address.rm1</name>
<value>rm_multi_a_dns:8088</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.https.address.rm1</name>
<value>rm_multi_a_dns:8090</value>
</property>
<property>
<name>yarn.resourcemanager.ha.rm-ids</name>
<value>rm1</value>
</property>
<property>
<name>yarn.resourcemanager.ha.resolve-needed</name>
<value>true</value>
</property>
<property>
<name>yarn.resourcemanager.ha.resolver.useFQDN</name>
<value>true</value> # required in secure mode
</property>
<property>
<name>yarn.resourcemanager.ha.refresh-period-ms</name>
<value>180000</value> # 3 min
</property>
```
where rm_multi_a_dns is a multi-A DNS record for rm1_address and
rm2_address. This means the following output on the terminal.
$ dig +short <rm_multi_a_dns> | xargs -n +1 dig +short -x | sort
<rm1_address>
<rm2_address>
For the newly introduced flags, please refer to yarn-default.xml.
### How was this patch tested?
### For code changes:
- [ ] Does the title or this PR starts with the corresponding JIRA issue id
(e.g. 'HADOOP-17799. Your PR title ...')?
- [ ] Object storage: have the integration tests been executed and the
endpoint declared according to the connector-specific documentation?
- [ ] If adding new dependencies to the code, are these dependencies
licensed in a way that is compatible for inclusion under [ASF
2.0](http://www.apache.org/legal/resolved.html#category-a)?
- [ ] If applicable, have you updated the `LICENSE`, `LICENSE-binary`,
`NOTICE-binary` files?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]