The best sequence to start a cluster - Shards/Config Servers and MongoS?

So is there a good way to start things?

Start with the shards replica sets / config replica sets/ mongos ?

I started up a replica set shard 27001, and it for instance would complain that it couldn’t connect to 26001/2/3

Or is it just start them all up and they will sort there stuff out? Which to be honest affects my OCD :slight_smile:

So I found this …

  1. Bring up config servers
  2. Bring up mongos

So I assume that the shards would be brought up lastly?

And to shutdown it would the reverse?

Yes. But be careful while doing so.

If you are removing either a shard or replica set, make sure you take the data backup and follow all the necessary steps as it should.

Documentation clearly lists all the steps Topic-wise:

And if you just want to recover a mongod process after an unexpected shutdown, here is the link:


To be honest, it isn’t removing servers/shards. Merely shutting them down in a controlled manner, to prevent any issues.