Mongo DB installation
15, September 2012
The following command to install the latest stable version of MongoDB:
$ sudo apt-get install mongodb-10gen
When this command completes, you have successfully installed MongoDB! Continue for configuration and start-up suggestions.
Starting MongoDB
Upstart users can start the mongod process by issuing the following command:
$ sudo service mongodb start
All other users can issue the following command to start mongod:
$ sudo /etc/init.d/mongodb start
You can verify that mongod has started successfully by checking the contents of the log file at /var/log/mongodb/mongodb.log
Stopping MongoDB
Upstart users can stop the mongod process by issuing the following command:
$ sudo service mongodb stop
All other users can issue the following command to stop mongod:
$ sudo /etc/init.d/mongodb stop
Restarting MongoDB
Upstart users can restart the mongod process by issuing the following command:
$ sudo service mongodb restart
All other users can issue the following command to restart mongod:
$ sudo /etc/init.d/mongodb restart
type “mongo” in your terminal to see the version