2
$ /usr/local/hadoop/sbin/start-all.sh
This script is Deprecated. Instead use start-dfs.sh and start-yarn.sh 
Starting namenodes on [localhost] 
divyeshlad@localhost's password:  
localhost: starting namenode, logging to /usr/local/hadoop/logs/hadoop-divyeshlad-namenode-divyeshlad-VirtualBox.out
localhost: chown: changing ownership of '/usr/local/hadoop/logs': Operation not permitted
localhost: /usr/local/hadoop/sbin/hadoop-daemon.sh: line 159: /usr/local/hadoop/logs/hadoop-divyeshlad-namenode-divyeshlad-VirtualBox.out: Permission denied
localhost: head: cannot open '/usr/local/hadoop/logs/hadoop-divyeshlad-namenode-divyeshlad-VirtualBox.out' for reading: No such file or directory
localhost: /usr/local/hadoop/sbin/hadoop-daemon.sh: line 177: /usr/local/hadoop/logs/hadoop-divyeshlad-namenode-divyeshlad-VirtualBox.out: Permission denied
localhost: /usr/local/hadoop/sbin/hadoop-daemon.sh: line 178: /usr/local/hadoop/logs/hadoop-divyeshlad-namenode-divyeshlad-VirtualBox.out: Permission denied
Thomas
  • 6,223
curious
  • 33
  • thanks @Thomas that helped i logged in as chown -R divyeshlad /usr/local/hadoop and namenode is now running. – curious Aug 20 '16 at 15:47

1 Answers1

2

Well, first the script tells you that it is deprecated and you should use the scripts start-dfs.sh and start-yarn.sh.

Second, you are starting the services as user divyeshlad, who does not have write permissions in /usr/local/hadoop/logs.

So either start the services as root or chown -R divyeshlad /usr/local/hadoop/logs.
Not sure if the latter one will work as I do not know if Hadoop needs root rights for running.

Thomas
  • 6,223