Mongodb Download Mac Os X

Mac os x 10.11 free download for mac - Mac OS X El Capitan 10.11.6: Yosemite just got bigger, and much more programs. Today we will install MongoDB on Mac OS X. MongoDB is one of the leading NoSQL database. MySql and Oracle are termed as “Relation Databases”, similarly we can say that MongoDB is a “Document Database”. We can store any valid JSON in MongoDB database. MongoDB is open source and written in.

  1. Mongodb Download Mac Os X Download
  2. Mongodb Download Mac Os X 10 11 Download Free
Mongodb

There are numerous posts, manuals and readme articles on installation of MongoDB in Mac OS X. This post documents the steps I went through to install the latest release of MongoDB on my Mac running Mountain Lion 10.8.5 & setting it up to run as a daemon. The steps outlined below closely follow the steps shared by Github user xiaolai in his repository MongoDB-OSX-Launchctl. One of the issue I faced following the steps in his readme was the a Bad file descriptor error raised by launchctl, possibly caused by a mistake I made in the paths of the directories required by MongDB.

To setup MongoDB to run as a daemon, download the latest version of MongoDB and decompress the dowloaded file –

Copy the contents of the folder mongodb-osx-x86_64-2.4.6/bin/ to /opt/local/bin. Alternatively, you can use Mac Ports or Homebrew to install MongoDB. The next steps assume MongoDB binaries are present in /opt/local/bin.

Before you setup MongoDB to run as a daemon, you will need to create a data directory, a directory where log files will be written and a configuration file. Follow the steps below –

You can provide a configuration file to MongoDB or skip the following steps. Read more about the MongoDB configuration here – http://docs.mongodb.org/manual/reference/configuration-options/. A basic MongoDB configuration file (name it mongod.conf) looks like this –

If you have created a configuration file, copy it to the appropriate directory –

Mongodb Download Mac Os X Download

The important step in setting up MongoDB to run as a daemon in Mac OS X is to create a Plist file and use it as a launchctl item. Create a file called org.mongo.mongod.plist with the following contents –

Note that the path to the mongod and the directories created earlier should be correctly specified in the Plist file. Any errors in these program arguments result in errors.

Install the launchctl item like so –

Mongodb Download Mac Os X 10 11 Download Free

Note that launchctl can be setup to run MongoDB with a Plist in /System/Library/LaunchDaemons, however, in my case, /Library/LaunchDaemons worked without any issues. With the release of OS X Mavericks in the horizon, I may need to update the post with any changes in the steps above.