0
点赞
收藏
分享

微信扫一扫

提交spark任务到yarn集群上

灯火南山 2022-07-12 阅读 159

先Maven打包自己编写的程序.

放到Linux指定目录下

放到
/root/module/spark_job/realtime-parent.jar

编写Spark-submit 提交脚本

要注意空格啥的 和路径别写错了

sh脚本文件:

$SPARK_HOME/bin/spark-submit \
--class com.ods.BaseDBMaxwellApp \
--num-executors 80 \
--driver-memory 6g \
--executor-memory 6g \
--executor-cores 3 \
--master yarn \
--deploy-mode cluster \
--queue default \
--conf spark.executor.memoryOverhead=2048 \
--conf spark.core.connection.ack.wait.timeout=300 \
/root/module/spark_job/realtime-parent.jar

class 就是你程序的权限定类名

打开yarn查看发布的job程序


http://zjj102:8088/cluster​​

这个地址是ResourcesManager所在的机器的ip


举报

相关推荐

0 条评论