Flink TaskManagers do not start until job is submitted in YARN cluster

偶尔善良 提交于 2020-01-02 18:24:30

问题


I am using Amazon EMR to run Flink Cluster on YARN. My setup consists of m4.large instances for 1 master and 2 core nodes. I have started the Flink CLuster on YARN with the command: flink-yarn-session -n 2 -d -tm 4096 -s 4.

Flink Job Manager and Application Manager starts but there are no Task Managers running. The Flink Web interface shows 0 for task managers, task slots and slots available. However when I submit a job to flink cluster, then Task Managers get allocated and the job runs and the Web UI shows correct values as expected and goes back to 0 once the job is complete.

I would like Task Managers to be running even when no Job is submitted as I want to use Flink's REST API to monitor and modify parallelism based on the available slots value.

Is there a configuration that I've missed which prevents Task Managers from running all the time?


回答1:


Flink's behavior was changed in FLIP-6 to allow dynamic resource allocation. From Flink version 1.5.0, one can put mode: legacy in flink-conf.yaml to run Flink in the old mode where Task Managers will be started along with Job Manager.



来源:https://stackoverflow.com/questions/52439318/flink-taskmanagers-do-not-start-until-job-is-submitted-in-yarn-cluster

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!