Rizky Lab.

How do I resize the hard disk volume of the virtual machine?

I have run out of space on my Windows7 virtual machine, which I only gave 40 GB space when I created it. My Windows7 operating system (guest) installed on Ubuntu 18.04 (host) virtualbox. Right now, I’m doing project in managing and processing some spatial data that need bigger space for storing and running several bigger memory consumsion software (e.g. ENVI, Erdas, ArcGIS and Matlab). Suppose 50 GB is quiet enough for that, following description will show you how to resize the storage.

1. Remove the virtual disk image (*.vdi) file from virtualbox.

2. Open terminal (Ctrl + Alt + T) and use the following command:

VBoxManage modifymedium YOUR_HARD_DISK.vdi --resize SIZE_IN_MB

replace YOUR_HARD_DISK and SIZE_IN_MB with your image name and desired size. sudo might be necessary in some machine unless you might encounter an error.

3. After resizing, reattach image to your guest system

4. Run your Guest system and you would find old volume of hard disk

5. the extra virtual hard drive space needs to be partitioned and attached. This can be done with Computer Management.

6. Right click on drive C and Extend volume. We can also shrink a volume or make a new partition by this tool.

Good Luck

Scroll to top