please explain these mongo statistics

Posted by sivann on Super User See other posts from Super User or by sivann
Published on 2012-11-07T13:13:09Z Indexed on 2012/11/19 23:08 UTC
Read the original article Hit count: 187

Filed under:
|

My setup: I have 2 hosts, and 2 shards each.

  • Host1 has 2 shards, and is the master of the replicas
  • host2 has the secondaries of the 2 shards.

.

  • host1: shard1 (repset1),shard2 (repset2)
  • host2: shard1 (repset1),shard2 (repset2)

There's also a 3rd host that acts as arbitrer.

I have 50 threads writing randomly to both shards (using a hash) via mongos with REPLICA_SAFE WriteConcern set on each insert.

The questions:

  1. mongostat displays about 90% locked for both shards in host1 and about 1% locked on host2. Since I use REPLICA_SAFE which supposedly writes to both servers shouldn't the locks be the same?
  2. mongostat reports qr=30 for both shards of host1, and qw=0 always. Since I perform only writes how is this possible? Moreover on host2 all queues are reported 0. Faults are abut the same in all shards/hosts (arround 80).
  3. netIn/netOut on the secondaries (host2) are always about 200bytes/sec. Too low.
  4. mongos has 53 connections, host1's shards have 71 and 71 and host2's shards have 9 and 8. How is this?

Please answer whatever you can. Thanks!

© Super User or respective owner

Related posts about java

Related posts about statistics