Hadoop yarn调试

ResourceManager

  • Update log level

http://headnodehost:9014/logLevel

  • Download log file

Find the log url by the application page

curl -O http://headnodehost:9014/logs/yarn-resourcemanager-HEADNODE0.log

Application Master

  • Update log level

yarn.app.mapreduce.am.log.level

Similar configuration parameter:am.

dfs.namenode.logging.level
mapreduce.map.log.level
mapreduce.reduce.log.level

  • Download log file

application is not finished

curl http://workernode24.zampdmphdp.b1.internal.chinacloudapp.cn:30060/node/containerlogs/container_1438609276772_0006_01_000001/wankun/syslog/?start=0 > am.log

application is finished :

yarn application -list

usage: yarn logs -applicationId <application ID> [OPTIONS]

general options are:
 -appOwner <Application Owner>   AppOwner (assumed to be current user if
                                 not specified)
 -containerId <Container ID>     ContainerId (must be specified if node
                                 address is specified)
 -nodeAddress <Node Address>     NodeAddress in the format nodename:port
                                 (must be specified if container id is
                                 specified)

Eg:

yarn logs -applicationId application_1438609276772_0008 -containerId container_1438609276772_0008_01_000001 -nodeAddress workernode19.zampdmphdp.b1.internal.chinacloudapp.cn > success.log

Note

  • If windows system
sed -i "s/&lt;/</g" am.log 
sed -i "s/&gt;/>/g" am.log 
sed -i "s/^M//g" am.log
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值