Hi 大家好:

在使用flink过程中,运行官网给的命令
https://ci.apache.org/projects/flink/flink-docs-stable/ops/deployment/yarn_setup.html#run-a-single-flink-job-on-yarn
报错如下:

➜  flink-1.8.1 ./bin/flink run -m yarn-cluster
./examples/batch/WordCount.jar
------------------------------------------------------------
 The program finished with the following exception:

java.lang.RuntimeException: Could not identify hostname and port in
'yarn-cluster'.
at
org.apache.flink.client.ClientUtils.parseHostPortAddress(ClientUtils.java:47)
at
org.apache.flink.client.cli.AbstractCustomCommandLine.applyCommandLineOptionsToConfiguration(AbstractCustomCommandLine.java:83)
at
org.apache.flink.client.cli.DefaultCLI.createClusterDescriptor(DefaultCLI.java:60)
at
org.apache.flink.client.cli.DefaultCLI.createClusterDescriptor(DefaultCLI.java:35)
at org.apache.flink.client.cli.CliFrontend.runProgram(CliFrontend.java:224)
at org.apache.flink.client.cli.CliFrontend.run(CliFrontend.java:213)
at
org.apache.flink.client.cli.CliFrontend.parseParameters(CliFrontend.java:1050)
at
org.apache.flink.client.cli.CliFrontend.lambda$main$11(CliFrontend.java:1126)
at
org.apache.flink.runtime.security.NoOpSecurityContext.runSecured(NoOpSecurityContext.java:30)
at org.apache.flink.client.cli.CliFrontend.main(CliFrontend.java:1126)


疑问:
1.为什么会将 yarn-clustet解析为host?
2.要运行single flink job on yarn的正确姿势是啥?

Best,
Yuhuan

回复