On this page本页内容
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.这不会影响同一集群中其他分片集合的块平衡。
You can only run 只能在sh.disableBalancing()
on a mongos
instance. mongos
实例上运行sh.disableBalancing()
。如果在sh.disableBalancing()
errors if run on mongod
instance.mongod
实例上运行sh.disableBalancing()
,则它将出错。
The sh.disableBalancing()
method has the following parameter:sh.disableBalancing()
方法具有以下参数:
namespace | string | The namespace of the collection. |
For more information on the balancing process, see Manage Sharded Cluster Balancer and Sharded Cluster Balancer.有关平衡过程的更多信息,请参阅管理分片群集平衡器和分片群集平衡器。