Cloudera CDH/CDP 및 Hadoop EcoSystem, Semantic IoT등의 개발/운영 기술을 정리합니다. gooper@gooper.com로 문의 주세요.
Job이 끝난 log를 로그를 webui에서 확인하기 위해서는 아래와 같이 설정되어 있어야한다.
1. 설정값 설정
가. yarn-site.xml
<property>
<name>yarn.log.server.url</name>
<value>http://master:19888/jobhistory/logs</value>
</property>
<property>
<name>yarn.log-aggregation-enable</name>
<value>true</value>
</property>
<property>
<name>yarn.nodemanager.log.retain-seconds</name>
<value>900000</value>
</property>
<property>
<name>yarn.nodemanager.remote-app-log-dir</name>
<value>/app-logs</value>
</property>
나. mapred-site.xml
<property>
<name>mapreduce.jobtracker.staging.root.dir</name>
<value>file:///data/hadoop/tmp/staging</value>
</property>
<property>
<name>mapreduce.jobtracker.http.address</name>
<value>sda1:50030</value>
</property>
<property>
<name>mapreduce.jobhistory.address</name>
<value>master:10020</value>
</property>
<property>
<name>mapreduce.jobhistory.webapp.address</name>
<value>master:19888</value>
</property>
2. historyserver 데몬이 기동
기동 : ./sbin/mr-jobhistory-daemon.sh start historyserver
3. 프로세스 확인
jps -m ==>mr-jobhistory-daemon.sh start historyserver
---------------------------------------메세지(오류)내용----------------------
Failed while trying to construct the redirect url to the log server. Log Server url may not be configured
java.lang.Exception: Unknown container. Container either has not started or has already completed or doesn't belong to this node at all.