You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by GitBox <gi...@apache.org> on 2019/06/26 17:30:34 UTC
[GitHub] [hadoop] HappyRay opened a new pull request #1020: YARN-9646 Use
localhost when testing with the mini yarn cluster
HappyRay opened a new pull request #1020: YARN-9646 Use localhost when testing with the mini yarn cluster
URL: https://github.com/apache/hadoop/pull/1020
When testing
org.apache.hadoop.yarn.applications.distributedshell.TestDistributedShell#testDSShellWithoutDomain
at home
The following error happened:
org.apache.hadoop.yarn.exceptions.YarnRuntimeException: org.apache.hadoop.yarn.exceptions.YarnRuntimeException: java.net.BindException: Problem binding to [ruyang-mn3.linkedin.biz:0] java.net.BindException: Can't assign requested address; For more details see: http://wiki.apache.org/hadoop/BindException
at org.apache.hadoop.yarn.server.MiniYARNCluster.startResourceManager(MiniYARNCluster.java:327)
...
Caused by: java.net.BindException: Can't assign requested address
at sun.nio.ch.Net.bind0(Native Method)
It's because the test uses
InetAddress.getLocalHost().getHostName();
to get the host name and tries to bind to it.
The machine is issued at work. At home, the FQDN of the hostname is either not resolvable or the cached ip address is not reachable. Even on VPN, somehow the same error happened from time to time. The exact cause of that behavior on VPN is unknown yet.
It makes WFH more difficult.
The test will be simpler and more reliable if it simply uses "localhost".
===
The comment in
org.apache.hadoop.yarn.applications.distributedshell.TestDistributedShell#checkHostname
* NetUtils.getHostname() returns a string in the form "hostname/ip".
* Sometimes the hostname we get is the FQDN and sometimes the short name. In
* addition, on machines with multiple network interfaces, it runs any one of
* the ips.
suggests some complexities involved with this method of calling InetAddress.getLocalHost()
===
This test specifically checks for hostname patterns. Not sure why.
This change will remove the check, which simplifies the test quite a bit.
Testing:
The failed test succeeds and all the distributed shell tests and mini cluster tests succeed
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org