2
votes
chown: changing ownership of `/usr/local/hadoop/libexec/../logs': Operation not permitted
 starting namenode, logging to /usr/local/hadoop/libexec/../logs/hadoop-hadoop-namenode-ayush-PC.out
/usr/local/hadoop/bin/hadoop-daemon.sh: line 135:     /usr/local/hadoop/libexec/../logs/hadoop-hadoop-namenode-ayush-PC.out: Permission denied
head: cannot open `/usr/local/hadoop/libexec/../logs/hadoop-hadoop-namenode-ayush-    PC.out' for reading: No such file or directory
localhost: chown: changing ownership of `/usr/local/hadoop/libexec/../logs': Operation not permitted
localhost: starting datanode, logging to /usr/local/hadoop/libexec/../logs/hadoop-hadoop-datanode-ayush-PC.out
localhost: /usr/local/hadoop/bin/hadoop-daemon.sh: line 135:     /usr/local/hadoop/libexec/../logs/hadoop-hadoop-datanode-ayush-PC.out: Permission denied
localhost: head: cannot open `/usr/local/hadoop/libexec/../logs/hadoop-hadoop-datanode-  ayush-PC.out' for reading: No such file or directory
localhost: chown: changing ownership of `/usr/local/hadoop/libexec/../logs': Operation not permitted
 localhost: starting secondarynamenode, logging to /usr/local/hadoop/libexec/../logs/hadoop-hadoop-secondarynamenode-ayush-PC.out
 localhost: /usr/local/hadoop/bin/hadoop-daemon.sh: line 135: /usr/local/hadoop/libexec/../logs/hadoop-hadoop-secondarynamenode-ayush-PC.out: Permission denied
 localhost: head: cannot open `/usr/local/hadoop/libexec/../logs/hadoop-hadoop-secondarynamenode-ayush-PC.out' for reading: No such file or directory
chown: changing ownership of `/usr/local/hadoop/libexec/../logs': Operation not permitted
 starting jobtracker, logging to /usr/local/hadoop/libexec/../logs/hadoop-hadoop-jobtracker-ayush-PC.out
/usr/local/hadoop/bin/hadoop-daemon.sh: line 135: /usr/local/hadoop/libexec/../logs/hadoop-hadoop-jobtracker-ayush-PC.out: Permission denied
head: cannot open `/usr/local/hadoop/libexec/../logs/hadoop-hadoop-jobtracker-ayush-PC.out' for reading: No such file or directory
 localhost: chown: changing ownership of `/usr/local/hadoop/libexec/../logs': Operation not permitted
localhost: starting tasktracker, logging to /usr/local/hadoop/libexec/../logs/hadoop-hadoop-tasktracker-ayush-PC.out
localhost: /usr/local/hadoop/bin/hadoop-daemon.sh: line 135: /usr/local/hadoop/libexec/../logs/hadoop-hadoop-tasktracker-ayush-PC.out: Permission denied
localhost: head: cannot open `/usr/local/hadoop/libexec/../logs/hadoop-hadoop-tasktracker-ayush-PC.out' for reading: No such file or directory

I am getting this error. I have read that many people get this error but I have not beeen able to find a solution for this. Can anyone help??

2
Does hadoop user have read, write permission in the directory /usr/local/hadoop/?Animesh Raj Jha

2 Answers

3
votes

make a separate user - hduser, always recommened

- do chown -R 755 /usr/local/hadoop
- when creating tmp paths like /app/hadoop/tmp, apply the same settings as above

Hopefully, this will resolve the issue.

The issue is related to permission, not hadoop

0
votes

Below are 2 very helpful suggestions:

  1. It is good to check whether HADOOP_HOME and JAVA_HOME is set in .bashrc file. Sometimes, not setting up these environment variables may also cause error while starting the hadoop cluster.

  2. It is also useful to debug the error by going through the log files generated in /usr/local/hadoop/logs directory.