MongoDB Error 43 CursorNotFound (10-Minute Idle Cursor Timeout)

Slow batch loop paused >10 minutes between `getMore` fetches, expiring the server cursor.

Runs locally in browser Free · No login Independently Verified 2026-11-25 v4.1.0
Identifier: MongoDB Error 43 CursorNotFound (10-Minute Idle Cursor Timeout) Platform: MongoDB
Common Root Causes:
  • Slow batch loop paused >10 minutes between `getMore` fetches, expiring the server cursor.

Interactive Diagnostic Checklist

Verified Solutions:
  1. Use keyset pagination (`_id > lastId` with `limit`) instead of holding long-lived cursors.
Safe Diagnostic Command:
Check batch processing loop duration
Warning: Verify configuration changes in staging or with dry-run flags (e.g. nginx -t) before reloading production services.

Technical Explanation

Slow batch loop paused >10 minutes between `getMore` fetches, expiring the server cursor. Recommended diagnostic: `Check batch processing loop duration`. Remediation: Use keyset pagination (`_id > lastId` with `limit`) instead of holding long-lived cursors.

Worked Examples

  • Run `Check batch processing loop duration` to verify root cause before applying the remediation.

Limitations & Assumptions

  • Always verify configuration changes in staging or with dry-run flags (e.g. `nginx -t`) before reloading production services.

Source References & Verification

Resource ID: err-mongodb-cursor-not-found-43 · Independently verified: 2026-11-25

Related Resources