copy? clone? way too many different answers - help!

This is for discussing general topics about how to use VirtualBox.
Post Reply
reiki
Posts: 17
Joined: 8. Jun 2007, 13:40

copy? clone? way too many different answers - help!

Post by reiki »

I've googled. I've searched the forums. This seems like an extremely common question, but the answers are so widely varied that it becomes confusing. I guess what I'm looking for is a "portable" VM. Here's my situation:

I have a linux (Kubuntu) host. I have one Win7, 64-bit virtual machine that I use for a couple of important tasks for equipment that I can't use in linux.
Current VirtualBox version is 4.1.4

When I upgrade my Kubuntu install from 11.04 to 11.10 I will be doing a clean install as I've never been happy with upgrades. So I need a way to make the existing VM "portable" so I can put it on another partition, upgrade my system, reinstall VirtualBox (making sure I have same VB version when I wipe the OS partition as I will have when I reinstall) and then bring that VM back to life in the new installation. When reinstalling my OS, I may, or may not, wipe my current /home partition. If I wipe both, then the UUIDs of those partitions will change from whet they are now.

I know this is supposed to be easy, because these are, after all, VIRTUAL machines, but it's really hard to find an answer I feel confident with. I use VirtualBox. I'd like to box up one of my virtual machines and be able to start it up again elsewhere without having to stand on my head, manually edit files, while patting the top of my head and rubbing my belly at the same time.

Is there an easy way to do this? It's not in the user docs (yes, I read the section on cloning). Step-by-step. How do I make a copy of the existing VM (it has no snapshots) and use it on another partition after reinstalling both my OS and VirtualBox?
vbox4me2
Volunteer
Posts: 5218
Joined: 21. Nov 2008, 20:27
Location: Rotterdam
Contact:

Re: copy? clone? way too many different answers - help!

Post by vbox4me2 »

The only way to keep things the same is to backup all the config files, master and VM settings files. You could make a script for it and after reinstalling vbox overwrite them with your backup. Done it a few times under windows and it works flawlessly provided the vdi's are in the same place.
slowace
Posts: 3
Joined: 1. May 2011, 21:39
Primary OS: Mac OS X other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: WinXP, Linux

Re: copy? clone? way too many different answers - help!

Post by slowace »

Couldn't you do this with "Export Appliance?"
MasterKGB
Posts: 52
Joined: 24. Jun 2011, 12:16
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: XP, Win7, Linux

Re: copy? clone? way too many different answers - help!

Post by MasterKGB »

hmm why complicated if its possible easy

Just write down your settings of your VM somewhere
Copy the .VDI to a safe place
reinstall your System
reinstall VB
Copy your old .VDI to his new place
Setup a VM with your old Settings and choose as harddisk your .VDI File

Thats it, works million times for me on windows and Linux
Post Reply