Win7 install MongoDB system environment: win7 64-bit Database: mongodb-win32-i386-v2.4 the first step of course is to download http://www.mongodb.org/downloadsstep 2 unzip the mongodb-win32-i386-v2.4-latest.zip such as unzip to D: \ installsofts \ MongoDB step 3 set the environment variable to set $ MongoDB \ bin to the system environment variable path Step 4: configure the configuration file to create the file Mongo. for example, enter the following content in the Directory D: \ installsofts \ MongoDB.
# Store data here defines a data folder to store data Dbpath = D: \ devsofts \ Dynamic Data # All output go here defines a location for storing log files Logpath = D: \ devsofts \ mongolog \ Mongo. Log # Log read and write operations Diaglog = 3
If these paths are not specified, they will be under drive C, which is obviously not well managed. Step 5: Install and start MongoDB server. Use D: \ installsofts \ MongoDB \ bin> mongod.exe -- config D: \ installsofts \ MongoDB \ Mongo under cmd. config -- install ..... sat Jun 08 17:26:10. 713 service can be started from the command line with 'net start MongoDB 'and then start the service: D: \ installsofts \ MongoDB \ bin> Net start mongodbmongo dB is starting. the Mongo dB service has been started successfully. Step 6: D: \ installsofts \ MongoDB \ bin> Mongo log on to the MongoDB shell environment to close the service: net stop MongoDB Delete service: D: \ installsofts \ MongoDB \ bin> mongod.exe -- remove when we are viewing the data and log directories, new files are generated.