For the first time, Hadoop was configured on the VM, and three virtual machines were created, one as namenode and jobtracker.
The other two machines are used as datanode and tasktracker.
After configuration, start the Cluster
View cluster status through http: // localhost: 50700
No datanode found
Check the node and find that the datanode process has been started. view the logs on the datanode machine.
2014-03-01 22:11:17, 473 INFO org. apache. hadoop. ipc. client: Retrying connect to server: Master. hadoop/192.168.128.132: 9000. already tried 0 time (s); retry policy is RetryUpToMaximumCountWithFixedSleep (maxRetries = 10, sleepTime = 1 SECONDS)
2014-03-01 22:11:18, 477 INFO org. apache. hadoop. ipc. client: Retrying connect to server: Master. hadoop/192.168.128.132: 9000. already tried 1 time (s); retry policy is RetryUpToMaximumCountWithFixedSleep (maxRetries = 10, sleepTime = 1 SECONDS)
2014-03-01 22:11:19, 481 INFO org. apache. hadoop. ipc. client: Retrying connect to server: Master. hadoop/192.168.128.132: 9000. already tried 2 time (s); retry policy is RetryUpToMaximumCountWithFixedSleep (maxRetries = 10, sleepTime = 1 SECONDS)
2014-03-01 22:11:20, 485 INFO org. apache. hadoop. ipc. client: Retrying connect to server: Master. hadoop/192.168.128.132: 9000. already tried 3 time (s); retry policy is RetryUpToMaximumCountWithFixedSleep (maxRetries = 10, sleepTime = 1 SECONDS)
2014-03-01 22:11:21, 489 INFO org. apache. hadoop. ipc. client: Retrying connect to server: Master. hadoop/192.168.128.132: 9000. already tried 4 time (s); retry policy is RetryUpToMaximumCountWithFixedSleep (maxRetries = 10, sleepTime = 1 SECONDS)
It is found that datanode cannot connect to the master node. However, after trying, you can ping it to the node to check that port 9000 is also in the listening status.
Eventually found in core-site.xml
<Property>
<Name> fs. default. name </name>
<Value> hdfs :/// localhost: 9000 </value>
</Property>
The listening port 127.0.0.1 cannot be accessed by external servers.
Change to the host name. Everything works.
<Property>
<Name> fs. default. name </name>
& Lt; value & gt; hdfs: // Master. Hadoop: 9000 & lt;/value & gt;
</Property>
Build a Hadoop environment on Ubuntu 13.04
Cluster configuration for Ubuntu 12.10 + Hadoop 1.2.1
Build a Hadoop environment on Ubuntu (standalone mode + pseudo Distribution Mode)
Configuration of Hadoop environment in Ubuntu
Detailed tutorial on creating a Hadoop environment for standalone Edition
Build a Hadoop environment (using virtual machines to build two Ubuntu systems in a Winodws environment)