Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What version of MongoDB is installed on Ubuntu

Hi I'm a bit of a shell n00b.

Can anyone tell me how I would check the version of MongoDB that is installed on my Linux Ubuntu machine?

I see that my MongoDB shell version: 1.2.2 so Im pretty sure that MongoDB itself is out dated too. And does anyone know of any 'How to update MongoDB' docs? I find mongodb.org to be a bit confusing.

Please and thank you.


Ok if I use db.version() inside of mongo shell it says 1.2.2

If I $ mongod --version I get this:

db version v1.2.2, pdfile version 4.5 Wed Oct 16 10:28:22 git version: nogitversion 

I ran

sudo apt-get update sudo apt-get install mongodb 

and get

sudo apt-get install mongodb Reading package lists... Done Building dependency tree        Reading state information... Done mongodb is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 179 not upgraded.  mongod --version db version v1.2.2, pdfile version 4.5 Wed Oct 16 10:31:07 git version: nogitversion 

So why isn't it updating? Is apt-get pointing at the wrong repo / source?

like image 802
RachelD Avatar asked Oct 16 '13 14:10

RachelD


People also ask

How we can check MongoDB version in Ubuntu?

Using db. To know the MongoDB version, you can also run db. version() command in Mongo Shell.

How do I know if MongoDB is installed?

Open the command prompt and type "cd c:\program files\mongodb\server\your version\bin". After you enter the bin folder type "mongo start". If you get either a successful connection or failed one it means it's installed at least.


1 Answers

inside shell:

$ mongod --version 
like image 86
afghanbloodhound Avatar answered Sep 22 '22 08:09

afghanbloodhound