Skip to content

Commit 04c9ebd

Browse files
schmallisokay-kim
authored andcommitted
DOCS-11227: use balancerStart/Stop command to start/stop balancer with drivers
1 parent 791159d commit 04c9ebd

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

source/tutorial/manage-sharded-cluster-balancer.txt

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -165,13 +165,13 @@ all migration, use the following procedure:
165165

166166
.. note::
167167

168-
To disable the balancer from a driver that does not have the
169-
:method:`sh.stopBalancer()` or :method:`sh.setBalancerState()` helpers,
170-
issue the following command from the ``config`` database:
168+
To disable the balancer from a driver,
169+
use the :command:`balancerStop` command against the ``admin`` database,
170+
as in the following:
171171

172172
.. code-block:: javascript
173173

174-
db.settings.update( { _id: "balancer" }, { $set : { stopped: true } } , { upsert: true } )
174+
db.adminCommand( { balancerStop: 1 } )
175175

176176
.. _sharding-balancing-re-enable:
177177
.. _sharding-balancing-enable:
@@ -193,12 +193,14 @@ re-enable it:
193193

194194
sh.setBalancerState(true)
195195

196-
From a driver that does not have the :method:`sh.startBalancer()` helper,
197-
issue the following from the ``config`` database:
196+
.. note::
198197

199-
.. code-block:: javascript
198+
To enable the balancer from a driver, use the :command:`balancerStart`
199+
command against the ``admin`` database, as in the following:
200+
201+
.. code-block:: javascript
200202

201-
db.settings.update( { _id: "balancer" }, { $set : { stopped: false } } , { upsert: true } )
203+
db.adminCommand( { balancerStart: 1 } )
202204

203205
Disable Balancing During Backups
204206
--------------------------------

0 commit comments

Comments
 (0)