Diagnostic step 1
If index build is still running and cluster is degraded, stop accepting writes from the application if possible to let secondaries catch up. This is reversible and limits data churn.
Generated Oct 3, 2026, 12:35:03 AM
If index build is still running and cluster is degraded, stop accepting writes from the application if possible to let secondaries catch up. This is reversible and limits data churn.
Add temporary capacity: bring up an additional secondary (with a larger oplog) to act as a catch-up node or to run the index build there. This avoids impacting existing secondaries.
Consider building the index on a secondary by taking it offline (stop mongod), starting mongod in standalone mode against the data copy, create the index there, then reintroduce it to the set as a secondary so it will replicate less. This requires careful orchestration and backup.
Preemptively increase oplog size on a node before heavy operations (requires planning — create a new larger oplog member and replace an existing one if you cannot resize in-place). Monitor oplog window with rs.printReplicationInfo().
For future maintenance, schedule index builds during a full application quiesce window or perform rolling index builds using newer MongoDB features or by building on secondaries then stepping them up if supported. Escalate to DBA or hosting provider if you cannot provision additional disk or cannot safely resync members.