brew: brew services do not stop correctly

brew config output

HOMEBREW_VERSION: 3.6.8
ORIGIN: https://github.com/Homebrew/brew.git
HEAD: fa2649dde786208da7d151a89bcafdd23a453f4d
Last commit: 2 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: edbc4965f09e9f82322464d52dd34bde46d50237
Core tap last commit: 3 hours ago
Core tap branch: master
HOMEBREW_PREFIX: /opt/homebrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 8
Homebrew Ruby: 2.6.10 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
CPU: octa-core 64-bit arm_firestorm_icestorm
Clang: 14.0.0 build 1400
Git: 2.37.0 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 7.84.0 => /usr/bin/curl
macOS: 13.0-arm64
CLT: 14.0.0.0.1.1661618636
Xcode: N/A
Rosetta 2: false

brew doctor output

 zhanglei  ~  brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Some installed formulae are deprecated or disabled.
You should find replacements for the following formulae:
  php@7.4

Warning: Unbrewed dylibs were found in /usr/local/lib.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae, and may need to be deleted.

Unexpected dylibs:
  /usr/local/lib/libwkhtmltox.0.12.6.dylib

Warning: Unbrewed header files were found in /usr/local/include.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae, and may need to be deleted.

Unexpected header files:
  /usr/local/include/wkhtmltox/image.h
  /usr/local/include/wkhtmltox/pdf.h

Verification

  • I ran brew update and am still able to reproduce my issue.
  • I have resolved all warnings from brew doctor and that did not fix my problem.

What were you trying to do (and why)?

NONE

What happened (include all command output)?

zhanglei  ~  brew services stop mysql@5.7 Stopping mysql@5.7… (might take a while)

It doesn’t work, and the previous version is normal.

What did you expect to happen?

zhanglei  ~  brew services stop mysql@5.7 Stopping mysql@5.7… (might take a while)

It doesn’t work, and the previous version is normal.

Step-by-step reproduction instructions (by running brew commands)

zhanglei  ~  brew services stop mysql@5.7
Stopping `mysql@5.7`... (might take a while)

It doesn't work, and the previous version is normal.

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 25 (9 by maintainers)

Most upvoted comments

my xcode version 14.1.

yup me too but this happens when we restart our mac and the service has been running before. so after i did the experiment:

  • the service has not been run or “none”
  • I did brew services start httpd
  • and I tried brew service stop httpd : no problem, it works
  • I did again brew services start httpd
  • restart mac
  • and try again brew services stop, and it will take a very long time to stop

I also do:

  • rm -rf ~/Library/LaunchAgents/homebrew.mxcl.httpd.plist
  • restart mac
  • do it again brew services start httpd and brew service stop httpd : it’s work
  • but after I restart again with the service running on login and try to brew service stop httpd it will happen like that too