Well, config server is basically used when you go for sharding of data, mean to say , for sharded cluster you require config server. If you use replicaset for the config server it means you are basically improves consistency across the config server.
following restriction apply to a replica set configuration when used for config servers:
- Must have zero arbiters.
- Must have no delayed members.
- must build indexes, it means , no members should have
setting to false
- Standalone and identical mongod servers.
- There are not all created equal (config string passed to mongos). The first config server in the list is important. in 3 node config server, if you lose 1 or 2 config servers, the cluster continues to function. In this case you can't modify any metadata or chunksize, etc in the sharded enviroment.
- Useful Commands on mongos:
db.chunks()on config db,
- It's important to remember that all operations over configs, need to be done through the mongos and not directly.
Availability of Config Server
If config server replica set loses its primary , it this case , can not elect a primary, it means cluster metadata become read-only. You can read and write data from shards , but no chunck migration or chunk split will ocuur until the replic set can elect primary.
Suggestions are welcome to improve this post.