问题描述,下载mongo后修改配置文件,然后使用/etc/init.d/mongod脚本启动,成功启动,后面发现配置文件bindIp处需要注释,于是重新修改配置文件,这时重启失败,试着关闭后再次start,stop成功而start报了如下错误:
[root@sg_adserver_mongoAli-161.117.199.175:161.117.199.175 ~]#/etc/init.d/mongod start
Starting mongod (via systemctl): Job for mongod.service failed because the control process exited with error code. See "systemctl status mongod.service" and "journalctl -xe" for details.
[FAILED]
之前也遇到过启动脚本不能正常启动的问题,于是采用命令行启动(这里–replSet adntkcpmongo是副本集名称),结果还是报错了
[root@sg_adserver_mongoAli-161.117.199.175:161.117.199.175 ~]#/usr/bin/mongod -f /etc/mongod.conf --replSet adntkcpmongo
about to fork child process, waiting until server is ready for connections.
forked process: 6560
ERROR: child process failed, exited with error number 100
看一下