[SERVER-8260] Sharded Cluster not working when one of the shard is gone Created: 22/Jan/13  Updated: 24/Jan/13  Resolved: 22/Jan/13

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 2.2.0
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: Joseph Chua Assignee: Unassigned
Resolution: Incomplete Votes: 0
Labels: replication, sharding
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

windows 2008 R2


Issue Links:
Related
Participants:

 Description   

I setup a testing environment to test the availability of sharded Mongo cluster. Below is my setup:
1. All the Mongo components are running on the same VM
2. The cluster has 2 shard, A and B. Each shard is a replica set of 3 mongod servers
3. There are three config servers running
4. 1 mongos running

After the above setup is done, a db and a collection of the db are enabled with sharding. Shared collection is then populated with some data. By checking shard status, it is confirmed that both shards carry data in the sharded collection.

Then the following steps are taken for the sharded cluster availability test.
1. perform a select and insert operation on sharded collection. Both operations are successful.
2. Shut down a secondary node of Shard A. Then, perform a select and insert operation on sharded collection. Again both operations are successful.
3. Shut down one more secondary node of Shard A. Then, perform a select and insert operation on sharded collection. This time it fails. The error message from the shell is
"error: {
"$err" : "socket exception [CONNECT_ERROR] for shardA/XXX,XXXXX,XXXXXXX",
"code" : 11002
}"
and it is also found that the remaining node of Shard A was demoted to secondary from primary.

From the result of this test, it looks like the sharded cluster will stop working once any one of the shard in the cluster is gone.

Per Mongo documentation, it is not the expected behavior. Can you point out if there is anything wrong in my setup/steps above?

Thanks



 Comments   
Comment by Joseph Chua [ 24/Jan/13 ]

I did post the same in the forum but get no answer so far. That is why I post the question here...

Comment by Ian Whalen (Inactive) [ 22/Jan/13 ]

HI Joseph, this project is intended for feature requests and bug fixes. For questions like this please create a new discussion in our forum at https://groups.google.com/forum/?fromgroups#!forum/mongodb-user - if the discussion there leads to the conclusion that this should be a feature request or bug ticket, then you should follow up with a ticket here.

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