有时我可以获得连接,有时会失败
MongoDB shell version: 2.4.3
connecting to: test
Wed Jul 3 13:07:09.878 Socket recv() errno:104 Connection reset by peer 127.0.0.1:27017
Wed Jul 3 13:07:09.878 SocketException: remote: 127.0.0.1:27017 error: 9001 socket exception [1] server [127.0.0.1:27017]
Wed Jul 3 13:07:09.878 DBClientCursor::init call() failed
Wed Jul 3 13:07:09.880 JavaScript execution failed: Error: DBClientBase::findN: transport error: 127.0.0.1:27017 ns: admin.$cmd query: { whatsmyuri: 1 } at src/mongo/shell/mongo.js:L112
exception: connect failed
答案 0 :(得分:7)
我想在MongoDB日志中你会收到这个:
Wed Jul 3 13:07:...因为开放连接太多而拒绝连接:819
尝试执行以下操作:
开始mongod
:
$ mongod
像轰鸣声一样开始mongo:
$ mongo 127.0.0.1:27017