Virtual Box resize disk space

  • Go into settings of the VirtualBox console manager and go into Storage settings. Copy the position path of your current controller. The file can be *.vdi or *.vmdk or others.
  • Shut down VirtualBox again.
  • Make a copy of the VDI file – just in case (“C:\Users\Administrator\VirtualBox VMs\vm\Windows10TeamSystem-disk1.vdi” -> “C:\Users\Administrator\VirtualBox VMs\vm\Windows10TeamSystem-disk1Copy.vdi“)
  • Go into the Windows command prompt (Start->type “cmd” into the box)
  • cd C:\Users\Administrator\VirtualBox VMs\vm\ the location of the VDI file that you wish to resize.
  • At the Windows command prompt, type:
  • D:\>"C:\Program Files\Oracle\VirtualBox\VBoxmanage" modifyhd Windows10TeamSystem-disk1.vdi --resize 358400
    this will re-size the drive to 350 GB(1024 * 350 = 358400). Pick a value that suits you. Note, your vdi file will not change in size at this point. The output should look like:
  • Enlarge the Virtual Machine’s Partition

    You now have a larger virtual hard disk. However, the operating system’s partition on your virtual hard disk is the same size, so you won’t be able to access any of this space yet.

  • You’ll now need to extend the guest operating system’s partition as if you were enlarging a partition on a real hard disk in a physical computer. You can’t enlarge the partition while the guest operating system is running, just as you can’t enlarge your C:\ partition while Windows is running on your computer.You can use a GParted live CD to resize your virtual machine’s partition – simply boot the GParted ISO image in your virtual machine and you’ll be taken to the GParted partition editor in a live Linux environment. GParted will be able to enlarge the partition on the virtual hard disk.First, download the GParted live CD’s ISO file from here.Load the ISO file into your virtual machine by going into the virtual machine’s settings window, selecting your virtual CD drive, and browsing to the ISO file on your computer.

    Boot (or restart) your virtual machine after inserting the ISO image and the virtual machine will boot from the ISO image. GParted’s live CD will ask you several questions while booting – you can press Enter to skip them for the default options.

    Once GParted is booted, right-click the partition you want to enlarge and select Resize/Move.

    Specify a new size for the partition – for example, drag the slider all the way to the right to use all the available space for the partition. Click the Resize/Move button after you’ve specified the space you want to use.

    Finally, click the Apply button to apply your changes and enlarge the partition.

    After the resize operation completes, restart your virtual machine and remove the GParted ISO file. Windows will check the file system in your virtual machine to ensure it’s working properly — don’t interrupt this check.

    The virtual machine’s partition will now take up the entire virtual hard disk, so you’ll have access to the additional space.

Leave a Reply