-
Oracle VirtualBox - Resizing 'vmdk' diskCloud/Oracle VirtualBox 2020. 8. 11. 11:29
<Overview>
This is how to resize 'vmdk' file by CLI.
<Pre-Requisites>
1. Oracle VB should be installed
2. You should have a VM to resize.
<Steps>
1. My VM(controller) has 30.00GB 'vmdk' disk.
2. Check and go to the directory location that the disk is placed on.
Machine > Settings > Storage > Information > Location
3. Open a command prompt.
4. You should check the location for the command file(VBoxManage.exe) to resize.
In my case, I can see the file in here.
5. Change disk format from .vmdk to vdi
VBoxManage clonemedium "original.vmdk" "clone.vdi" --format vdi
6. Resize the cloned vdi disk.
1GB = 1024MB
500GB = 512,000MB
VBoxManage modifymedium "clone.vdi" --resize 512000
7. Change the cloned disk to vmdk format
VBoxManage clonemedium "clone.vmdk" "resize.vdi" --format vmdk
8. Replace the VM disk.
Machine > Settings > Storage > Attributes > Choose Virtual Hard Disk File... > resized.vmdk
9. Check the Disk size
That's a wrap!