当 运行 火花时,Yarn 最大限度地使用 Vcores
Maximize use of Vcores by Yarn when running spark
我有一个在 4 个节点中使用 Hadoop 2.9 的虚拟化集群。
每个节点有 16 个 cpu 和 126 GB 内存。
我尝试将 yarn.scheduler.minimum-allocation-vcores 设置为不同于 1 的其他值,当我 运行 spark-submit 声明 yarn 为主时,每个容器仅使用 1 个 vcore .
有没有办法覆盖它?
谢谢!
使用spark.executor.cores
。来自 docs:
The number of cores to use on each executor. In standalone and Mesos coarse-grained modes, setting this parameter allows an application to run multiple executors on the same worker, provided that there are enough cores on that worker. Otherwise, only one executor per application will run on each worker.
默认情况下是:
1 in YARN mode
我有一个在 4 个节点中使用 Hadoop 2.9 的虚拟化集群。 每个节点有 16 个 cpu 和 126 GB 内存。
我尝试将 yarn.scheduler.minimum-allocation-vcores 设置为不同于 1 的其他值,当我 运行 spark-submit 声明 yarn 为主时,每个容器仅使用 1 个 vcore .
有没有办法覆盖它?
谢谢!
使用spark.executor.cores
。来自 docs:
The number of cores to use on each executor. In standalone and Mesos coarse-grained modes, setting this parameter allows an application to run multiple executors on the same worker, provided that there are enough cores on that worker. Otherwise, only one executor per application will run on each worker.
默认情况下是:
1 in YARN mode