MongoDB出错:ERROR: child process failed, exited with error number 1 To see additional infor
生活随笔
收集整理的這篇文章主要介紹了
MongoDB出错:ERROR: child process failed, exited with error number 1 To see additional infor
小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
linux中安裝mongoDB之后,啟動不了,出現(xiàn)下邊的錯誤,網上搜原因,很多說需要刪除.lock文件,需要bin/mongod --repair修復,但是都不成功,最后發(fā)現(xiàn)是配置文件中路徑問題。
[root@wqd mongodb]# bin/mongod -f single/mongod.conf about to fork child process, waiting until server is ready for connections. forked process: 8962 ERROR: child process failed, exited with error number 1 To see additional information in this output, start without the "--fork" option.
解決:
先用bin/mongod --repair去修復,看一些信息
最重要的是倒數第三句exception in initAndListen: NonExistentPath: Data directory /data/db not found., terminating
配置文件中data/db路徑有問題
修改路徑從根目錄開始"/usr/local/mongodb/single/data/db"
全部配置如下:
再次啟動成功
總結
以上是生活随笔為你收集整理的MongoDB出错:ERROR: child process failed, exited with error number 1 To see additional infor的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: MySQL 笔记9 -- PyMySQ
- 下一篇: Python 数据分析与展示笔记1 --