I'm having a weird issue trying to restart my hadoop cluster in Ambari after a reboot of all nodes. Despite not making any configuration changes the name node service fails to start with the error below.
> Fail: Execution of 'su -s /bin/bash - hdfs -c 'export
> PATH=$PATH:/usr/hdp/current/hadoop-client/bin ; hdfs --config
> /etc/hadoop/conf dfsadmin -safemode get' | grep 'Safe mode is OFF''
> returned 1.
I have looked around and found someone pointing to a non UTF-8 encoding issue but have not had any luck resolving this. Can someone tell me what this error means or how to debug it?
- Duncan Krebs
Safemode for the NameNode is essentially a read-only mode for the Hadoop Distributed File System (HDFS) cluster. NameNode might enter into Safemode for different reasons, such as the following: Available space is less than the amount of space required for the NameNode storage directory.
The name node service was failing to start because safe mode was on. After reading up on safe mode I realized that it is turned on when read only mode is necessary for the name node. I'm not sure what caused it to stay in safe mode but running this command below resolved my issue.
sudo -u hdfs hdfs dfsadmin -safemode leave
Hope this helps someone. - Duncan Krebs
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With