spark-submit报错

spark-submit --class  ${main_class} \
--master yarn \
--deploy-mode client \
--driver-memory 8g \
--executor-memory 6g \
--num-executors 1 \
--executor-cores 34 \
 ${HOME_PATH}/obs_finance-1.0-SNAPSHOT-jar-with-dependencies.jar ${year_month}

注意这个34超过了我们yarn设置的最大32

 不出意外就报错了

Caused by: java.io.IOException: Failed to send RPC RPC 6675935870406582041 to /9.135.247.xxx:36633: io.netty.channel.StacklessClosedChannelException


23/03/07 10:22:22 ERROR cluster.YarnSchedulerBackend$YarnSchedulerEndpoint: Sending RequestExecutors(1,0,Map(),Set()) to AM was unsuccessful


23/03/07 10:22:22 ERROR util.Utils: Uncaught exception in thread main
org.apache.spark.SparkException: Exception thrown in awaitResult: 

Caused by: java.io.IOException: Connection reset by peer

我们分析报错

rpc / Connection reset by peer/网络原因?其实不是。

 Sending RequestExecutors(1,0,Map(),Set()) to AM was unsuccessful 这句话才是最主要的。

就是向AM申请executors资源的时候失败了,为啥失败,网络原因?还是资源超过上限,按照我们瞎搞的肯定就是资源不够了。

所以合理分配资源。

------------------------------------------------------------------------------------------------------------------------

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值