What is happening
A healthy replica may supply an identical part. Older source parts may remain long enough to reconstruct a failed merge, but cleanup can remove them. Manual attachment without schema and part-range checks can duplicate data.
ClickHouse recovery
ClickHouse inserts create data parts and background merges create new parts before retiring older ones. Replicated tables coordinate part identity through Keeper, while local metadata and detached parts preserve important recovery context.
Understand the symptom
A healthy replica may supply an identical part. Older source parts may remain long enough to reconstruct a failed merge, but cleanup can remove them. Manual attachment without schema and part-range checks can duplicate data.
What you may see
One part file differs from checksums.txt.
Metadata, marks, columns, or compressed data cannot be read.
One input part or storage path may be damaged.
Required part or mutation state is unavailable.
Protect the source
Freeze merges and detached-part deletion.
Verify block ranges and replica state first.
Copy local and remote parts before repair.
Do this now
Stop inserts, merges, mutations, fetches, and cleanup.
Keep metadata, checksums, marks, and filesystem attributes.
Save replicas, queues, Keeper paths, mutations, and system.part_log.
Preserve every alternate part source.
NEPFOSYS process
NEPFOSYS maps partitions, block ranges, active/detached parts, replicas, and mutations.
Checksums, compressed blocks, columns, marks, and indexes are tested from copies.
Recovered parts are compared for schema, row counts, keys, time ranges, and duplication.
A clear next step
Start a case with the exact symptoms, incident timeline, prior attempts, encryption details, and the files that matter most. NEPFOSYS will route the case to the appropriate DFW intake or nationwide mail-in path.
Start with a case reviewQuestions, answered
Often, if it has the exact part or equivalent covered range.
Not before preserving it and confirming another complete source.
They may contain source data or prior ranges useful for reconstruction.
DFW local · Nationwide mail-in