-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Storage Execution
-
Fully Compatible
-
ALL
-
Execution Team 2024-08-05
-
0
This test fails occasionally in our CI system with the symptom that the unfinished index build is not detected after restarting as a standalone.
Local test runs with additional logging of the replica set status shows that this test fails when the last durable/committed optime has not caught up with the last applied optime:
[js_test:index_build_restart_standalone] [jsTest] Replica set status before shutting down: { [js_test:index_build_restart_standalone] [jsTest] "set" : "index_build_restart_standalone", [js_test:index_build_restart_standalone] [jsTest] "date" : ISODate("2024-07-24T02:06:37.124Z"), [js_test:index_build_restart_standalone] [jsTest] "myState" : 1, [js_test:index_build_restart_standalone] [jsTest] "term" : NumberLong(1), [js_test:index_build_restart_standalone] [jsTest] "syncSourceHost" : "", [js_test:index_build_restart_standalone] [jsTest] "syncSourceId" : -1, [js_test:index_build_restart_standalone] [jsTest] "heartbeatIntervalMillis" : NumberLong(2000), [js_test:index_build_restart_standalone] [jsTest] "majorityVoteCount" : 1, [js_test:index_build_restart_standalone] [jsTest] "writeMajorityCount" : 1, [js_test:index_build_restart_standalone] [jsTest] "votingMembersCount" : 1, [js_test:index_build_restart_standalone] [jsTest] "writableVotingMembersCount" : 1, [js_test:index_build_restart_standalone] [jsTest] "optimes" : { [js_test:index_build_restart_standalone] [jsTest] "lastCommittedOpTime" : { [js_test:index_build_restart_standalone] [jsTest] "ts" : Timestamp(1721786795, 5), [js_test:index_build_restart_standalone] [jsTest] "t" : NumberLong(1) [js_test:index_build_restart_standalone] [jsTest] }, [js_test:index_build_restart_standalone] [jsTest] "lastCommittedWallTime" : ISODate("2024-07-24T02:06:35.689Z"), [js_test:index_build_restart_standalone] [jsTest] "readConcernMajorityOpTime" : { [js_test:index_build_restart_standalone] [jsTest] "ts" : Timestamp(1721786795, 5), [js_test:index_build_restart_standalone] [jsTest] "t" : NumberLong(1) [js_test:index_build_restart_standalone] [jsTest] }, [js_test:index_build_restart_standalone] [jsTest] "appliedOpTime" : { [js_test:index_build_restart_standalone] [jsTest] "ts" : Timestamp(1721786797, 2), [js_test:index_build_restart_standalone] [jsTest] "t" : NumberLong(1) [js_test:index_build_restart_standalone] [jsTest] }, [js_test:index_build_restart_standalone] [jsTest] "durableOpTime" : { [js_test:index_build_restart_standalone] [jsTest] "ts" : Timestamp(1721786795, 5), [js_test:index_build_restart_standalone] [jsTest] "t" : NumberLong(1) [js_test:index_build_restart_standalone] [jsTest] },
One potential solution to "lock" in the index builds into the checkpoint would be to use the LAST_DURABLE option to the ReplSetTest.awaitReplication() call in the test. We have used this option previously in SERVER-34108 (rebuild_multiple_indexes_at_startup.js) and SERVER-36623 (do_not_rebuild_indexes_before_repair.js).
- is related to
-
SERVER-34108 Rebuilding unfinished unindexes one at a time can error
- Closed
-
SERVER-36623 Do not rebuild indexes before repairing databases
- Closed
-
SERVER-57795 index_build_restart_standalone.js should ensure that checkpoints include start of index builds
- Closed