Installation
- Check the firewalls among servers. ( Recommended to open all ports among servers )
- Create same account( TEST_ACCOUNT ) to all servers.
- Create public key of TEST_ACCOUNT for each server. ( ssh-keygen )
- Authorize public key of TEST_ACCOUNT in master server to each slave server TEST_ACCOUNT so that master account can access each slave servers through ssh( FILE : $HOME/.ssh/authorized_keys ). Make sure the value of chmod of authorized_keys file is “0×600″ or it doesn’t work.
- Copy hadoop-1.2.1 to the same directory of each server.
- Modify $HADOOP/conf/masters & $HADOOP/conf/slaves to add master and slave servers. Copying modified file to each server is recommended.
- SAMPLE : masters
- SAMPLE : slaves
- SAMPLE : masters
- Modify /etc/hosts to recognize hostname of each servers(sudo is needed.). Recommended to use same content among servers. I used hostname like “hadoop-master1″ or “hadoop-slave3″.
- SAMPLE : /etc/hosts
- SAMPLE : /etc/hosts
- Configure hadoop setting for each server.
- Run Format($HADOOP/bin/hadoop name node -format) and Start($HADOOP/bin/start-all.sh) at master server.
Tips
Format script
I used two masters with two mounted directories ( /data1 & /data2 ) and five slaves with three mounted directories( /data1 & /data2 & /data3 ). You can change the directory of your own. Locate this script to $HADOOP/bin
Trouble-shootings
1. Unregistered data node
- This exception occurred because of different content of $HADOOP/conf/masters and $HADOOP/conf/slaves among servers.
2. ERROR org.apache.hadoop.metrics2.impl.MetricsSystemImpl: Error getting localhost name. Using ‘localhost’…
- This issue is because the server has localhost in “/etc/hosts” or “/etc/HOSTNAME” or “rc.conf”. There’re several ways to resolve this issues and I choose “removing a line which includes localhost” in hostname file.
3. Bad connect ack with firstBadLink as xxx.xxx.xxx:50010
- There are several reasons to cause this issue. In my case, I turned off the firewall ( for example “/etc/init.d/iptable stop” ) to resolve this issue (!!Not recommended because turning off the firewall is dangerous for servers which can be accessed from outside. Refer the following site to add IPs and PORTs to the firewall rule. – http://blog.cloudera.com/blog/2009/08/hadoop-default-ports-quick-reference/ )
'About Computer > 서버관리' 카테고리의 다른 글
[번역] Memory allocation mechanisms in AIX / AIX: Throughput problems when malloc is called often (0) | 2015.09.25 |
---|---|
OpenSSH Public Key Authentication (0) | 2015.08.13 |
phps.kr linux 서버 구축 순 (cont.d) (0) | 2014.01.16 |
실수로 Parallels MacAddress를 수정한 후 Ubuntu Network가 동작하지 않을 때 (0) | 2013.12.22 |
nitrous.io (TODO) (0) | 2013.11.04 |
댓글