I have VirtualBox 5 in OS X El Capitan 10.11.3. There is an option in Windows's VirtualBox to enlarge the image here described. However, I cannot find a similar way for OS X.
My storage looks like this
Clicking the 8.00 GB you get
Choose disk image and you get
so no similar view as in Windows.
DavidAnderson. The user manual's page 150 is here. It just describes about the command VBoxManage modifyhd but not how you can get it in your commandline.
In VirtualBox 4, there was VBoxManage command to enlarge the image size, as described here about How To Resize A VirtualBox Disk (Window and Mac)
VBoxManage modifyhd “<vdi_file_full_path_and_name>” –resize 40000
I solved the PATH problem by not changing the PATH but uninstalling Macports as described here by the recursive forceful deletes, so I can now call the function without explicitly having
/usr/local/bin/VBoxManage in the start of the command.
klanomath. I run successfully
/usr/local/bin/VBoxManage modifyhd "/Users/masi/VirtualBox VMs/Ubuntu 14.04 64bit/Ubuntu 14.04 64bit.vdi" --resize 10000 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
I login successfully to the encrypted system. I login successfully to my Ubuntu's user account but the session only stays in the view
where the Ubuntu on the host stays stacked infinite time. The encryption of the virtual disk should not be a problem because I managed to get the login view of the OS. I have not been able to login to different TTYs of Ubuntu inside the virtual machine, to debug the case further.
I login successfully as Guest and I get
which indicates that the size of my disk for the OS is too small. I increase successfully the space to 20 GB by the following command but I still receive the complain about no disk space in the Guest login
VBoxManage modifyhd "/Users/masi/VirtualBox VMs/Ubuntu 14.04 64bit/Ubuntu 14.04 64bit.vdi" --resize 20000
The space looks ok inside and there should be enough space
The storage looks now like this where the actual space increases dynamically
Login to my User account still stays stucked forever, like one of the screenshots indicates.
Thread in Oracle's VirtualBox Forum
I opened a thread about the issue in Oracle's VB forum here. I got this answer
https://forums.virtualbox.org/viewtopic.php?f=24&t=50661 Pay close attention to step 2 Also if you selected to use LVM when you installed you would need to use LVM to extend the primary partition. Seek assistance from Ubuntu on how to do that.
where I do not understand the thing about LVM and not content provided in the link.
The last point was solved by completely removing the existing disk and doing reinstallation of Ubuntu with 50 GB dynamic disk size. For long term stability, this method is the safest. I had backups of the files in the disk.
How can you enlarge disk image in VirtualBox?
VBoxManage modifyhdcommand on page 150. Exactly which version of VirtualBox are you using?
VBoxManagecan be found in the directory (folder)
/usr/local/bin, then you should be able to execute the command by typing the full path: