asert failed : unexpected error: Error: stepDown failed: No electable secondaries caught up as of ...The priority settings of replica set members affect both the timing and the outcome of elections for primary. Higher-priority members are more likely to call elections, and are more likely to win.To avoid rollbacks, rs.stepDown(), by default, only steps down the primary if an electable secondary is completely caught up with the primary. The command will wait up to either 10 seconds or the secondaryCatchUpPeriodSecs for a secondary to catch up.
If no electable secondary meets this criterion by the waiting period, the primary does not step down and the method throws an exception.
--
You received this message because you are subscribed to the Google Groups "mongodb-user"
group.
For other MongoDB technical support options, see: https://docs.mongodb.com/manual/support/
---
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mongodb-user+unsubscribe@googlegroups.com.
To post to this group, send email to mongod...@googlegroups.com.
Visit this group at https://groups.google.com/group/mongodb-user.
To view this discussion on the web visit https://groups.google.com/d/msgid/mongodb-user/94cdca35-215a-4b9e-a64a-4976573a1d36%40googlegroups.com.
Hi Victor,
Having a higher priority setting should not have an effect on the rs.stepDown() operation.
Based on the error you initially reported,
assert failed : unexpected error: Error: stepDown failed: No electable secondaries caught up as of ...
the most likely cause is that the Secondary was not yet caught up with the Primary after your upgrade.
As suggested earlier, you should check your Replica Set Status as well as your Replica Set Lag to verify the optime of your Primary and Secondaries next time.
You may also find the following documents useful:
Thanks,
Chris