我安装了全新的hadoop 2.9设置,一切似乎都没问题。但是,只有一个错误,我无法通过。当我执行命令
时start-dfs.sh
我得到以下错误:
localhost: mkdir: cannot create directory ‘//logs’: Permission denied
localhost: chown: cannot access '//logs': No such file or directory
localhost: starting namenode, logging to //logs/hadoop-amitesh-namenode-amitesh-VirtualBox.out
localhost: /usr/local/hadoop/hadoop-2.9.0/sbin/hadoop-daemon.sh: line 159: //logs/hadoop-amitesh-namenode-amitesh-VirtualBox.out: No such file or directory
localhost: head: cannot open '//logs/hadoop-amitesh-namenode-amitesh-VirtualBox.out' for reading: No such file or directory
localhost: /usr/local/hadoop/hadoop-2.9.0/sbin/hadoop-daemon.sh: line 177: //logs/hadoop-amitesh-namenode-amitesh-VirtualBox.out: No such file or directory
localhost: /usr/local/hadoop/hadoop-2.9.0/sbin/hadoop-daemon.sh: line 178: //logs/hadoop-amitesh-namenode-amitesh-VirtualBox.out: No such file or directory
有2个观察结果:
1)The error says //logs. However, ideally the path should had been /usr/local/hadoop/hadoop-2.9.0. Not sure about it
2) By being sudo, I gave chown -R amitesh:amitesh hadoop.
However, the top 2 directories "usr" and "local" still has root ownership:group.
有什么建议吗?我确实在stackoverflow上看到了一些其他文章,但它们对我的情况没有帮助。