1

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
f_puras
  • 2,521
  • 4
  • 33
  • 38
Aevi
  • 11
  • 3

1 Answers1

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.

Andrew White
  • 52,720
  • 19
  • 113
  • 137