Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to upgrade mongodb from 2.0 to 2.2 in mac osx

There are no instructions that I can find on the mongodb website on how to install 2.2 when you already have 2.0 using brew. I can see versions using "brew versions mongodb" but when I try to install one it says "mongodb does not have a version "2.2.0-x86_64" in the Cellar."

The versions command shows:

new-host-4:~ scott$ brew versions mongodb
2.2.0-x86_64 git checkout 34fb67d /usr/local/Library/Formula/mongodb.rb
2.0.7-x86_64 git checkout 6434ebb /usr/local/Library/Formula/mongodb.rb
2.0.6-x86_64 git checkout 2553479 /usr/local/Library/Formula/mongodb.rb
...

I know it's only a few lines of magic but I don't know the proper incantation.

like image 256
Scott Eisenberg Avatar asked Oct 02 '12 03:10

Scott Eisenberg


People also ask

How can I install MongoDB on Mac?

Go to the MongoDB website's download section and download the correct version of MongoDB. Run the Mongo daemon, in one terminal window run ~/mongodb/bin/mongod . This will start the Mongo server. Run the Mongo shell, with the Mongo daemon running in one terminal, type ~/mongodb/bin/mongo in another terminal window.


1 Answers

All I had to do was the following...

$ brew update
$ brew upgrade mongodb
like image 158
Matt Farmer Avatar answered Oct 03 '22 10:10

Matt Farmer