TaskTracker节点心跳监控配置

1. 可以配置TaskTracker,让其周期性的执行脚本以报告其自身的"healthy or not".

     (1)TaskTracker周期性的执行脚本,检查输出是否含有“ERROR”,若是,该节点的状态被报告为"unhealthy",JobTracker将该TaskTracker节点设为black-listed,并且不再会给该节点分配任务。

     (2) TaskTracker将继续周期性执行该脚本,直到该节点变为恢复"healthy",其将从JobTracker的black-listed中删除。

     (3)Admin可以从JobTracker的Web接口查看TaskTracker节点的状态(healthy or unhealthy)。


2. 配置:conf/mapred-site.xml

         


                mapreduce.tasktracker.healthchecker.script.path
                /home/hadoop/program/hadoop-0.21.0/*****
                Absolute path to the script which is periodically run by the TaskTracker to determine if the node is healthy or not. The file should be executable by the TaskTracker. If the value of this key is empty or the file does not exist or is not executable, node health monitoring is not started




                mapreduce.tasktracker.healthchecker.interval
                10000
                Frequency at which the node health script is run, in milliseconds



                mapreduce.tasktracker.healthchecker.script.timeout
                ***
                Time after which the node health script will be killed by the TaskTracker if unresponsive. The node is marked unhealthy. if node health script times out.



                mapreduce.tasktracker.healthchecker.script.args
                 ,  , 
                Extra arguments that can be passed to the node health script when launched. These should be comma separated list of arguments. 

     

你可能感兴趣的:(Hadoop)