You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Zhu Zhu (Jira)" <ji...@apache.org> on 2019/12/26 02:23:00 UTC

[jira] [Commented] (FLINK-15394) in yarn mode, jobmanager fails to start in case of rest.port conflict.

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

Zhu Zhu commented on FLINK-15394:
---------------------------------

Hi [~watters_fish], I think it is not a bug. If a user has configured the port for the jobmanager and the jobmanager fails to take that port, it is expected to fail the job rather than let it take another port.
You can specify a port range with config "rest.bind-port" so that jobmanagers on the same machine would not conflict for a single configured rest port.

> in yarn mode, jobmanager fails to start in case of rest.port conflict.
> ----------------------------------------------------------------------
>
>                 Key: FLINK-15394
>                 URL: https://issues.apache.org/jira/browse/FLINK-15394
>             Project: Flink
>          Issue Type: Bug
>          Components: Runtime / REST
>    Affects Versions: 1.9.0
>         Environment: a small yarn cluster with three node.
>            Reporter: watters.wang
>            Priority: Major
>
> In flink 1.9, if rest.port is set in flink.yaml,  jobmanager will start failed in case of rest.port conflict in small cluster. 
> in 1.7, that's ok .
>  
> {code:java}
> //代码占位符
> org.apache.flink.runtime.entrypoint.ClusterEntrypointException: Failed to initialize the cluster entrypoint YarnJobClusterEntrypoint.
> 	at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:182)
> 	at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.runClusterEntrypoint(ClusterEntrypoint.java:501)
> 	at org.apache.flink.yarn.entrypoint.YarnJobClusterEntrypoint.main(YarnJobClusterEntrypoint.java:102)
> Caused by: org.apache.flink.util.FlinkException: Could not create the DispatcherResourceManagerComponent.
> 	at org.apache.flink.runtime.entrypoint.component.AbstractDispatcherResourceManagerComponentFactory.create(AbstractDispatcherResourceManagerComponentFactory.java:257)
> 	at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.runCluster(ClusterEntrypoint.java:210)
> 	at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.lambda$startCluster$0(ClusterEntrypoint.java:164)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at javax.security.auth.Subject.doAs(Subject.java:422)
> 	at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1754)
> 	at org.apache.flink.runtime.security.HadoopSecurityContext.runSecured(HadoopSecurityContext.java:41)
> 	at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:163)
> 	... 2 more
> Caused by: java.net.BindException: Could not start rest endpoint on any port in port range 8081
> 	at org.apache.flink.runtime.rest.RestServerEndpoint.start(RestServerEndpoint.java:219)
> 	at org.apache.flink.runtime.entrypoint.component.AbstractDispatcherResourceManagerComponentFactory.create(AbstractDispatcherResourceManagerComponentFactory.java:161)
> 	... 9 more
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)