title: Hadoop start dfs permission denied for "hadoop" user
body: <p>I have setup hadoop on mac local mac. When i start-dfs using the <code>start-dfs.sh</code> command using a separate <code>hadoop</code> user i get the following error in the terminal.</p>
  
  <p><code>0.0.0.0: mkdir: /usr/local/Cellar/hadoop/2.3.0/libexec/logs: Permission denied</code></p>
  
  <p>Does anyone know how i can change the log directory for hadoop? I installed hadoop using homebrew.</p>
  
  <pre><code>bash-3.2$ start-dfs.sh  
  14/03/31 09:04:20 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable  
  Starting namenodes on [localhost]  
  localhost: mkdir: /usr/local/Cellar/hadoop/2.3.0/libexec/logs: Permission denied  
  localhost: chown: /usr/local/Cellar/hadoop/2.3.0/libexec/logs: No such file or directory  
  localhost: starting namenode, logging to /usr/local/Cellar/hadoop/2.3.0/libexec/logs/hadoop-hadoop-namenode-mymac.local.out
  localhost: /usr/local/Cellar/hadoop/2.3.0/libexec/sbin/hadoop-daemon.sh: line 151: /usr/local/Cellar/hadoop/2.3.0/libexec/logs/hadoop-hadoop-namenode-mymac.local.out: No such file or directory  
  localhost: head: /usr/local/Cellar/hadoop/2.3.0/libexec/logs/hadoop-hadoop-namenode-mymac.local.out: No such file or directory
  localhost: /usr/local/Cellar/hadoop/2.3.0/libexec/sbin/hadoop-daemon.sh: line 166: /usr/local/Cellar/hadoop/2.3.0/libexec/logs/hadoop-hadoop-namenode-mymac.local.out: No such file or directory
  localhost: /usr/local/Cellar/hadoop/2.3.0/libexec/sbin/hadoop-daemon.sh: line 167: /usr/local/Cellar/hadoop/2.3.0/libexec/logs/hadoop-hadoop-namenode-mymac.local.out: No such file or directory
  localhost: mkdir: /usr/local/Cellar/hadoop/2.3.0/libexec/logs: Permission denied
  localhost: chown: /usr/local/Cellar/hadoop/2.3.0/libexec/logs: No such file or directory
  </code></pre>