Virtual machines in VirtualBox can be exported from one VirtualBox installation and imported to another. It works well to move virtual machines across different systems and physical locations.
Related: How to export VirtualBox Virtual Machine
Related: How to import Virtual Machine to VirtualBox
If you're moving your virtual machine image within a local machine, for example, into a new disk or partition, the export and import process could be daunting. It is especially true if you're moving a large number of virtual machines or recently changed your VirtualBox's virtual machine directory.
Steps to move VirtualBox virtual machine within local host:
-
Make sure your virtual machine is powered off.
-
Get current location of your virtual machine image.
-
Exit VirtualBox.
-
Copy or move the virtual machine folder to a new location.
$ mv ~/Workspace/VMs/VirtualBox/Ubuntu ~/Workspace/VirtualBox/VMs/
-
Start VirtualBox.
-
Right click on virtual machine and click Remove.
-
Click Remove to confirm removal.
-
Click on Tools.
-
Click on Add.
-
Navigate to the virtual machine folder and select on the .vbox file.
-
Click Open.
-
Run the virtual machine to test.