gpt4 book ai didi

mongodb无法启动

转载 作者:IT老高 更新时间:2023-10-28 13:06:21 25 4
gpt4 key购买 nike

今天我更新了我的 Mongo.. mongodb-stable(来自 10gen repo)

但是我的服务已经停止了。以下命令不起作用

$ sudo service mongodb start
$ start: Unknown job: mongodb

即使这个命令也不起作用

$ sudo /etc/init.d/mongodb start
$ Rather than invoking init scripts through /etc/init.d, use the service(8)
utility, e.g. service mongodb start
Since the script you are attempting to invoke has been converted to an
Upstart job, you may also use the start(8) utility, e.g. start mongodb
start: Unknown job: mongodb

没有运行mongo进程

$ ps -ef|grep mongo
$ user 9689 8121 0 13:01 pts/1 00:00:00 grep --color=auto mongo

日志在这里

tail /var/log/mongodb/mongodb.log 
Fri Dec 10 11:24:35 [conn4] end connection 127.0.0.1:54217
Fri Dec 10 11:25:35 [initandlisten] connection accepted from 127.0.0.1:54229 #5
Fri Dec 10 11:26:25 [initandlisten] connection accepted from 127.0.0.1:54243 #6
Fri Dec 10 11:26:30 [conn6] end connection 127.0.0.1:54243
Fri Dec 10 11:30:13 got kill or ctrl c or hup signal 15 (Terminated), will terminate after current cmd ends
Fri Dec 10 11:30:13 [interruptThread] now exiting
Fri Dec 10 11:30:13 dbexit:

Fri Dec 10 11:30:13 [interruptThread] shutdown: going to close listening sockets...
Fri Dec 10 11:30:13 [interruptThread] closing listening socket: 5
Fri Dec 10 11:30:13 [interruptThread] closing listening socket: 6
Fri Dec 10 11:30:13 [interruptThread] closing listening socket: 7
Fri Dec 10 11:30:13 [interruptThread] closing listening socket: 8
Fri Dec 10 11:30:13 [interruptThread] shutdown: going to flush oplog...
Fri Dec 10 11:30:13 [interruptThread] shutdown: going to close sockets...
Fri Dec 10 11:30:13 [interruptThread] shutdown: waiting for fs preallocator...
Fri Dec 10 11:30:13 [interruptThread] shutdown: closing all files...
Fri Dec 10 11:30:13 closeAllFiles() finished

Fri Dec 10 11:30:13 [interruptThread] shutdown: removing fs lock...
Fri Dec 10 11:30:13 dbexit: really exiting now

目前,我只是通过这个命令运行 Mongo,手动创建进程

$ sudo mongod -f /etc/mongodb.conf

有什么想法吗?还是有人通过更新管理器更新了 Mongo-stable?

编辑:

这个 mongodb 版本是 v1.6.5,看来 mongo 团队发布了它是稳定的,但有一个错误。他们立即将其修复为 v1.7.4。你可以看到major priority issue .

最佳答案

已报告并修复错误。

https://jira.mongodb.org/browse/SERVER-2200

$ sudo apt-get purge mongodb-stable $ sudo apt-get install mongodb-stable (remove the lock file if present in /var/lib/mongodb)  $ sudo init 6 

然后编辑/etc/init/mongodb.conf删除“限制 nofile 20000”行

$ sudo vi /etc/init/mongodb.conf $ sudo service mongodb startmongodb start/running, process 2351

工作。

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

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