flink部署-低级错误记录

flink部署-低级错误记录,第1张

项目场景:

flink-yarn模式 配置,启动测试


问题1

Flink Application Mode模式执行任务时出错

 The program finished with the following exception:

java.lang.IllegalStateException: No ClusterClientFactory found. If you were targeting a Yarn cluster, please make sure to export the HADOOP_CLASSPATH environment variable or have hadoop in your classpath. For more information refer to the "Deployment" section of the official Apache Flink documentation.
        at org.apache.flink.client.deployment.DefaultClusterClientServiceLoader.getClusterClientFactory(DefaultClusterClientServiceLoader.java:83)
        at org.apache.flink.client.deployment.application.cli.ApplicationClusterDeployer.run(ApplicationClusterDeployer.java:61)
        at org.apache.flink.client.cli.CliFrontend.runApplication(CliFrontend.java:213)
        at org.apache.flink.client.cli.CliFrontend.parseAndRun(CliFrontend.java:1057)
        at org.apache.flink.client.cli.CliFrontend.lambda$main(CliFrontend.java:1132)
        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:1729)
        at org.apache.flink.runtime.security.contexts.HadoopSecurityContext.runSecured(HadoopSecurityContext.java:41)
        at org.apache.flink.client.cli.CliFrontend.main(CliFrontend.java:1132)
----------------------------------------------------------------------------

问题1原因:
bin/flink run-application -t yarn-appliction -c com.atguigu.flink.chapter01.Flink02_UnBounded_WC_Lambda ./flink211125-1.0-SNAPSHOT.jar

执行上述命令时,手打打少了一个a,导致奇怪的错误。
正确命令如下:
bin/flink run-application -t yarn-application -c com.atguigu.flink.chapter01.Flink02_UnBounded_WC_Lambda ./flink211125-1.0-SNAPSHOT.jar

问题2

配置了flink-yarn高可用后,提交任务测试。

bin/flink run-application -t yarn-application -c com.atguigu.flink.chapter01.Flink02_UnBounded_WC_Lambda ./flink211125-1.0-SNAPSHOT.jar

之后一直处于 ACCEPTED 状态。

Deploying cluster, current state ACCEPTED
Deployment took more than 60 seconds. Please check if the requested resources are available in the YARN cluster

问题2原因

配置了高可用以后要起zookeeper, 否则一直连不上zookeeper,会一直是ACCEPTED状态,超过60秒还会提示你检查yarn集群资源够不够。

原因就是:配了高可用但没有起zookeeper,把zookeeper起了之后问题解决。


欢迎分享,转载请注明来源:内存溢出

原文地址: https://outofmemory.cn/langs/885712.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-14
下一篇 2022-05-14

发表评论

登录后才能评论

评论列表(0条)

保存