Pcornel
Virtualization · Virtual Storage

VHD / VHDX

Cheat sheet · https://pcornel.dk/topic.php?topic=3511

Back to the Topic

Answer

VHD and VHDX are Microsoft virtual hard disk image formats; VHDX is the newer format with larger-capacity and resilience/features compared with legacy VHD, subject to platform support.

Remember

  • VHD and VHDX are image formats, not storage backends.
  • VHDX capabilities do not guarantee the host filesystem or storage hardware provides equivalent resilience.
  • Dynamic VHD/VHDX logical size can exceed current file allocation.
  • A readable VHDX file does not prove the guest filesystem inside it is healthy.

First checks

  • Get-VHD <path> | fl VhdFormat,VhdType,FileSize,Size,ParentPath — VHDX details
  • Test-VHD <path> — integrity
  • Optimize-VHD <path> -Mode Full — compact dynamic VHDX (VM off)

Verify in this order

VHDX file → Hyper-V storage stack → guest disk

Where it usually breaks

First mismatch in guest block/filesystem view → virtual controller/disk → hypervisor mapping → datastore/path → storage backend → durability/read-back; preserve identity/native error/pre-state before mutation.

Virtual Storage → VHD / VHDX reference map

BoundaryMeaningEvidence limit
VHDlegacy formatCompatibility boundary
VHDXnewer formatFeature/capacity boundary
Allocationfixed/dynamic/differencingSeparate property
Backendfile storageOutside format

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=3511

Confirmation

Confirm action

Continue?