I am trying to format namenode in hdfs but says: permission denied

爱⌒轻易说出口 提交于 2020-01-06 01:35:59

问题


I am trying to format namenode . For this I have tried.

hduser@Ubuntu:/usr/hadoop/hadoop-2.7.1$ bin/hdfs namenode -format

It says:

bin/hdfs: line 304: /root/software/jdk1.8.0_45/bin/java: Permission denied
bin/hdfs: line 304: exec: /root/software/jdk1.8.0_45/bin/java: cannot execute: Permission denied

回答1:


So, you have an odd install. It looks like you are trying to reference a JDK installation that is installed to /root (this is very unusual). You are getting permission denied because you are trying to run a command as a non-privileged that depends on that JDK installation that your user can't access.

Running as root would probably make this error go away but you probably have an unorthodox installation that might need to be reconsidered.



来源:https://stackoverflow.com/questions/31753915/i-am-trying-to-format-namenode-in-hdfs-but-says-permission-denied

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