[SERVER-57301] Wait and set 'secondaryOk' after recipientSet restart in tenant_migration_recipient_resume_on_stepup_and_restart.js Created: 28/May/21  Updated: 29/Oct/23  Resolved: 02/Jun/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.0.0-rc1, 5.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Wenbin Zhu Assignee: Wenbin Zhu
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.0, v4.9
Participants:
Linked BF Score: 25

 Description   

After the tenant_migration_recipient_resume_on_stepup_and_restart.js restarts the recipientRst, the node instance is recreated and `secondaryOk` is not set on the node, thus when calling waitForMigrationGarbageCollection, which does the collection count on each node including secondaries, the call fails on a secondary with NotPrimaryNoSecondaryOk. After restarting replset, we usually call awaitSecondaryNodes() and getPrimary() to wait for election to finish and all nodes in their desired state, and this also sets `secondaryOk`.



 Comments   
Comment by Vivian Ge (Inactive) [ 06/Oct/21 ]

Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you!

Comment by Githook User [ 07/Jun/21 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-57301 Wait and set 'secondaryOk' after recipientSet restart in tenant_migration_recipient_resume_on_stepup_and_restart.js

(cherry picked from commit af1405bc804add82c458913c0f5955ca1917b999)
Branch: v5.0
https://github.com/mongodb/mongo/commit/24e3e049a9c2690330089fa581f72e370f24163a

Comment by Githook User [ 02/Jun/21 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-57301 Wait and set 'secondaryOk' after recipientSet restart in tenant_migration_recipient_resume_on_stepup_and_restart.js
Branch: master
https://github.com/mongodb/mongo/commit/af1405bc804add82c458913c0f5955ca1917b999

Generated at Thu Feb 08 05:41:30 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.