【Hadoop】YARN 完全分布式配置
mv mapred-site.xml.template mapred-site.xml
// 基于YARN的资源调度配置
vi etc/hadoop/mapred-site.xml:
<configuration>
<property>
<name>mapreduce.framework.name</name>
<value>yarn</value>
</property>
</configuration>
vi etc/hadoop/yarn-site.xml:
<configuration>
<property>
<name>yarn.nodemanager.aux-services</name>
<value>mapreduce_shuffle</value>
</property>
<property>
<name>yarn.resourcemanager.resource-tracker.address</name>
<value>172.16.152.130:8031</value>
</property>
<property>
<name>yarn.resourcemanager.address</name>
<value>172.16.152.130:8032</value>
</property>
<property>
<name>yarn.resourcemanager.scheduler.address</name>
<value>172.16.152.130:8034</value>
</property>
<property>
<name>yarn.resourcemanager.webapp.address</name>
<value>172.16.152.130:8088</value>
</property>
<property>
<name>yarn.log-aggregation-enable</name>
<value>true</value>
</property>
<property>
<name>yarn.log.server.url</name>
<value>http://master:19888/jobhistory/logs/</value>
</property>
</configuration>
修改后拷贝至从节点(slave)
scp -r yarn-site.xml root@slave:/usr/local/software/hadoop-2.5.1/etc/hadoop/
$ sbin/start-yarn.sh
$ sbin/stop-yarn.sh
在master上jsp 发现 20906 ResourceManager,从节点发现20808 NodeManager 即成功,web 访问YARN :http://master:8088/cluster
“年轻时,我没受过多少系统教育,但什么书都读。读得最多的是诗,包括烂诗,我坚信烂诗早晚会让我邂逅好诗。”
by. 马尔克斯