Run MongoDB on Windows: Difference between revisions

From Soma-notes
Created page with "To get MongoDB running on a recent version of Windows (preferably 64-bit): * Download and unzip the current version of [http://www.mongodb.org/downloads MongoDB]. * Unpack thi..."
 
No edit summary
 
Line 4: Line 4:
* Add C:\Program Files\mongodb\bin to your PATH environment variable by going to System->Advanced System Settings->Environment Variables. (System can be accessed by right-clicking on the start menu/start icon.)
* Add C:\Program Files\mongodb\bin to your PATH environment variable by going to System->Advanced System Settings->Environment Variables. (System can be accessed by right-clicking on the start menu/start icon.)
* Create the directory C:\data\db
* Create the directory C:\data\db
* You can run MongoDB now by typing <tt>mongod</tt> at a command prompt.  If you want your databases to be elsewhere, type <tt>mongodb --dbpath /path/to/db</tt>
* You can run MongoDB now by typing <tt>mongod</tt> at a command prompt.  If you want your databases to be elsewhere, type <tt>mongod --dbpath /path/to/db</tt>

Latest revision as of 03:40, 25 January 2014

To get MongoDB running on a recent version of Windows (preferably 64-bit):

  • Download and unzip the current version of MongoDB.
  • Unpack this zip file in your Program Files directory, calling in mongodb.
  • Add C:\Program Files\mongodb\bin to your PATH environment variable by going to System->Advanced System Settings->Environment Variables. (System can be accessed by right-clicking on the start menu/start icon.)
  • Create the directory C:\data\db
  • You can run MongoDB now by typing mongod at a command prompt. If you want your databases to be elsewhere, type mongod --dbpath /path/to/db