mongodb 安装启动

新建 /usr/local/mongodb/data文件夹,新建文件--logpath=/usr/local/mongodb/logs 

./mongod --port 27017 --fork --dbpath=/usr/local/mongodb/data --logpath=/usr/local/mongodb/logs --logappend

 

about to fork child process, waiting until server is ready for connections.
forked process: 2440
child process started successfully, parent exiting 

查看是否启动netstat -lanp | grep "27017"

 删除rm /tmp/mongodb-27017.sock

就可以了 

posted @ 2016-08-11 16:18  vincent_duan  阅读(158)  评论(0编辑  收藏  举报