Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

HDFS NameNode won't leave safemode

Solved Go to solution

HDFS NameNode won't leave safemode

Explorer

Hello,

- I've setup a Sandbox HDP 3.0.1.
- Determine Network Adapter of Your VirtualBox Sandbox (Bridged Adapter, IP:192.168.1.37).
- I edited the hosts file (on my computer, windows) and assigned the domain sandbox-hdp.hortonworks.com to the IP address of 192.168.1.37, but When I start all services via the Ambari UI, I receive the following error message:

 

safemode: Call From sandbox-hdp.hortonworks.com/172.18.0.2 to sandbox-hdp.hortonworks.com:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused


2019-09-29 18:25:10,968 - Retrying after 10 seconds. Reason: Execution of '/usr/hdp/current/hadoop-hdfs-namenode/bin/hdfs dfsadmin -fs hdfs://sandbox-hdp.hortonworks.com:8020 -safemode get | grep 'Safe mode is OFF'' returned 1. safemode: Call From sandbox-hdp.hortonworks.com/172.18.0.2 to sandbox-hdp.hortonworks.com:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused.

 

I do not know how to fix the error. Who knows, please just help, thank you!

1 ACCEPTED SOLUTION

Accepted Solutions

Re: HDFS NameNode won't leave safemode

New Contributor

At the startup of NameNode it loads the file system namespace from the last saved fsimage into its main memory and the edits log file showbox apk. Then, merges edits log file on fsimage and results in new file system namespace.

13 REPLIES 13
Highlighted

Re: HDFS NameNode won't leave safemode

Super Mentor

@ThanhP 
Are you sure that your NameNode is running fine and listening to Port 8020 ?
Can you please verify if the port is actually listening or not?

 

# netstat -tnlpa | grep 8020
# netstat -tnlpa | grep 50070
# ps -ef | grep -i NameNode

 

.

Most probably the NameNode may not be running healthy, Or there may be some errors  reported inside  the  "/var/log/hadoop/hdfs/hadoop-hdfs-namenode-*.log"
Can you please check and share the NN log.

Also as you are using Sandbox which runs many other services so some times due to less resource availability (like free memory/cpu..etc)  services does not run properly so please try to stop the services which you are not using currently like Spark/Zeppelin/Oozie ..etc to free some resources and then restart NameNode to see if it works fine?
Just start the Selective Services first like HDFS/Yarn/MapReduce/Zookeeper ...etc and then later based on resource availability we can start other services which are needed else just stop other services and put them in Maintenance mode until you actually want to test them.

Re: HDFS NameNode won't leave safemode

Super Mentor

@ThanhP 
In addition to my previous notes,  In order to further isolate the issue you can also try to start the NameNode (OR Hdfs services) manually using command line to see if it is starting fine? 

See the doc: how to start HDFS services or individual components manually via command line:
https://docs.cloudera.com/HDPDocuments/HDP3/HDP-3.1.0/administration/content/starting_hdp_services.h...

Example:

# su -l hdfs -c "/usr/hdp/current/hadoop-hdfs-namenode/../hadoop/sbin/hadoop-daemon.sh start namenode"

.

 

Re: HDFS NameNode won't leave safemode

Explorer

Hello @jsensharma

I checked NameNode has no listening on ports 8020 and 50070

 

Results after executing the ps -ef | command grep -i NameNode:

[root@sandbox-hdp ~]# ps -ef | grep -i NameNode

hdfs      1879     1  0 07:47 ?        00:00:06 /usr/lib/jvm/java/bin/java -Dproc_secondarynamenode -Dhdp.version=3.0.1.0-187 -Djava.net.preferIPv4Stack=true -Dhdp.version=3.0.1.0-187 -Dhdfs.audit.logger=INFO,NullAppender -server -XX:ParallelGCThreads=8 -XX:+UseConcMarkSweepGC -XX:ErrorFile=/var/log/hadoop/hdfs/hs_err_pid%p.log -XX:NewSize=128m -XX:MaxNewSize=128m -Xloggc:/var/log/hadoop/hdfs/gc.log-201909300747 -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -XX:+PrintGCDateStamps -XX:CMSInitiatingOccupancyFraction=70 -XX:+UseCMSInitiatingOccupancyOnly -Xms1024m -Xmx1024m -Dhadoop.security.logger=INFO,DRFAS -Dhdfs.audit.logger=INFO,DRFAAUDIT -XX:OnOutOfMemoryError=/usr/hdp/current/hadoop-hdfs-secondarynamenode/bin/kill-secondary-name-node -Dyarn.log.dir=/var/log/hadoop/hdfs -Dyarn.log.file=hadoop-hdfs-secondarynamenode-sandbox-hdp.hortonworks.com.log -Dyarn.home.dir=/usr/hdp/3.0.1.0-187/hadoop-yarn -Dyarn.root.logger=INFO,console -Djava.library.path=:/usr/hdp/3.0.1.0-187/hadoop/lib/native/Linux-amd64-64:/usr/hdp/3.0.1.0-187/hadoop/lib/native -Dhadoop.log.dir=/var/log/hadoop/hdfs -Dhadoop.log.file=hadoop-hdfs-secondarynamenode-sandbox-hdp.hortonworks.com.log -Dhadoop.home.dir=/usr/hdp/3.0.1.0-187/hadoop -Dhadoop.id.str=hdfs -Dhadoop.root.logger=INFO,RFA -Dhadoop.policy.file=hadoop-policy.xml org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode

root     12433 12140  0 07:59 pts/0    00:00:00 grep --color=auto -i NameNode

 

File Log

==> /var/log/hadoop/hdfs/hadoop-hdfs-secondarynamenode-sandbox-hdp.hortonworks.com.log <==

2019-09-30 09:04:11,529 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 2 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:12,530 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 3 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:13,531 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 4 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:14,532 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 5 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:15,533 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 6 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:16,535 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 7 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:17,540 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 8 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:18,543 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 9 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:19,544 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 10 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:20,545 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 11 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:21,546 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 12 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:22,547 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 13 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:23,549 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 14 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:24,552 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 15 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:25,554 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 16 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:26,555 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 17 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:27,556 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 18 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:28,557 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 19 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:29,558 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 20 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:30,559 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 21 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:31,560 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 22 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:32,561 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 23 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:33,563 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 24 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:34,564 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 25 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:35,565 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 26 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:36,567 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 27 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:37,569 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 28 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:38,570 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 29 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:39,573 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 30 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:40,575 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 31 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:41,581 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 32 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:42,584 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 33 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:43,594 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 34 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:44,595 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 35 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:45,599 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 36 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:46,605 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 37 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:47,607 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 38 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:48,608 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 39 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:49,609 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 40 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

2019-09-30 09:04:50,615 INFO  ipc.Client (Client.java:handleConnectionFailure(942)) - Retrying connect to server: sandbox-hdp.hortonworks.com/172.18.0.2:8020. Already tried 41 time(s); retry policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=50, sleepTime=1000 MILLISECONDS)

==> /var/log/hadoop/hdfs/hadoop-hdfs-secondarynamenode-sandbox-hdp.hortonworks.com.out <==

