分享

hadoop启动报错

pig2 2014-1-9 08:28:41 发表于 问题解答 [显示全部楼层] 回帖奖励 阅读模式 关闭右栏 0 6214
本帖最后由 pig2 于 2014-1-9 08:30 编辑

chaiying0@ubuntu:~$ /home/hadoop/hadoop-0.20.2/bin/start-all.sh
starting namenode, logging to /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-namenode-ubuntu.out
/home/hadoop/hadoop-0.20.2/bin/hadoop-daemon.sh: line 117: /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-namenode-ubuntu.out: Permission denied
head: cannot open `/home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-namenode-ubuntu.out' for reading: No such file or directory
localhost: starting datanode, logging to /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-datanode-ubuntu.out
localhost: /home/hadoop/hadoop-0.20.2/bin/hadoop-daemon.sh: line 117: /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-datanode-ubuntu.out: Permission denied
localhost: head: cannot open `/home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-datanode-ubuntu.out' for reading: No such file or directory
localhost: starting secondarynamenode, logging to /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-secondarynamenode-ubuntu.out
localhost: /home/hadoop/hadoop-0.20.2/bin/hadoop-daemon.sh: line 117: /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-secondarynamenode-ubuntu.out: Permission denied
localhost: head: cannot open `/home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-secondarynamenode-ubuntu.out' for reading: No such file or directory
starting jobtracker, logging to /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-jobtracker-ubuntu.out
/home/hadoop/hadoop-0.20.2/bin/hadoop-daemon.sh: line 117: /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-jobtracker-ubuntu.out: Permission denied
head: cannot open `/home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-jobtracker-ubuntu.out' for reading: No such file or directory
localhost: starting tasktracker, logging to /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-tasktracker-ubuntu.out
localhost: /home/hadoop/hadoop-0.20.2/bin/hadoop-daemon.sh: line 117: /home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-tasktracker-ubuntu.out: Permission denied
localhost: head: cannot open `/home/hadoop/hadoop-0.20.2/bin/../logs/hadoop-chaiying0-tasktracker-ubuntu.out' for reading: No such file or directory


这里面有两个错误,一个是permission denied,另一个是no such file or director
解决办法:
1.no such file or director首先看一下,是否有这个文件,如果没有这属于一个低级错误。如果有的话,可以继续往下看。
2.大多数因为权限问题
当前用户没有打开 hadoop下的logs 文件。可以使用 ls -al 查看一下,logs文件的权限应该不属于当前用户需要使用 sudo chown chaiying0:chaiying0 logs 命令 来赋予当前用户 chaiying0权限。
chaiying0访问hadoop用户下的文件肯定是没有权限的
3.如果上面不行可以尝试格式化:hadoop namenode -format
hadoop namenode -format
格前先删除tmp下面的所有文件,(包括data节点)。

没找到任何评论,期待你打破沉寂

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

推荐上一条 /2 下一条