1、安装ssh,JDK(修改)
配置java_home:sudo gedit /etc/environment
配置jvm: sudo update-alternatives --config java
2、设置SSH为无密码
ssh-keygen -t rsa -f ~/.ssh/id_rsa -P \"\"
cp ~/.ssh/id_rsa.pub ~/.ssh/authorized_keys
测试: ssh localhost
3、下载hadoop(0.20.203)、hbase(0.90.3)压缩包,解压到/home/hadoop,修改配置
修改hadoop目录文件权限
sudo chown asyty /home/hadoop
sudo chown 755 /home/hadoop
4、配置hadoop core-site.xml / hdfs-site.xml / mapred-site.xml / haddop-env.sh
hadoop-env.xml:
添加java_home, export.html' target='_blank'>export JAVA_HOME=/usr/........xxxxx
core-site.xml:
<configuration>
<property>
<name>fs.default.name</name>
<value>hdfs://localhost:9000</value>
</property>
<property>
<name>hadoop.tmp.dir</name>
<value>/var/hadoop/hadoop-${user.name}</value>
</property>
</configuration>
hdfs-site.xml:
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
</configuration>
mapred-site.xml:
<configuration>
<property>
<name>mapred.job.tracker</name>
<value>localhost:9001</value>
</property>
</configuration>
格式化namenode:
切换到hadoop安装目录:bin/hadoop namenode -format