java.net.ConnectException: Call From sandbox-hdp.hortonworks.com/172.18.0.2 to sandbox-hdp.hortonworks.com:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused

                at sun.reflect.GeneratedConstructorAccessor9.newInstance(Unknown Source)

                at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

                at java.lang.reflect.Constructor.newInstance(Constructor.java:423)

                at org.apache.hadoop.net.NetUtils.wrapWithMessage(NetUtils.java:831)

                at org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:755)

                at org.apache.hadoop.ipc.Client.getRpcResponse(Client.java:1501)

                at org.apache.hadoop.ipc.Client.call(Client.java:1443)

                at org.apache.hadoop.ipc.Client.call(Client.java:1353)

                at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:228)

                at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:116)

                at com.sun.proxy.$Proxy10.getTransactionId(Unknown Source)

                at org.apache.hadoop.hdfs.protocolPB.NamenodeProtocolTranslatorPB.getTransactionID(NamenodeProtocolTranslatorPB.java:130)

                at sun.reflect.GeneratedMethodAccessor7.invoke(Unknown Source)

                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

                at java.lang.reflect.Method.invoke(Method.java:498)

                at org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMethod(RetryInvocationHandler.java:422)

                at org.apache.hadoop.io.retry.RetryInvocationHandler$Call.invokeMethod(RetryInvocationHandler.java:165)

                at org.apache.hadoop.io.retry.RetryInvocationHandler$Call.invoke(RetryInvocationHandler.java:157)

                at org.apache.hadoop.io.retry.RetryInvocationHandler$Call.invokeOnce(RetryInvocationHandler.java:95)

                at org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(RetryInvocationHandler.java:359)

                at com.sun.proxy.$Proxy11.getTransactionID(Unknown Source)

                at org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.countUncheckpointedTxns(SecondaryNameNode.java:660)

                at org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.shouldCheckpointBasedOnCount(SecondaryNameNode.java:668)

                at org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.doWork(SecondaryNameNode.java:358)

                at org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode$1.run(SecondaryNameNode.java:325)

                at org.apache.hadoop.security.SecurityUtil.doAsLoginUserOrFatal(SecurityUtil.java:482)

                at org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.run(SecondaryNameNode.java:321)

                at java.lang.Thread.run(Thread.java:748)

Caused by: java.net.ConnectException: Connection refused

                at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)

                at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717)

                at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)

                at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:531)

                at org.apache.hadoop.ipc.Client$Connection.setupConnection(Client.java:687)

                at org.apache.hadoop.ipc.Client$Connection.setupIOstreams(Client.java:790)

                at org.apache.hadoop.ipc.Client$Connection.access$3600(Client.java:410)

                at org.apache.hadoop.ipc.Client.getConnection(Client.java:1558)

                at org.apache.hadoop.ipc.Client.call(Client.java:1389)

                ... 21 more

 

I have followed the instructions in this article, but still cannot fix it

https://www.ibm.com/support/pages/ibm-biginsights-how-configure-hadoop-client-port-8020-bind-all-net...

 

Thanks for reviewing help, sincerely thank you!

Re: HDFS NameNode won't leave safemode

Mentor

@ThanhP 

I had the same situation with my Sandbox I had not used for a while.
Here is my config I disabled all the network adapters except one which I attached to my LAN using the Bridged Adapter, 12  GB, 4 CPU's see attached screenshots once my Sandbox had booted I accessed the CLI and managed to turn off safe mode as the namenode was not starting. Bridged.PNGConsole CLI.PNGNetwork.PNG
You should access the Linux CLI through the web interface. Can you try that and revert

Re: HDFS NameNode won't leave safemode

New Contributor

At the startup of NameNode it loads the file system namespace from the last saved fsimage into its main memory and the edits log file showbox apk. Then, merges edits log file on fsimage and results in new file system namespace.

Re: HDFS NameNode won't leave safemode

Explorer

@Herman 

I think the problem you said is right. Can you show me how to fix it?

Re: HDFS NameNode won't leave safemode

Mentor

@ThanhP 

 

What @Herman  was trying to explain is what happens in the background and you cannot influence or manually replicate the process. 
The screenshots I attached are the best you can get to resolve the issue because the screenshots are from exactly the same sandbox you are using.

 

So follow those steps and revert

Re: HDFS NameNode won't leave safemode

Explorer

Cảm ơn @Shelton 

Re: HDFS NameNode won't leave safemode

Explorer

@Shelton 

I have followed the steps he instructed, but still cannot fix. I have attached 2 photos, thanks for reviewing. Thank you very much!

1.JPG2.JPG