Fi-Ware Cosmos: Name node is in safe mode

蹲街弑〆低调 提交于 2020-01-04 07:55:15

问题


I am trying to delete a folder in my Cosmos account, but I get the SafeModeException:

# hadoop fs -rmr /home/<user>/input

rmr: org.apache.hadoop.hdfs.server.namenode.SafeModeException: Cannot delete /user/<user>/input. Name node is in safe mode


回答1:


During start up Namenode loads the filesystem state from fsimage and edits log file. It then waits for datanodes to report their blocks so that it does not prematurely start replicating the blocks though enough replicas already exist in the cluster. During this time Namenode stays in safemode. A Safemode for Namenode is essentially a read-only mode for the HDFS cluster, where it does not allow any modifications to filesystem or blocks. And it takes some time to do above operations and after that it comes out of same node.

If still that doesn't happen or you want the namenode to leave safe mode then give

hadoop dfsadmin -safemode leave


来源:https://stackoverflow.com/questions/32987760/fi-ware-cosmos-name-node-is-in-safe-mode

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!