Support Questions

Find answers, ask questions, and share your expertise

Unable to start the HDFS using Ambari

avatar
Contributor

Hi All ,

I am trying to start the HDFS using ambari . It remains stuck at following error .

safemode: Call From  hostname/16.250.53.40 to hostname:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused
2017-09-04 09:00:04,064 - Retrying after 10 seconds. Reason: Execution of '/usr/hdp/current/hadoop-hdfs-namenode/bin/hdfs dfsadmin -fs hdfs://hostname:8020 -safemode get | grep 'Safe mode is OFF'' returned 1. safemode:

 Call From hostname/16.250.53.40 to hostname:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused
safemode: 

Call From hostname/16.250.53.40 to hostname:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused
1 ACCEPTED SOLUTION

avatar
Master Mentor

@Kishore Kumar

Pleas emake sure that all the cluster nodes has correct FQDN configured. All the hosts are returning the correct FQDN (hostname) when we run the following command:

# hostname -f

.

Try starting the NameNode manually to see if it works ? As mentioned here: https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.6.2/bk_administration/content/starting_hdp_serv...

.

View solution in original post

6 REPLIES 6

avatar
Master Mentor

@Kishore Kumar

Can you do the following as user root

# su - hdfs

Now as user hdfs

$ hdfs dfsadmin -safemode leave

Then restart through Ambari

avatar
Contributor

@Geoffrey Shelton Okot

I tried that several time . It give following error too

afemode: Call From hostname/16.250.53.40 to hostnamet:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused

avatar
Master Mentor

@Kishore Kumar

Pleas emake sure that all the cluster nodes has correct FQDN configured. All the hosts are returning the correct FQDN (hostname) when we run the following command:

# hostname -f

.

Try starting the NameNode manually to see if it works ? As mentioned here: https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.6.2/bk_administration/content/starting_hdp_serv...

.

avatar
Contributor

It works, after stating manually as mention on this doc .

Thanks

avatar
Expert Contributor
@Kishore Kumar

Did you check the connectivity from Ambari Server to Namenode service?

avatar
Master Mentor

@Kishore Kumar

Can you check the /etc/hosts on the cluster nodes and make sure the entries are like

IP:FQDN : short-name optional

And the FQDN on each host should be the exact output of

# hostname -f