Macos – Homebrew install problems: Permission denied – /Library/Caches/Homebrew/Formula/libksba.brewing

githomebrewmacmacos

I've been having problems installing Homebrew since changing my home username on my Mac OSX 10.6.8 computer. After removing all files from the previous Homebrew installation since that didn't work, I installed it again. When I run brew doctor, it says:

Warning: Suspicious git origin remote found.

With a non-standard origin, Homebrew won't pull updates from
the main repository. The current git origin is:


Unless you have compelling reasons, consider setting the
origin remote to point at the main repository, located at:
  https://github.com/mxcl/homebrew.git

It wouldn't let me install git (I did it with the package installer) and now when I try to run brew install libksba, it says:

Error: Permission denied - /Library/Caches/Homebrew/Formula/libksba.brewing

I've tried doing chown and looking up anything that would help but I'm not finding anything. Any chance anyone knows how to fix this?

Best Answer

Running this command fixed it for me just now (I was having the same problem)

sudo chown -R ${USER} /Library/Caches/Homebrew/
Related Question