Virtual Disk Snapshot and Differencing-Chain Recovery
A disk snapshot or differencing disk stores changes on top of a parent and reads everything else through it. Recovery has to establish which file is the wanted top, which parents it depends on and which ranges each one supplies before the guest disk can be trusted. A VM snapshot is not an independent backup.
- A disk snapshot is a delta over its parent; a VM snapshot may also hold memory and configuration, and none is a backup.
- A missing parent leaves the ranges it supplied unknown, not the whole disk lost; ranges held in a child can still be read.
- VMDK CID and parentCID are consistency fields; a match is necessary for a chain, not proof the parent is unchanged.
- The active top is established from configuration and snapshot metadata, not from the highest file number.
- Boot, consolidation, commit, rebase and repair write; a complete chain is still not proof of a consistent guest.
What a disk snapshot is, and what it is not
A disk snapshot freezes a parent and sends new writes to a child: a delta file, or a differencing disk. A VM snapshot is broader — depending on the platform it can also capture memory state and VM configuration — and not every disk snapshot is a separate file: a QCOW2 internal snapshot is an alternate mapping table inside the same image. In every form, a snapshot depends on the data it was taken from. Losing the base disk, or the storage that holds it, takes the snapshot’s complete view with it, which is why a snapshot is not a backup.
A chain is a layered block map
A differencing or sparse virtual disk maps each guest address through the current file’s own allocation metadata. When the block is not present there, the read falls through to the parent, then to that parent’s parent, back to the base. One guest sector can mean walking several files before its bytes are found. VHDX can make this decision per sector inside a block; QCOW2 per cluster, or per subcluster with extended L2 entries. The format internals are covered in VHDX and QCOW2 Internal Metadata Recovery; this page is about the dependency graph and the choices it forces.
A missing layer leaves ranges unknown
When a parent or an intermediate snapshot is missing, the full guest view can no longer be confirmed. That is not the same as every byte being lost. Blocks present in a later child can still be read from it; what becomes unknown is every range the missing layer supplied, or might have supplied.
Scroll horizontally to see the full table →
| Guest range | Where its newest data lives | With B missing |
|---|---|---|
| Range 1 | Rewritten after C was created, so present in C | Readable from C alone |
| Range 2 | Not present in C; resolved by B’s map, which may hold it or pass it to A or the base | Unknown. A and the base hold older content or the same content, and without B’s map there is no way to tell which |
Filling unknown ranges with zeros, or with bytes from A or the base, produces a disk that looks complete and is not. If such a view is built for analysis, the substituted ranges have to be marked and carried into validation. A file that lies entirely inside readable ranges is not automatically coherent either: its filesystem metadata or the application data it depends on may sit in an unknown range. An older chain that is still intact, such as base → A, is a different recovery point, to be offered as such rather than silently substituted for the latest state.
CID and parentCID are consistency fields, not content hashes
Broadcom describes the VMDK CID as a value in each disk descriptor used for integrity or state tracking; a child’s parentCID has to match its parent’s CID. Its article on the “parent virtual disk has been modified” error lists modifications to the parent, power outages, interrupted migrations, software errors and user actions as ways a mismatch arises.
A CID is not a cryptographic hash of the parent’s content, and a matching pair does not prove the parent is unchanged. A match is a necessary check for the chain, not a sufficient one. parentFileNameHint and similar paths are locators, not identity; timestamps and snapshot suffix numbers are hints. Confirm a candidate parent with its virtual size and geometry, its extent descriptors, the VM configuration and logs, and guest evidence that structures continue correctly across the layers.
Broadcom’s documented remediation edits descriptor CID values, with backups and warnings, to make a production VM usable again. On a chain whose data still has to be recovered, editing the CID to make it open hides exactly the question that needs an answer: whether the parent changed. Similarly, Broadcom’s procedure for recreating a missing descriptor targets a descriptor that points to an existing flat extent; it does not apply to every disk type and not to encrypted disks. A descriptor without its extent is not a usable disk, whatever it still says.
Which file is the active top
The file with the largest number is not necessarily the state anyone needs. Branches (several children of one snapshot), clones, linked clones sharing a base, and configuration left stale after files were moved can all produce more than one plausible top. First decide which state is wanted — the last running state, or a specific snapshot — then establish where the VM configuration and snapshot metadata point and what the logs show about recent snapshot operations. Tools that enumerate a backing chain from a chosen file help, but they describe the chain from that file, not which file should be chosen.
The inventory reaches beyond the VM directory: parents on other datastores, base disks shared by linked clones, raw or externally mapped disks, and the configuration and key material an encrypted disk needs.
Read, attach, consolidate, commit, rebase: what each writes
- Inspect, read and export. Reading descriptors and maps, presenting a read-only guest view and exporting files from it. These are the analysis steps, done on preserved copies.
- Boot, attach and mount. A running guest writes, and attaching a chain can update metadata: the VHDX specification, for example, has an implementation refresh stale parent paths after a chain opens successfully.
- Consolidation. Merges deltas into parents, rewriting parent blocks and removing the historical layers.
- Commit and rebase. In QEMU’s
qemu-img, commit writes the top image’s changes into its base or backing file, can empty the top, and leaves images between them invalid. A safe-mode rebase writes the differing clusters into the image being rebased, not into the new backing file; an unsafe rebase changes only the backing reference. - Repair. A consistency check’s repair mode rewrites metadata, and QEMU warns that the broader repair mode carries a higher risk of choosing the wrong fix or hiding corruption.
Converting or cloning a chain into a new output file does not fix a missing parent and does not prove consistency. With a salvage option, unreadable areas are treated as zeros in the output. QEMU also warns never to modify an image in use, and that forcing a shared read of an image in use can give inconsistent results. Options and versions change these side effects.
A complete chain is not yet a consistent guest
Copying files from a running VM without a coordinated point-in-time capture can mix states and may not produce even a crash-consistent disk view. A coordinated storage snapshot may provide crash consistency, provided it covers every disk and volume the guest depends on; application consistency needs additional guest and application coordination. If booting the guest or letting it replay its filesystem journal is needed to analyse the data, that happens only on a disposable working copy after preservation. Booting is not the first validation step. See Live Systems, Snapshots and Consistent Recovery Copies and Storage Metadata Generations and Consistency.
Validating the result
- The chosen top and recovery point are confirmed and documented, with the reasons.
- Every dependency in the chain is listed with how it was matched.
- The guest view has no unmarked unknown ranges.
- The filesystems, databases and files the owner needs pass their own checks; see How to Validate Recovered Data.
An open VM console or a readable guest partition table is an intermediate result.
Preserve every file the wanted top depends on — inside and outside the VM directory — together with configuration and logs, decide which state is wanted, and do all merges, boots and repairs on copies.
Technical references: Broadcom KB 345254 — CID and parentCID, causes of mismatch · Broadcom KB 321422 — recreating a flat-disk descriptor, its limits · QEMU: qemu-img — commit, rebase, convert, check, shared access. The Broadcom articles cover ESXi 7 and 8 and the Workstation versions they list, and describe operational remediation rather than recovery procedure; the QEMU page is the development (master) documentation, and installed releases may differ.
Related: VHDX and QCOW2 Internal Metadata Recovery · Virtual Machine Disk Corruption · Storage Metadata Generations and Consistency · Sparse, Thin-Provisioned and Virtual Storage Recovery · Recovering Data from Snapshots and Previous Versions · VM, Database and Application-Container Recovery Tools