Guest OS:
xfs_fsr # Defrag.
cat /dev/zero | pv | cat > /zerofile # Write zeroes until space runs out.
sync && shutdown now # Flush and reboot.
rm /zerofile && sync && shutdown now # Remove file, flush, and shutdown.
Host OS:
cd "\Program Files (x86)\VMware\VMware Workstation"
vmware-vdiskmanager.exe -d "%USERPROFILE%\Documents\Virtual Machines\MachineName\MachineName.vmdk"
vmware-vdiskmanager.exe -k "%USERPROFILE%\Documents\Virtual Machines\MachineName\MachineName.vmdk"