家釀需要權限的/ usr /本地和因爲沒有其他人使用我的筆記本電腦我一直只是做不能CHOWN在/ usr /地方在OSX自制10.13海伊謝拉
sudo chown -R $(whoami) $(brew --prefix)
但在高塞拉利昂,這給
chown: /usr/local: Operation not permitted
什麼是修復?
家釀需要權限的/ usr /本地和因爲沒有其他人使用我的筆記本電腦我一直只是做不能CHOWN在/ usr /地方在OSX自制10.13海伊謝拉
sudo chown -R $(whoami) $(brew --prefix)
但在高塞拉利昂,這給
chown: /usr/local: Operation not permitted
什麼是修復?
問題保持發生。 ..深入挖掘後,我發現只有卸載Homebrew然後重新安裝它解決了這個問題。
卸載自制:如果您正在使用的zsh 因爲你是從哪裏來的,你可能需要改變你的$ PATH慶典
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
不幸的是,你不能再在高山脈中播放/usr/local
。一種解決方法是sudo mkdir /usr/local/include
和/usr/local/Frameworks
如果它們不存在,並
sudo chown -R $(whoami) $(brew --prefix)/*
感謝ilovezfs這個簡單的解決方法和驚人的自制軟件!
仍然沒有工作。 $ brew update 錯誤:/ usr/local目錄不可寫入。 –
同上。看起來像上次更新的高山... – ruggershawn
嘗試卸載並重新安裝Homebrew:https://stackoverflow.com/questions/46459152/cant-chown-usr-local-for-homebrew-in-osx -10-13-high-sierra – ruggershawn
您不能爲/usr/local
本身變更許可,但你可以改變文件夾下的權利許可,所以這個固定的
sudo chown -R $(whoami) /usr/local/*
獲得同樣的問題仍然是 –
:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"
然後重新安裝。 你應該添加export PATH=$HOME/bin:/usr/local/bin:$PATH
在.zshrc
然後它應該工作,這個問題通過這種方式解決在我的mac。
我就跑這一點,一切都被採取高塞拉利昂護理:
在/ usr/bin中/紅寶石-e 「$(捲曲-fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)」
嘗試禁用System Integrity Protection。從文檔:
System Integrity Protection can be configured using the csrutil(1) command.
You can check whether System Integrity Protection is currently enabled on your system by running the following command in the Terminal:
$ csrutil status
System Integrity Protection status: enabled.
To enable or disable System Integrity Protection, you must boot to Recovery OS and run the csrutil(1) command from the Terminal.
Boot to Recovery OS by restarting your machine and holding down the Command and R keys at startup. Launch Terminal from the Utilities menu. Enter the following command:
$ csrutil enable
After enabling or disabling System Integrity Protection on a machine, a reboot is required.
雖然這可能在理論上回答這個問題,但[這將是更可取的](// meta.stackoverflow.com/q/8259)在這裏包括答案的基本部分,並提供了供參考的鏈接。 –
儘管這個鏈接可能回答這個問題,但最好在這裏包含答案的基本部分,並提供供參考的鏈接。如果鏈接頁面更改,則僅鏈接答案可能會失效。 - [來自評論](/ review/low-quality-posts/18881025) –
我做了這件事,謝謝! –
這是修復「高」Sierra升級後我的自制軟件的唯一方法。 我的錯誤是: 'gh4x-mbpr:〜gh4x $釀造環節混帳 鏈接/usr/local/Cellar/git/2.15.0 ...錯誤:權限被拒絕@ dir_s_mkdir - 在/ usr /本地/ lib' 和 '須藤喬敦 - R的$(WHOAMI)$(BREW --prefix)/ *' 沒有幫助... – gh4x
爲我工作,謝謝! –