Recovering a VMDK from just a -flat.vmdk file is straightforward as long as you can recreate the small descriptor file. Use vmkfstools for simplicity or manual creation for zero‑space overhead. The key data points are:
Use the vmkfstools command to generate a dummy disk of the exact same size: vmkfstools -c -a -d thin temp.vmdk . recover vmdk from flat file
Create a new file named vmname.vmdk in the same directory as the flat file. Recovering a VMDK from just a -flat
To recover a VMDK from a -flat.vmdk file, you must (the small text file that points to the actual data). This process essentially "marries" a new header to your existing data. Prerequisites Power off the virtual machine associated with the disk. Enable SSH on your ESXi host and log in as root. Create a new file named vmname
# Disk DescriptorFile version=1 CID=12345678 parentCID=ffffffff createType="vmfs"
Set a random CID (e.g., 12345678 ). This must differ from other disks in the same VM.
Open it with a text editor ( vi .vmdk ) and locate the line under .