-
Power-off VM
-
Login to ESXi via SSH and convert VMDK to thin provisioned:
vmkfstools -i $THICK_VMDK -d thin $THIN_VMDK
-
Replace $THICK_VMDK with $THIN_VMDK in the VM settings
-
Power-on VM
-
Login to VM to zero disk space:
Linux:
bash dd if=/dev/zero of=/zero bs=64m rm -f /zero
Windows:
1. Download sdelete
2. Run sdelete -z c:
- Power-off VM and login to ESXi via SSH to punchzero the thin disk:
bash vmkfstools -K $THIN_VMDK
-
Power-on VM
-
Delete $THICK_VMDK from datastore