- Reference >
- Database Commands >
- replSetStepDown
replSetStepDown¶
-
replSetStepDown
¶ Options: The
replSetStepDown
command forces the primary of the replica set to relinquish its status as primary. This initiates an election for primary. You may specify a number of seconds for the node to avoid election to primary:If you do not specify a value for
<seconds>
,replSetStepDown
will attempt to avoid reelection to primary for 60 seconds.Warning
replSetStepDown
forces all clients currently connected to the database to disconnect. This helps ensure that clients maintain an accurate view of the replica set.New in version 2.0: If there is no secondary, within 10 seconds of the primary,
replSetStepDown
will not succeed to prevent long running elections.