How to Move VirtualBox Machine Disk or Change Installation Path

Been very long I updated this blog, too bad…

So few weeks ago I added 1TB HDD to my 256SSD laptop and I decided to move my VirtualBox machine installation folder to the larger space so I can expand and have more space in my home directory. This worked, I am going to show how to do that smoothly in this post. I will be moving my Ubuntu installation to another directory path. This is also applicable if you want to move the entire machine installation path to another directory.

VirtualBox Manager

Remove Machine

First thing to do is to remove the Ubuntu Machine if you are trying to move, skip this step if you are trying to restore. Choose Remove only, not Delete all files.

Removing VM Machine

Moving Machine Installation Path

If you are trying to move the entire machine installation path to another part of your filesystem or disk, then this is for you. Else just ignore.

The default machine installation path in Linux is ~/VirtualBox VMs. Move this directory to anywhere you wish to move it to, we then edit our VirtualBox Preferences by navigating to File > Preferences > General in our VirtualBox Manager and enter new Default Machine Folder as below

Restoring Machines

Restoring the machine is pretty easy:

  • Create New Machine
  • Give it same specification
  • Select the old disk you want to restore instead of creating new disk

A  detailed way to do this is in the video below, ignore the glitches 🙂

So, this was how I migrated my machine installation path and moved my machine to another directory.