在成功创建name节点之后,我在尝试启动name节点时遇到了这个问题。对我来说,它似乎试图登录到一个不存在的文件。如何更改设置以将脚本日志定向到正确的目录?
bash-3.2$ start-all.sh
starting namenode, logging to /usr/local/bin/../logs/hadoop-Yili-namenode-wifi169-
116.bucknell.edu.out
nice: /usr/local/bin/../bin/hadoop: No such file or directory
localhost: starting datanode, logging to /usr/local/bin/../logs/hadoop-Yili-datanode-
wifi169-116.bucknell.edu.out
localhost: nice: /usr/local/bin/../bin/hadoop: No such file or directory
localhost: starting secondarynamenode, logging to /usr/local/bin/../logs/hadoop-Yili-
secondarynamenode-wifi169-116.bucknell.edu.out
localhost: nice: /usr/local/bin/../bin/hadoop: No such file or directory
starting jobtracker, logging to /usr/local/bin/../logs/hadoop-Yili-jobtracker-wifi169-
116.bucknell.edu.out
nice: /usr/local/bin/../bin/hadoop: No such file or directory
localhost: starting tasktracker, logging to /usr/local/bin/../logs/hadoop-Yili-
tasktracker-wifi169-116.bucknell.edu.out
localhost: nice: /usr/local/bin/../bin/hadoop: No such file or directory
1条答案
按热度按时间f2uvfpb91#
试着跑
which hadoop
. 如果这个命令给您一个输出,那么您的hadoop\u home已经设置在.bashrc文件中。如果未设置,则编辑主目录中的.bashrc文件,并添加以下语句,因为您的hadoop已安装在
/opt/hadoop
. 可能是另一个地方。这对你有帮助。