启动Hadoop集群时出错

时间:2012-07-26 15:25:46

标签: java hadoop

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

我收到此错误。 我已经读过许多人得到这个错误,但我还没有找到解决方案。任何人都可以帮忙??

2 个答案:

答案 0 :(得分:3)

创建一个单独的用户 - hduser,始终推荐

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

希望这可以解决问题。

问题与权限有关,而不是hadoop

答案 1 :(得分:0)

以下是2条非常有用的建议:

  1. 最好检查是否设置了HADOOP_HOME和JAVA_HOME .bashrc文件。有时,不设置这些环境变量 启动hadoop集群时也可能导致错误。

  2. 通过浏览日志文件来调试错误也很有用 在/ usr / local / hadoop / logs目录中生成。