Shrink VirtualBox Image




Although we assign 40/50gb hdd space to VM, not all of it is used.
After using VM for sometime, you may find vdi is constantly increasing & may need to shrink it.

To Shrink vdi size.
Linux

dd if=/dev/zero of=/testfile
rm -rf /testfile


Windows

sdelete -c

You can download sdelete from

Run following command to shrink image
Linux

VBoxManage modifyvdi hdd.vdi --compact

Windows

VBoxManage.exe  modifyvdi hdd.vdi --compact


if you find any missing point in here, please let us know in comment section or tweet us at @linuxreaders. To get more articles like this, subscribe to our RSS feeds / Mails.
Read 240 articles by

Trending Posts