How to launch MongoDB while our MAC OSX starts 2 comments


How to launch MongoDB while our Mac OSX starts

Launching MongoDB while our MAC starts

Once MongoDB is installed in our MAC OSX, the most useful is to launch the mongod service automatically when our computer is starting.

Steps to follow

These are the steps to follow:

  • We must create the file org.mongodb.mongod.plist at the directory /Library/LaunchDaemons, with this content:

  • Now we load the file

Starting MongoDB manually

If we need to start, or stop, manually the daemon this would be the way:

Creating the alias

Even, we can use aliases by editing the ~/.bash_profile file by this manner:

Interesting links

These are the urls I have read for extracting the information above.

http://www.journaldev.com/2330/how-to-install-mongodb-on-mac-os-x-and-run-as-service

http://stackoverflow.com/questions/5596521/what-is-the-correct-way-to-start-a-mongod-service-on-linux-os-x

https://alicoding.com/how-to-start-mongodb-automatically-when-starting-your-mac-os-x/

I hope you find this post useful!


Leave a comment

Your email address will not be published. Required fields are marked *

seventeen − 2 =

2 thoughts on “How to launch MongoDB while our MAC OSX starts