Strange homebrew error

I ran brew update and then brew upgrade. It looks like it completed. When I went to run brew update as a doublecheck. terminal gave me ‘Killed: 9’. Has anybody seen this before? Even stranger, any commandline gives me the same error. I quit iterm2 and re-opened iterm2 and it seems ok now.

I haven’t seen that error.
I would try brew doctor and see if it finds anything.

Ran brew doctor and there were no issues. might have to wait to see if it happens again. Thanks for the suggestion.

This can be a problem with gatekeeper/code signing. Sometimes it just fixes itself with a terminal restart/fresh session, as in your case. If not, you would probably try a reinstall next, and then start googling for what people are doing to solve it on your macOS version. :slightly_frowning_face:

This is the probable explanation:

If you replace a signed macOS binary by using cp instead of mv then macOS caches the signature, doesn’t like the look of it because the file changed and kills your process when you try and start the new binary. Clearly, this is a bug in macOS. We had to update our install scripts to copy the file a different way.

1 Like

Wow thanks. I’m guessing that’s the way that brew upgrade works. terminal restart is the way to go. Thanks for helping!

You’re welcome!

I’m not sure how the sausage is made, but homebrew is a great package manager. I use it on Linux too.

Agreed. It makes it a lot easier for me to install on a fresh computer and do the upgrade/update.