# JAVAexport JAVA_HOME=/usr/lib/jdk1.7.0_60export JRE_HOME=/usr/lib/jdk1.7.0_60/jre export CLASSPATH=.:$CLASSPATH:$JAVA_HOME/lib:$JRE_HOME/lib export PATH=$PATH:$JAVA_HOME/bin:$JRE_HOME/bin
core-site.xml
fs.default.name hdfs://cdh0:8020 hadoop.tmp.dir /data/dfs/${user.name}
hdfs-site.xml
dfs.name.dir /data/dfs/name dfs.data.dir /data/dfs/dn dfs.replication 1
mapred-site.xml
mapred.job.tracker cdh0:8021 mapred.local.dir /data/mapred/local
masters
cdh0
slaves
cdh1
同步小脚本
#!/bin/bashcd /etc/hadoop-0.20/conf.clusterscp masters slaves hdfs-site.xml core-site.xml mapred-site.xml root@cdh1:/etc/hadoop-0.20/conf.cluster/