运行 brew services list 命令有问题
Problem with running brew services list command
我使用自制软件并安装了 'mongodb' 和其他服务,我使用 brew services list
查看我的服务和其他 brew 命令来启动和停止或重新启动它们,但今天我可以执行任何命令当我 运行 brew services list
它给了我这个
Warning: No services available to control with 'brew services'
我知道这是什么意思,但我以前用过这个,今天我遇到了这个问题,我不知道为什么?
我尝试使用 brew update --force
但没有用
简短回答:none 的 Homebrew 安装包公开了服务。
更长的答案,专门针对 MongoDB:MongoDB 已 removed from Homebrew core due to its license. You can install MongoDB with Homebrew using the MongoDB Homebrew tap:
$ brew tap mongodb/brew
$ brew install mongodb-community
$ brew services start mongodb-community
请注意,Homebrew 删除公式似乎并没有停止旧的 mongod
守护进程(尽管它确实从 brew services list
中删除了它,所以你不能 brew services stop
它),因此如果该服务之前是 运行,您需要停止它(例如,使用 ps -x | grep mongo
后跟 kill <pid>
) 然后 启动新服务。
我使用自制软件并安装了 'mongodb' 和其他服务,我使用 brew services list
查看我的服务和其他 brew 命令来启动和停止或重新启动它们,但今天我可以执行任何命令当我 运行 brew services list
它给了我这个
Warning: No services available to control with 'brew services'
我知道这是什么意思,但我以前用过这个,今天我遇到了这个问题,我不知道为什么?
我尝试使用 brew update --force
但没有用
简短回答:none 的 Homebrew 安装包公开了服务。
更长的答案,专门针对 MongoDB:MongoDB 已 removed from Homebrew core due to its license. You can install MongoDB with Homebrew using the MongoDB Homebrew tap:
$ brew tap mongodb/brew
$ brew install mongodb-community
$ brew services start mongodb-community
请注意,Homebrew 删除公式似乎并没有停止旧的 mongod
守护进程(尽管它确实从 brew services list
中删除了它,所以你不能 brew services stop
它),因此如果该服务之前是 运行,您需要停止它(例如,使用 ps -x | grep mongo
后跟 kill <pid>
) 然后 启动新服务。