`
朱秋旭
  • 浏览: 228173 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

mongo 启动方式

阅读更多

mongodb 使用命令行启动

 

#bin/mongod

 

--dbpath arg                          directory for datafiles - defaults to /data/db

--logpath arg                         log file to send write to instead of  stdout - has to be a file, not  directory

 

--fork                                fork server process

 

--port arg                            specify port number - 27017 by default

 

也可以使用配置文件

 

-f [ --config ] arg                   configuration file specifying  additional options

 

# vi /data/mongo/mongodb.cnf

dbpath=/data/mongo/

logpath=/data/mongo/mongo.log

logappend=true

fork=true

port=27017

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics