When thin provisioning disk in your VMware virtual environment you may occasionally run into an issue where a VM is soaking up more space than it appears it should be. This is because of the way that VMware treats thin provisioned disk.
Example : You thin provision 100GB of disk to a VM. Its using 50GB, so the VMDK is showing 50GB. You copy 5GB of files to the VM and delete them after. The OS reports 50GB being used, and the VMDK shows 55 – this is because the space WAS used, and now that’s how big the VMDK will be until maintenance is performed. A simple command you can do to get that disk space reduced to the ACTUAL size is :
VMKFSTOOLS --punchzero /vmfs/volumes/volume/VM_FOLDER/File.VMDK
I do this by puttying into the host running the VM first, power off the VM, and run the command above. This can take a while so if the disk is huge – be prepared to wait.