Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save heshamelmasry77/52fbc53ba0b8c1e7d4b764428ae59390 to your computer and use it in GitHub Desktop.
Save heshamelmasry77/52fbc53ba0b8c1e7d4b764428ae59390 to your computer and use it in GitHub Desktop.
Uninstall MongoDB on Mac

How to Completely Uninstall MongoDB Community on macOS Catalina

From this post on the IntelliPaat forum.

This guide assumes that MongoDB Community was installed on macOS Catalina using brew install mongodb-community@4.2. Refer to MongoDB Manual: Install on MacOS for installation instructions.

Commands to Uninstall

launchctl list | grep mongo 

launchctl remove homebrew.mxcl.mongodb 

pkill -f mongod 

brew uninstall mongodb-community

Commands to remove settings and data:

  • settings: rm -r /usr/local/etc/mongod.conf
  • logs: rm -r /usr/local/var/log/mongodb
  • data: rm -r /usr/local/var/mongodb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment