Sometimes I can get a connection, sometimes it fails
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
I guess that in MongoDB logs you receive this:
Wed Jul 3 13:07:... connection refused because too many open connections: 819
Try to do following:
start mongod
:
$ mongod
start mongo like bellow:
$ mongo 127.0.0.1:27017
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With