HiveBrain v1.2.0
Get Started
← Back to all entries
debugMinor

Error while accessing remote MongoDB

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
errorwhilemongodbremoteaccessing

Problem

Trying to access remote MongoDB. Got the following error:

C:\Users\ranjj_000>mongo :28017

MongoDB shell version: 2.6.0
connecting to: 111.93.128.60:28017/test
2014-04-22T12:19:45.084+0530 Socket recv() errno:10054 An existing connection was     forcibly closed by the remote host. 111.93.128.60:28017
2014-04-22T12:19:45.087+0530 SocketException: remote: :28017 error: 9001 socket exception [RECV_ERROR] server [:28017]
2014-04-22T12:19:45.088+0530 DBClientCursor::init call() failed
2014-04-22T12:19:45.093+0530 Error: DBClientBase::findN: transport error: 111.93.128.60:28017 ns: admin.$cmd query: { whatsmyuri: 1 } at src/mongo/shell/mongo.js:148


exception: connect failed

Server is: CentOS release 6.4 (Final)

Solution

Port 28017 is usually the HTTP Console interface, not the port you should be using to connect via the shell. Change the port to 27017 instead and retry.

Context

StackExchange Database Administrators Q#63627, answer score: 3

Revisions (0)

No revisions yet.