Problem with rs.stepDown() in Lecture: Setting Up a Replica Set

After I specify rs.stepDown() during Lecture “Setting Up a Replica Set” , I see error message : “No electable secondaries caught up as of 2018-10-24T00:25:47.347+0000Please use the replSetStepDown command with the argument {force: true} to force node to step down.”

Any suggestions?

Are the other nodes up and running?
Are the other nodes actively part of the replica set?
What does rs.status() tell you?

If there are no other nodes actively taking part in the RS, then the primary cannot stepdown.

Thank you for your help! I realize that my nodes had issue with adding to replica set.
Now everything is good.

1 Like