数据库 - MongoDB ver3.0.12 不支持--fork参数?
淡淡烟草味
淡淡烟草味 2017-05-02 09:22:30
0
1
778

目前只安装了两个版本
3.0.12
3.2.9
发现两个都无法使用--fork参数
报错信息:
Error parsing INI config file: unrecognised option 'fork'
try 'mongod --help' for more information
于是mongod --help之后,列出的一大窜里根本就没有--fork。
是不是现在的版本不支持--fork参数了

淡淡烟草味
淡淡烟草味

reply all(1)
刘奇

I just found a 2.4.5 version, and the --fork parameter cannot be used.

The command --fork only works for Linux/Unix. If you need --fork for
running mongod in background, on Windows that can be achieved by
installing mongod as a service. When use mongod --install option to
install mongodb service, the --dbpath and --logpath are required. In
my case, I need use administrator command console to install the
service.

It seems that windows does not support the --fork parameter. The solution is to use --install to install the windows service.

mongodb.conf file

Start the server under cmd

mongodb.log file

Because direct cmd startup does not have enough permissions, administrator rights are required to open cmd.exe.

cmd administrator rights to start the server

mongodb.log file

Then directly enter net start MongoDB to start the server, and then you can close the window (it is running in the background).

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template