- Assume that mydisk.vmdk is mounted on /dev/sda1 with directory /BACKUP
- Suppose 950GB to be shrink. Issue this:
sudo dd bs=1M count=950000 if=/dev/zero of=/BACKUP/zero.datstatus=progress
This is for creating a 1M * 950000 = 950GB zero filled file, zero.dat - Then, delete this file,
sudo /bin/rm -rf /BACKUP/zero.dat - Close vmware-workstation and go back to host. Go to the vmdk file directory, say /vmware/mydisk.vmdk
- Make sure /vmware has doule size space of mydisk.vmdk because the following shrinking command will create another mydisk.vmdk.tmp file.
- sudo vmware-vdiskmanager -k mydisk.vmdk
- Go back to vmware-workstation. Click the 'Compact Disk' in the setting windows.
- Use clonezilla to boot the vmware guest.
- Enter the expert mode,unclick and click options as follows:
- Start to disk to disk cloning.
- Done
沒有留言:
張貼留言