如何为速度设置火花?
我正在运行来分析日志数据。
使用200万行(4G)进行聚合/连接大约需要5分钟。
我在运行1位大师,3位工人在3台机器上。我将执行器内存增加到8g,ES节点从1增加到3。
我正在以客户端模式(https://becominghuman.ai/real-world-python-workloads-on-spark-standalone-clusters-2246346c7040)运行独立的集群,我不使用submit,只是在启动主/工作人员之后运行python代码。
火花似乎发射了3个执行者总数(这是从3个工人)。
我想用微调来调音火花,以获得最好的表现。
我应该采取哪种方式进行优化?
explain api分析作业计划下面是与性能相关的设置
conf.set("es.scroll.size", 10000)
conf.set("spark.executor.memory", "8g")
conf.set("spark.driver.memory", "8g")
conf.set("spark.dynamicAllocation.enabled", "true")
conf.set("spark.shuffle.service.enabled", "true")
conf.set("es.nodes.resolve.hostname", "false")
conf.set("spark.driver.extraClassPath", "/usr/local/elasticsearch-hadoop-7.4.2/dist/elasticsearch-spark-20_2.11-7.4.2.jar")
conf.set("es.nodes", settings.ES_HOST)
conf.set("es.nodes.wan.only", 'true')spark-defaults.conf
# https://becominghuman.ai/real-world-python-workloads-on-spark-standalone-clusters-2246346c7040
spark.sql.execution.arrow.enabled true
# https://spark.apache.org/docs/latest/job-scheduling.html#dynamic-resource-allocation
spark.dynamicAllocation.enabled true
spark.shuffle.service.enabled truehttps://stackoverflow.com/questions/59590216
复制相似问题