Brew Install MongoDB. Permission Denied

  

➜ models git:(master) brew install mongodb
==> Downloading https://homebrew.bintray.com/bottles/mongodb-3.0.7.el_capitan.bo
Already downloaded: /Library/Caches/Homebrew/mongodb-3.0.7.el_capitan.bottle.tar.gz
==> Pouring mongodb-3.0.7.el_capitan.bottle.tar.gz
Error: Permission denied - /usr/local/vargit

 

由於是權限的問題,以後brew又本身選擇了進行git clone源碼,而後編譯,實際上是沒有什麼用的,由於/usr/local的權限是沒有的。mongodb

 

解決辦法:api

brew updatethis

 

Error: The /usr/local directory is not writable.
Even if this directory was writable when you installed Homebrew, other
software may change permissions on this directory. Some versions of the
"InstantOn" component of Airfoil are known to do this.component

You should probably change the ownership and permissions of /usr/local
back to your user account.
sudo chown -R $(whoami):admin /usr/localhomebrew

 

 因此只要 sudo chown -R $(whoami):admin /usr/localip

就能夠解決了源碼

相關文章
相關標籤/搜索