gpt4 book ai didi

hadoop - 无法通过 REST api 杀死 YARN 应用程序

转载 作者:行者123 更新时间:2023-12-02 20:02:18 54 4
gpt4 key购买 nike

我正在使用 Hadoop 2.5.0 (CDH 5.3.5)。

关注 this document ,我试图通过以下 REST api 杀死一个正在运行的 YARN 应用程序(其应用程序 id 是 application_1438849897472_0011):
curl -i -XPUT http://{rm-rest-host}:{rm-rest-port}/ws/v1/cluster/apps/application_1438849897472_0011/killed

但我得到了 404 的状态码和一条异常消息提示

org.apache.hadoop.yarn.webapp.WebAppException: /v1/cluster/apps/application_1438849897472_0011/killed: controller for v1 not found



那么出了什么问题呢?

最佳答案

正确的 URI 以 /state 结尾,而不是 /killed并且您缺少请求正文。

试试这个:

curl -v -X PUT -H "Content-Type: application/json" -d '{"state": "KILLED"}' 'http://{rm-rest-host}:{rm-rest-port}/ws/v1/cluster/apps/{app-id}/state'

关于hadoop - 无法通过 REST api 杀死 YARN 应用程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31868186/

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