sh.disableBalancing()
On this page
This version of the documentation is archived and no longer
supported. View the current documentation to learn how to
upgrade your version of MongoDB.
Description
sh.disableBalancing(namespace)
Disables the balancer for the specified sharded collection. This does not affect the balancing of chunks for other sharded collections in the same cluster.
Important
You can only run
sh.disableBalancing()
on amongos
instance.sh.disableBalancing()
errors if run onmongod
instance.The
sh.disableBalancing()
method has the following parameter:ParameterTypeDescriptionnamespace
stringThe namespace of the collection.For more information on the balancing process, see Manage Sharded Cluster Balancer and Sharded Cluster Balancer.