How to Enlarge Disk Image in VirtualBox?

Solution 1:

Your vdi path is wrong:

VBoxManage: error: Could not find file for the medium

In your resize command either use the uuid of the vdi or a proper path (no backslashes!) :

VBoxManage modifyhd "/Users/masi/VirtualBox VMs/Ubuntu 14.04 64bit/Ubuntu 14.04 64bit.vdi" --resize 10000

or (with backslashes but no quotation marks)

VBoxManage modifyhd /Users/masi/VirtualBox\ VMs/Ubuntu\ 14.04\ 64bit/Ubuntu\ 14.04\ 64bit.vdi --resize 10000

or after entering VBoxManage list hdds:

#replace UUID and size below by the appropriate UUID and the required size
VBoxManage modifyhd UUID --resize size

If your PATH doesn't work properly you may have to prepend /usr/local/bin/

Solution 2:

I might be missing something here, but this is how I see it. You are executing the VBoxManage command to add space to your virtual disk. What does that translate to? Does this mean you are adding logical blocks to the disk? If so, then this space is not going to be automatically added the the partitions containing the file sytems. Would you not also have to execute commands from within the virtual OS or a live version of a virtual OS to expand the file sytems?