gpt4 book ai didi

mongodb 2.4.9版本,无法启动mongodb服务

转载 作者:行者123 更新时间:2023-12-04 19:01:09 35 4
gpt4 key购买 nike

我必须根据项目要求安装 mongodb 版本 2.4.9。但是安装后无法启动mongodb服务。错误如下。

systemctl status mongodb.service
● mongodb.service
Loaded: loaded (/etc/init.d/mongodb; bad; vendor preset: enabled)
Active: failed (Result: exit-code) since ဟူး 2018-03-28 22:04:36 +0630; 28s ago
Docs: man:systemd-sysv-generator(8)
Process: 31482 ExecStart=/etc/init.d/mongodb start (code=exited, status=1/FAILURE)
မတ် 28 22:04:36 ubuntu mongodb[31482]: Rather than invoking init scripts through /etc/init.d, use the service(8)
မတ် 28 22:04:36 ubuntu mongodb[31482]: utility, e.g. service mongodb start
မတ် 28 22:04:36 ubuntu mongodb[31482]: initctl: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
မတ် 28 22:04:36 ubuntu mongodb[31482]: Since the script you are attempting to invoke has been converted to an
မတ် 28 22:04:36 ubuntu mongodb[31482]: Upstart job, you may also use the start(8) utility, e.g. start mongodb
မတ် 28 22:04:36 ubuntu mongodb[31482]: start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
မတ် 28 22:04:36 ubuntu systemd[1]: mongodb.service: Control process exited, code=exited status=1
မတ် 28 22:04:36 ubuntu systemd[1]: Failed to start mongodb.service.
မတ် 28 22:04:36 ubuntu systemd[1]: mongodb.service: Unit entered failed state.
မတ် 28 22:04:36 ubuntu systemd[1]: mongodb.service: Failed with result 'exit-code'.

请..

最佳答案

因为sudo -u mongodb /usr/bin/mongod -f /etc/mongodb.conf应该是 mongod 启动,/etc/init.d/monngodb 一定有问题-脚本...

关于mongodb 2.4.9版本,无法启动mongodb服务,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49538903/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com