hadoop 建立单点集群

hadoop-2.2.0




1.下载解压到/opt,文件夹改名hadoop

2./etc/profile.d文件夹下建立hadoop.sh
内容都是根据文档添加的
HADOOP_COMMON_HOME=/opt/hadoop
HADOOP_HDFS_HOME=/opt/hadoop
HADOOP_MAPRED_HOME=/opt/hadoop
HADOOP_YARN_HOME=/opt/hadoop


HADOOP_CONF_DIR=/opt/hadoop/conf


YARN_CONF_DIR=/opt/hadoop/conf

export HADOOP_COMMON_HOME
export HADOOP_HDFS_HOME
export HADOOP_MAPRED_HOME
export HADOOP_YARN_HOME
export HADOOP_CONF_DIR
export YARN_CONF_DIR

3.在HADOOP_HOME文件夹下建立conf文件夹,把HADOOP_HOME/etc/hadoop文件夹下的capacity-scheduler.xml,mapred-site.xml,yarn-site.xml文件拷贝到conf文件夹下
根据帮助文档的内容修改
别忘了yarn-site.xml中
<property>
    <name>yarn.nodemanager.address</name>
    <value>0.0.0.0:9333</value>
    <description>the nodemanagers bind to this port</description>
  </property>  

port需要填一个真实的port  而不是“port”



4.终端输入  命令在sbin目录
$ yarn-daemon.sh start resourcemanager
$ yarn-daemon.sh start nodemanager
























你可能感兴趣的:(hadoop,集群,hdfs,yarn)