I have upgraded MongodDB sharded cluster having two replica sets from 3.2 to 3.4. Current storage engine is MMAPv1. After successfully upgrading all the secondary, primary, config server and mongos to 3.4, when I run config server using following command.

sudo mongod --configsvr

I keep getting following Error.

SHARDING [shard registry reload] Periodic reload of shard registry failed :: caused by :: 115 could not get updated shard list from config server due to Current storage engine does not support majority readConcerns; will retry after 30s

And also I am unable to connect mongos with config server. When I try to connect it using following command

sudo mongos --configdb [ip-of-my-config-server]:27019

It gives me following error.

BadValue: configdb supports only replica set connection string

I suppose mongos is unable to connect to config server due to the majority readConcerns error on config server.

MongoDB manual says "When reading from the replica set config servers, MongoDB 3.4 uses a Read Concern level of "majority"."

And to use a read concern level of "majority", WiredTiger must be used as storage engine.

So it seems I have to switch to WiredTiger storage engine to make it work. But when I was going to switch to WiredTiger storage engine of a secondary replica set member, according to manual

"This procedure completely removes a secondary replica set member’s data"

So I am stuck halfway. Situation is

  1. Config server is giving error regarding majority readConcerns.
  2. I have to switch to WiredTiger to get rid of it.
  3. Switching to WiredTiger will remove data from secondary members.
  4. Data will not be replicated back to secondary members during this switching to WiredTiger procedure because of config server error and eventually I will be ended up losing all the data (Please correct if I am wrong).

Questions are:

  1. Can I make MongoDB 3.4 to use a Read Concern level of "local" when reading from the replica set config servers?
  2. How can I switch to WiredTiger engine without losing data in my scenario?

1 Answer 1


Problem seems to be that mongodb 3.4 requires that config server is replica set (CSRS) and not old type single node config server. So you need to initialize your config server as replica set and then start it with --replSet parameter.

Please check here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.