其他分享
首页 > 其他分享> > spark参数调优

spark参数调优

作者:互联网

spark参数调优

目录

1.num-executors

2.executor-memory

3.executor-cores

4.driver-memory

5.spark.default.parallelism

6.spark.storage.memoryFraction

7.spark.shuffle.memoryFraction

8.total-executor-cores

9.资源参数参考示例

以下是一份spark-submit命令的示例:

./bin/spark-submit \
  --master spark://192.168.1.1:7077 \
  --num-executors 100 \
  --executor-memory 6G \
  --executor-cores 4 \
 --total-executor-cores 400 \ ##standalone default all cores 
  --driver-memory 1G \
  --conf spark.default.parallelism=1000 \
  --conf spark.storage.memoryFraction=0.5 \
  --conf spark.shuffle.memoryFraction=0.3 \

示例2:

/opt/spark-2.1.1-bin-hadoop2.6/bin/spark-submit --class com.hangshu.start.RecoverProApp \
--master yarn \
--deploy-mode cluster \
--num-executors 27 \
--driver-memory 2g \
--executor-memory 5g \
--executor-cores 2 \
--conf spark.default.parallelism=135 \
--queue thequeue \
/opt/spark_jar/offline/dataAnalys-1.0.jar "2162304858206502921" "粗纱工序" "2022-07-21 05:35:49"

示例3:

/opt/spark-2.1.1-bin-hadoop2.6/bin/spark-submit --class com.hangshu.start.CalcProApp \
--master yarn \
--deploy-mode cluster \
--num-executors 27 \
--driver-memory 2g \
--executor-memory 5g \
--executor-cores 2 \
--conf spark.default.parallelism=135 \
--queue thequeue \
/opt/spark_jar/offline/dataAnalys-1.0.jar

6-2

5-3

后续

标签:--,executor,调优,参数,内存,Executor,spark
来源: https://www.cnblogs.com/cw2blog/p/16689411.html