-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Affects Version/s: 1.8.3
-
Component/s: Replication, Sharding
-
None
-
Environment:Sharded cluster with three shards, each shard is a replica set consisting of two replicas and one arbiter runnning Ubuntu Linux. The Balancer is turned off.
-
Linux
We and the replica originally defined when adding the shard (with the db.runCommand(
{ addshard : "replicaset/hostname" } ); command) is primary mongos seems to execute a replSetGetStatus for each insert or query it executes.
We are doing several thousands of inserts per second ant this behavior causes a severe performance impact. When switching primarys to a replica discovered by mongos this behavior stops and the performance go back to normal. This behavior is consitent trhougout the cluster on all three shards.
This is an output from mongostat when the primary is the server originally defined when adding the shard in mongos:
insert query update delete getmore command
553 195 0 0 175 1285
This is from mongostat when the other server is primary:
insert query update delete getmore command
607 279 0 0 175 196
Notice the vast difference in command/s.