Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Arbiter not accepting connections

(MongoDB version 2.6.3)

I have a replica set: 2 nodes + arbiter. The replica set works with no problems but I am not able to connect to the arbiter:

Failed to connect to myarbiter.com, reason: errno:111 Connection refused
2014-07-16T13:41:59.513+0000 Error: couldn't connect to server myarbiter.com ( myIP), connection attempt failed at src/mongo/shell/mongo.js:148
exception: connect failed

Courios is that I can add & remove the node into my replica set. Connectiong to the secondary or primary, I can see the Arbiter:

"_id" : 2,
"name" : "myarbiter:myport",
"health" : 1,
"state" : 7,
"stateStr" : "ARBITER",
"uptime" : 4,
"lastHeartbeat" : ISODate("2014-07-16T13:25:13Z"),
"lastHeartbeatRecv" : ISODate("2014-07-16T13:25:13Z"),
"pingMs" : 111

if I tail mongod.log (on the Arbiter) I can see

2014-07-16T13:48:15.583+0000 [initandlisten] connection accepted from SOME_IP:SOME_PORT #46 (37 connections now open)
2014-07-16T13:48:15.754+0000 [conn42]  authenticate db: admin { authenticate: 1, user: "MYUSER", nonce: "xxx", key: "xxx" }
2014-07-16T13:48:15.754+0000 [conn42] Failed to authenticate MYUSER@admin with mechanism MONGODB-CR: AuthenticationFailed UserNotFound Could not find user MYUSER@admin
2014-07-16T13:48:15.974+0000 [initandlisten] connection accepted from SOME_IP:SOME_POR #47 (38 connections now open)

With my other replica set, I can always connect to the Arbiter without problem. Any idea what is going on?

Edit: If I remove replica info & remove auth, I can connect to that node without problems. No firewall issues :)

like image 533
Jordi Avatar asked Jul 16 '14 13:07

Jordi


1 Answers

You say you have another replica set running trouble free. Is it running on the exact same MongoDB version as the troublesome one?

MongoDB has an open ticket about arbiter configuration and connection restrictions. It seems there have been some changes recently - you can have a look and see if the information written there is helpful for you: https://jira.mongodb.org/browse/SERVER-5479

like image 54
ederbf Avatar answered Nov 08 '22 04:11

ederbf