spark-submit 命令中 spark.executor.cores 和 executor-cores 有什么区别?

What is the difference between spark.executor.cores and executor-cores in the spark-submit command?

spark-submit命令中使用的executor-coresspark.executor.cores有区别吗?

由于 GC 开销内存错误,我的工作失败了,所以我正在尝试增加内核和内存设置。

我正在处理的总容量是两个文件中的 50 M 条记录。

spark-submit 命令中使用的 executor-cores 标志只是在 Spark 配置上设置 spark.executor.cores 设置。所以他们的效果是一样的:)

您可以尝试以下几种方法:

1) 你已经用 YARN 标记了问题,所以如果你发现你没有利用所有的核心,你应该看看

2) 当您通过显式设置 spark.yarn.executor.memoryOverhead 来增加内存开销时,YARN 上的许多内存问题都得到了解决。它将默认为 max(386MB, 0.10* executorMemory),这通常是不够的。