MongoDB only three of four shards being used Using MongoDB 2.6, I've setup four replication sets: a, b, c &amp; d:

>rs.conf()

a:PRIMARY&gt; rs.conf()
{
    "_id" : "name_of_replset",
    "version" : 1,
    "members" : [
        {
            "_id" : 0,
            "host" : "fedora_cje:port_number"
        },
        {
            "_id" : 1,
            "host" : "fedora_cje:port_number"
        },
        {
            "_id" : 2,
            "host" : "fedora_cje:port_number"
        }
    ]
}


Those replication sets have been added to shards

>sh.status()

 shards:
    {  "_id" : "a",  "host" : "a/fedora_cje:27000,fedora_cje:27001,fedora_cje:27002" }
    {  "_id" : "b",  "host" : "b/fedora_cje:27100,fedora_cje:27101,fedora_cje:27102" }
    {  "_id" : "c",  "host" : "c/fedora_cje:27200,fedora_cje:27201,fedora_cje:27202" }
    {  "_id" : "d",  "host" : "d/fedora_cje:27300,fedora_cje:27301,fedora_cje:27302" }


At the bottom of sh.status(), I am seeing this message

{  "_id" : "test",  "partitioned" : false,  "primary" : "d" }
{  "_id" : "test_collection",  "partitioned" : false,  "primary" : "d" }


but test and test_collection don't exist in the test_cluster database.

Inserting records, the fourth replication set and fourth shard are apparently ignored.

test_cluster.test_cluster_collection.stats()

"nchunks" : 3,
"shards" : {
    "a" : {...
    "b" : {...
    "c" : {


Notice also that the number of chunks remains at 3.

I am using the default /etc/mongod.conf file.

This is the insert statement being used:

&gt;use test_cluster
&gt;t=db.test_cluster.test_sharded_collection
&gt;for( var i=0; i &lt; 20000; i++ ){t.insert( { x:i,y:3,z:"test                       test" } )}


Question: Why is the fourth replication set and consequently the fourth shard being ignored during inserts?
There are a few confusing pieces here, first you list this piece of sh.status():

{  "_id" : "test",  "partitioned" : false,  "primary" : "d" }
{  "_id" : "test_collection",  "partitioned" : false,  "primary" : "d" }


That means that there is a test database, a test_collection database, not collections.  It also indicates that neither of them are sharded - that is what "partitioned" : false means.  

You then show some output from test_cluster.test_cluster_collection.stats() but that is not one of the databases from the sh.status command.  It is a collection from the test_cluster database, and there is no indication of how that is sharded, though it would be listed in sh.status().  Basically the two pieces of information have nothing to do with each other.

Your for loop will also be inserting into the test_sharded_collection as a sub-collection of test_cluster.  In other words, the full namespace you are inserting into is test_cluster.test_cluster.test_sharded_collection, and I suspect that is not sharded which is why you are likely not seeing the chunks increase.  What I suspect you intended to do was insert into test_cluster.test_sharded_collection.  Try this for your inserts instead:

use test_cluster;
for( var i=0; i &lt; 20000; i++ ){db.test_sharded_collection.insert( { x:i,y:3,z:"test                       test" } )};


The full output of sh.status(), and specifically the section about the test_sharded_collection would help me confirm my suspicions.