gpt4 book ai didi

hadoop - 在 hadoop 2.4 中使用 yarn 在集群模式下运行 Spark 时出现 InvalidResourceRequestException Yarn Exception

转载 作者:可可西里 更新时间:2023-11-01 16:32:04 26 4
gpt4 key购买 nike

使用 Apache spark 1.1.0hadoop 2.4

另外,我的集群在 CDH 5.1.3 上

我尝试使用以下命令启动 spark with yarn

./spark-shell --master yarn 
./spark-shell --master yarn-client

我得到以下异常:

14/10/15 21:33:32 INFO cluster.YarnClientSchedulerBackend: Application report from ASM: appMasterRpcPort: 0 appStartTime: 1413388999108 yarnAppState: RUNNING

14/10/15 21:33:44 ERROR cluster.YarnClientSchedulerBackend: Yarn application already ended: FAILED

======Node manager Exception ============================================

Caused by: org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.yarn.exceptions.InvalidResourceRequestException): Invalid resource request, requested memory < 0, or requested memory > max configured, requestedMemory=1408, maxMemory=1024 at org.apache.hadoop.yarn.server.resourcemanager.scheduler.SchedulerUtils.validateResourceRequest(SchedulerUtils.java:228) at org.apache.hadoop.yarn.server.resourcemanager.RMServerUtils.validateResourceRequests(RMServerUtils.java:80) at org.apache.hadoop.yarn.server.resourcemanager.ApplicationMasterService.allocate(ApplicationMasterService.java:444) at org.apache.hadoop.yarn.api.impl.pb.service.ApplicationMasterProtocolPBServiceImpl.allocate(ApplicationMasterProtocolPBServiceImpl.java:60) at org.apache.hadoop.yarn.proto.ApplicationMasterProtocol$ApplicationMasterProtocolService$2.callBlockingMethod(ApplicationMasterProtocol.java:99) at org.apache.hadoop.ipc.ProtobufRpcEngine$Server$ProtoBufRpcInvoker.call(ProtobufRpcEngine.java:585) at org.apache.hadoop.ipc.RPC$Server.call(RPC.java:1026) at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1986) at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1982) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:396) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1554) at org.apache.hadoop.ipc.Server$Handler.run(Server.java:1980)

at org.apache.hadoop.ipc.Client.call(Client.java:1410) at org.apache.hadoop.ipc.Client.call(Client.java:1363) at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:206) at $Proxy11.allocate(Unknown Source) at org.apache.hadoop.yarn.api.impl.pb.client.ApplicationMasterProtocolPBClientImpl.allocate(ApplicationMasterProtocolPBClientImpl.java:77) ... 20 more

最佳答案

根据您的 YARN 配置,应用程序可以为容器请求的最大内存为 1024MB。但是 spark 客户端正在请求一个 1408MB 的容器。更改 spark 的配置文件以请求更少的 RAM 或提高 YARN 中的最大内存。

关于hadoop - 在 hadoop 2.4 中使用 yarn 在集群模式下运行 Spark 时出现 InvalidResourceRequestException Yarn Exception,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26387221/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com