微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Spark num executor、executor core和executor memory相关的问题

如何解决Spark num executor、executor core和executor memory相关的问题

集群矩阵详细信息 - 节点 = 1,vcores = 8,内存 = 25 GB

调度器矩阵-最小分配=内存1024,vCores:1;最大分配 = 内存 3072,vCores:2

在 spark-defaults.conf 文件中 spark.dynamicAllocation.enabled=true

我尝试了命令:

pyspark --master yarn --num-executors 2 --executor-cores 4 --executor-memory 3G

我对 Spark 很陌生。所以,我只是想了解如何分配内存和任务。我在 cloudera 集群中尝试过。但我收到如下错误

required execution memory (3072),overhead (384),and PySpark memory (0 MB) is above the max threshold 
(3072 MB) of the cluster! Please check the values of 'yarn.scheduler.maximum-allocation-mb' and/or
'yarn.nodemanager.memory-mb'.

当我尝试使用以下命令时,它正在工作:

pyspark --master yarn --num-executors 2 --executor-cores 2 --executor-memory 1G
pyspark --master yarn --num-executors 2 --executor-cores 2 --executor-memory 2G

我尝试了以下命令:

pyspark --master yarn --num-executors 2 --executor-cores 2 --executor-memory 3G 

它也不起作用。

那么,这是否是我无法跨越调度程序的最大分配(内存 3072,在这种情况下为 vCores:2)的原因?谁能解释一下。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。