Select virtual machines > settings, select the virtual disk to defragment on the left, and then click Defragment on the right. Disk defragmentation is performed on the partition where the virtual disk is located in the host system.
Start Vmware and start the virtual system.
Double-click the icon in the lower right corner of the system, or select Start-Settings-Control Panel-VMware Tools. ) Select Shrink, select the disk to be defragmented, and click Prepare for Shrink. Select Yes in the window that appears. When the prompt window appears again, you have successfully lost weight for the virtual disk!