Reputation: 27
Data node service is not started on one of my Hadoop cluster.
Data node logs has the following information...
Exception details on PC where datanode service is not started:
2015-08-12 15:51:09,331 INFO org.apache.hadoop.http.HttpServer2: HttpServer.start() threw a non Bind IOException java.net.BindException: Port in use: localhost:0 at org.apache.hadoop.http.HttpServer2.openListeners(HttpServer2.java:919) at org.apache.hadoop.http.HttpSe ...........................
On successful Data Node PCs the Log looks like this
2015-08-12 15:43:57,520 INFO org.apache.hadoop.http.HttpServer2: Jetty bound to port 34958
2015-08-12 15:43:57,520 INFO org.mortbay.log: jetty-6.1.26
2015-08-12 15:43:57,619 INFO org.mortbay.log: Started HttpServer2$SelectChannelConnectorWithSafeStartup@localhost:34958
I have tried fixing the ports in hdfs-site.xml as explained in the link
But this did not work. Please throw some light in fixing this issue.
Thanks
Upvotes: 1
Views: 2940
Reputation: 1
I have uncommented the following line in /etc/hosts
and everything worked fine.
127.0.0.1 localhost
Upvotes: 0
Reputation: 954
"localhost:0 " please check your /etc/hosts ,most likely this file not set well
Upvotes: 2
Reputation: 453
This problem is due to the port is already used, hence BindException Thrown. to fix this issue follow the below steps.
1.
run netstat -np command to know the port used with process id
2.
Kill process id for the port which is already bind.
Upvotes: -1