hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-6643) TestRMFailover fails rarely due to port conflict
Date Thu, 25 May 2017 22:42:04 GMT

    [ https://issues.apache.org/jira/browse/YARN-6643?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16025501#comment-16025501
] 

Hudson commented on YARN-6643:
------------------------------

SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #11784 (See [https://builds.apache.org/job/Hadoop-trunk-Commit/11784/])
YARN-6643. TestRMFailover fails rarely due to port conflict. Contributed (jlowe: rev 3fd6a2da4e537423d1462238e10cc9e1f698d1c2)
* (edit) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/HATestUtil.java


> TestRMFailover fails rarely due to port conflict
> ------------------------------------------------
>
>                 Key: YARN-6643
>                 URL: https://issues.apache.org/jira/browse/YARN-6643
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 2.9.0, 3.0.0-alpha3
>            Reporter: Robert Kanter
>            Assignee: Robert Kanter
>             Fix For: 2.9.0, 3.0.0-alpha3, 2.8.2
>
>         Attachments: YARN-6643.001.patch
>
>
> We've seen various tests in {{TestRMFailover}} fail very rarely with a message like "org.apache.hadoop.yarn.exceptions.YarnRuntimeException:
java.io.IOException: ResourceManager failed to start. Final state is STOPPED".  
> After some digging, it turns out that it's due to a port conflict with the embedded ZooKeeper
in the tests.  The embedded ZooKeeper uses {{ServerSocketUtil#getPort}} to choose a free port,
but the RMs are configured to 10000 + <default-port> and 20000 + <default-port>
(e.g. the default port for the RM is 8032, so you'd use 18032 and 28032).
> When I was able to reproduce this, I saw that ZooKeeper was using port 18033, which is
10000 + 8033, the default RM Admin port.  It results in an error like this, causing the RM
to be unable to start, and hence the original error message in the test failure:
> {noformat}
> 2017-05-24 01:16:52,735 INFO  service.AbstractService (AbstractService.java:noteFailure(272))
- Service ResourceManager failed in state STARTED; cause: org.apache.hadoop.yarn.exceptions.YarnRuntimeException:
java.net.BindException: Problem binding to [0.0.0.0:18033] java.net.BindException: Address
already in use; For more details see:  http://wiki.apache.org/hadoop/BindException
> org.apache.hadoop.yarn.exceptions.YarnRuntimeException: java.net.BindException: Problem
binding to [0.0.0.0:18033] java.net.BindException: Address already in use; For more details
see:  http://wiki.apache.org/hadoop/BindException
>         at org.apache.hadoop.yarn.factories.impl.pb.RpcServerFactoryPBImpl.getServer(RpcServerFactoryPBImpl.java:139)
>         at org.apache.hadoop.yarn.ipc.HadoopYarnProtoRPC.getServer(HadoopYarnProtoRPC.java:65)
>         at org.apache.hadoop.yarn.ipc.YarnRPC.getServer(YarnRPC.java:54)
>         at org.apache.hadoop.yarn.server.resourcemanager.AdminService.startServer(AdminService.java:171)
>         at org.apache.hadoop.yarn.server.resourcemanager.AdminService.serviceStart(AdminService.java:158)
>         at org.apache.hadoop.service.AbstractService.start(AbstractService.java:193)
>         at org.apache.hadoop.service.CompositeService.serviceStart(CompositeService.java:120)
>         at org.apache.hadoop.yarn.server.resourcemanager.ResourceManager.serviceStart(ResourceManager.java:1147)
>         at org.apache.hadoop.service.AbstractService.start(AbstractService.java:193)
>         at org.apache.hadoop.yarn.server.MiniYARNCluster$2.run(MiniYARNCluster.java:310)
> Caused by: java.net.BindException: Problem binding to [0.0.0.0:18033] java.net.BindException:
Address already in use; For more details see:  http://wiki.apache.org/hadoop/BindException
>         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
>         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>         at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
>         at org.apache.hadoop.net.NetUtils.wrapWithMessage(NetUtils.java:791)
>         at org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:720)
>         at org.apache.hadoop.ipc.Server.bind(Server.java:482)
>         at org.apache.hadoop.ipc.Server$Listener.<init>(Server.java:688)
>         at org.apache.hadoop.ipc.Server.<init>(Server.java:2376)
>         at org.apache.hadoop.ipc.RPC$Server.<init>(RPC.java:1042)
>         at org.apache.hadoop.ipc.ProtobufRpcEngine$Server.<init>(ProtobufRpcEngine.java:535)
>         at org.apache.hadoop.ipc.ProtobufRpcEngine.getServer(ProtobufRpcEngine.java:510)
>         at org.apache.hadoop.ipc.RPC$Builder.build(RPC.java:887)
>         at org.apache.hadoop.yarn.factories.impl.pb.RpcServerFactoryPBImpl.createServer(RpcServerFactoryPBImpl.java:169)
>         at org.apache.hadoop.yarn.factories.impl.pb.RpcServerFactoryPBImpl.getServer(RpcServerFactoryPBImpl.java:132)
>         ... 9 more
> Caused by: java.net.BindException: Address already in use
>         at sun.nio.ch.Net.bind0(Native Method)
>         at sun.nio.ch.Net.bind(Net.java:444)
>         at sun.nio.ch.Net.bind(Net.java:436)
>         at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:214)
>         at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
>         at org.apache.hadoop.ipc.Server.bind(Server.java:465)
>         ... 17 more
> 2017-05-24 01:16:52,736 DEBUG service.AbstractService (AbstractService.java:enterState(452))
- Service: ResourceManager entered state STOPPED
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org


Mime
View raw message