Navigation
This version of the documentation is archived and no longer supported.

sh.stopBalancer()

On this page

Definition

sh.stopBalancer(timeout, interval)

Disables the balancer in a sharded cluster and waits for balancing to complete.

Important

You can only run sh.stopBalancer() on a mongos instance. sh.stopBalancer() errors if run on mongod instance.

Parameter Type Description
timeout integer Milliseconds to wait.
interval integer Milliseconds to sleep each cycle of waiting.