[SERVER-3605] After node is restarted it may not be set to ok state in mongos Created: 15/Aug/11  Updated: 11/Jul/16  Resolved: 16/Aug/11

Status: Closed
Project: Core Server
Component/s: Replication, Sharding
Affects Version/s: 2.0.0-rc0
Fix Version/s: 1.8.4, 2.0.0-rc0

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

Issue Links:
Depends
Operating System: ALL
Participants:

 Description   

Sometimes a node can go down and come back up, without being its 'ok' flag in the _nodes array being set to true. If this node becomes the primary, this causes the replSetGetStatus command to be run on every operation as the mongos keeps thinking its connection to the primary is down and re-checks it.



 Comments   
Comment by auto [ 15/Sep/11 ]

Author:

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

Message: Fix mongos skipping checking the health of the first node in the _nodes array
in the replica set monitor. SERVER-3605
Branch: v1.8
https://github.com/mongodb/mongo/commit/652f407b4b194bd98c1f59fb93f3a1b014ff9bb6

Comment by auto [ 15/Aug/11 ]

Author:

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

Message: Fix mongos skipping checking the health of the first node in the _nodes array
in the replica set monitor. SERVER-3605
Branch: master
https://github.com/mongodb/mongo/commit/861bc071b86f03816beb7e63e65f242d4cf504c4

Comment by Spencer Brody (Inactive) [ 15/Aug/11 ]

The bug is in the _checkStatus method in client/dbclient_rs.cpp. The code accidentally skips checking the health of the first element in the _nodes array.

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