FULL AI ANALYSIS

Vector DB returns deleted documents and stale IDs after nightly compaction and shard rebalance

Generated Oct 26, 2026, 9:23:15 AM

Analysis summary

Symptoms are consistent with an index/metadata inconsistency: compaction or shard rebalancer left stale pointers to segments that should have been tombstoned, so deleted vectors remain searchable. A race between delete/tombstone application and compaction/rebalance can leave orphaned vector references. Less likely causes include client-side caching or storage-level corruption, but the cluster-wide recurrence after the maintenance window points at the compaction/rebalance pipeline.

Possible causes

Compaction or shard-rebalance bug that leaves stale segment pointers or fails to apply tombstones across target nodes

85%

Race between ingestion delete operations and compaction leading to incomplete tombstone propagation

60%

Client-side query cache returning stale IDs even after backend fixed state

30%

Underlying storage corruption or filesystem-level inconsistencies on one or more shard nodes

15%

Suggested fixes

1

Diagnostic step 1

Immediately pause scheduled compaction and shard-rebalance jobs and stop ingestion to prevent further divergence.

2

Diagnostic step 2

Take consistent snapshots/backups of current index files and metadata from all nodes for forensic analysis before further changes.

3

Diagnostic step 3

Perform a full reindex of the affected collections: rebuild indexes from the authoritative document store into a clean cluster or into a new index namespace, then switch traffic to the rebuilt index after validating results.

4

Diagnostic step 4

If full reindex is not feasible immediately, run targeted reindexing for all shards that returned stale results and validate queries against source store.

5

Diagnostic step 5

Report the issue to the vector DB project/vendor with compaction/rebalance logs and include checksums of metadata to help identify a product bug; plan to upgrade if a fix is available.