[SERVER-4447] mongos does not find one replicaset. Works after mogos restart? Created: 07/Dec/11  Updated: 11/Jul/16  Resolved: 10/Apr/12

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 2.0.1
Fix Version/s: 2.1.1

Type: Bug Priority: Major - P3
Reporter: Anders Karlsson Assignee: Spencer Brody (Inactive)
Resolution: Done Votes: 0
Labels: mongos, replicaset, sharding
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Ubuntu Linux 11.04, Amazon EC2,


Operating System: Linux
Participants:

 Description   

Setting up a new shard cluster consisting of 6 shards, each a replicaset. Five of the 6 shards were added OK by mongos, but the last one would not work. The mongos logfile said this;
<quote>
Wed Dec 7 12:42:18 [conn23] addshard request

{ addshard: "replset5/mon-8088.recfut.net:27019,mon-8089.recfut.net:27019" }

failed: couldn't
connect to new shard mongos connectionpool: connect failed replset5/mon-8088.recfut.net:27019,mon-8089.recfut.net:27019 : connect failed to
set replset5/<node7>:27019,<node8>:27019
</quote>
There was nothing in the mongod logfiles on node7/node8 nor in the mongoc log. The replicaset could be connected to from the commandline:
<quote>
$ mongo --host replset5/<node7>:27019,<node8>:27019

The fix was to restart mongos.

The replicaset had probably been attemped to be added earlier, and failed because the replicaset was not yet live.



 Comments   
Comment by auto [ 09/Apr/12 ]

Author:

{u'login': u'stbrody', u'name': u'Spencer T Brody', u'email': u'spencer@10gen.com'}

Message: Clean up ReplicaSetMonitor after failed addShard command. SERVER-4447.
Branch: master
https://github.com/mongodb/mongo/commit/ee33c0b90fd74c0c3c48e2437648b1c2f3339dc5

Generated at Thu Feb 08 03:06:01 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.