- Sharding >
- Sharded Cluster Tutorials >
- Troubleshoot Sharded Clusters
Troubleshoot Sharded Clusters¶
On this page
This section describes common strategies for troubleshooting sharded cluster deployments.
Config Database String Error¶
Start all mongos instances in a sharded cluster with an identical
configdb string. If a mongos instance tries to
connect to the sharded cluster with a configdb string that
does not exactly match the string used by the other mongos
instances, including the order of the hosts, the following errors occur:
And:
To solve the issue, restart the mongos with the correct
string.
Cursor Fails Because of Stale Config Data¶
A query returns the following warning when one or more of the
mongos instances has not yet updated its cache of the
cluster’s metadata from the config database:
This warning should not propagate back to your application. The
warning will repeat until all the mongos instances refresh
their caches. To force an instance to refresh its cache, run the
flushRouterConfig command.
Avoid Downtime when Moving Config Servers¶
Use CNAMEs to identify your config servers to the cluster so that you can rename and renumber your config servers without downtime.