Unpack the installation package to D:\Program Files\mongodb
Create database directory D:\Program Files\mongodb\data
Create log directory D:\Program Files\mongodb\logs
Create profile directory D:\Program files\mongodb\etc
Setting up the configuration file D:\Program files\mongodb\etc\mongodb.conf
The contents are as follows:
Dbpath=D:\Program files\mongodb\data #数据库路径logpath=D:\Program Files\mongodb\logs\mongodb.log # Log output file path logappend=true #错误日志采用追加模式, after configuring this option, the MongoDB log is appended to the existing log file instead of creating a new file Journal= True #启用日志文件, quiet=true #这个选项可以过滤掉一些无用的日志信息 is enabled by default, set to Falseport = 27017 if required for debug use #端口号 defaults to 27017
Normal Startup
Mongod--config D:\Program files\mongodb\etc\mongodb.conf
Add to Windows Service
" \ "D:\Program files\mongodb\bin\mongod.exe\"--service--config=\ "D:\Program files\mongodb\etc\mongodb.conf\" "MongoDB 2.6Standard""auto"
Note: There are spaces after the binpath equals sign, and no spaces after the--config equals sign \ "
When a log file is specified, the log is output to the specified log file, regardless of whether the configuration file is specified or specified on the command line, and no log output is visible at the command line interface
http://localhost:27017/
Mongod Graphical Tools Mongovue
Windows installation configuration MongoDB and graphics tools Mongovue