DBAtlas · Database operations atlas

175 QueryPlanKilled: Query plan killed during execution

MongoDB

What does it mean?

The plan of a running query became invalid because the underlying data/collection changed, and it was killed. The query was aborted because it could not continue safely.

Why does it happen?

While the query was running (especially with an open cursor), the collection was dropped, an index it was using was dropped, or a rename/reconfiguration occurred. Underlying changes during long-running getMore calls are the typical trigger.

How to fix it

Restart the query/cursor (retry). Make sure no destructive DDL (drop, dropIndex, rename) is run on the collection or index while queries are running; schedule such maintenance outside query traffic. Shorten long-running reads and make sure required indexes are permanent.

Open in DBAtlas →

More from this engine