ResourceManager
- Update log level
- 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
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/</</g" am.log
sed -i "s/>/>/g" am.log
sed -i "s/^M//g" am.log