Friday 11 September 2020

How To Enlarge or Increase a Virtual Machine’s Disk space in Oracle VirtualBox

How To Enlarge a Virtual Machine’s Disk in VirtualBox

 

Use the Virtual Media Manager in VirtualBox

VirtualBox 6 added a graphical option for enlarging and resizing virtual disks. To access it, click File > Virtual Media Manager in the main VirtualBox window.

Select a virtual hard disk in the list and use the “Size” slider at the bottom of the window to change its size. Click “Apply” when you’re done.

You will still have to enlarge the partition on the disk to take advantage of the additional space. The partition remains the same size even while the disk size increases. See the instructions below for more information on enlarging the partition.

Enlarge a Virtual Disk in VirtualBox

To enlarge a virtual disk in VirtualBox, you’ll need to use the VBoxManage command from a Command Prompt window. First, shut down the virtual machine – ensure its state is set to Powered Off, not Saved.

(Before continuing, you should also delete any snapshots associated with the virtual machine if you use the snapshots feature in VirtualBox. This will ensure you’re modifying the correct virtual disk file and that everything will work properly afterward.)

Second, open a Command Prompt window from your Start menu and change to VirtualBox’s program files folder so you can run the command:

cd “C:\Program Files\Oracle\VirtualBox”

The following command will operate on the VirtualBox virtual disk located at “C:\Users\Gateway\VirtualBox VMs\Windows 7\Windows 7.vdi”. It will resize the virtual disk to 81920 MB (80 GB).

VBoxManage modifyhd “C:\Users\Gateway\VirtualBox VMs\Windows 7\Windows 7.vdi” --resize 81920

(Use two dashes before resize in the command above.)

Replace the file path in the command above with the location of the VirtualBox disk you want to resize and the number with the size you want to enlarge the image to (in MB).

Update: In VirtualBox 6.0, released in 2019, you may need to use the following command instead:

VBoxManage modifymedium disk “C:\Users\Gateway\VirtualBox VMs\Windows 7\Windows 7.vdi” --resize 81920

 

For More Tutorials Please Visit :- www.youtube.com/c/gatewaysolutions

 feel free to comment.

Thanks for reading .