Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've ported a 'hard disk' using the 'clonehd' advice given on How to easily port VirtualBox machines? But it's not at the latest state, it's probably before any 'snapshot' was taken.

I have only copied the 'hard disk', I haven't copied any 'snapshot' mainly because there are so many. I'm interested to transfer the 'hard disk' at it's latest state.

How can this be done? (easily and not by coping the entire snapshots, machine etc...)

share|improve this question
add comment

2 Answers

Yes, you can do this if you have some spare disk space.

Start with VB closed.

First, duplicate your VirtualBox directory. On my Linux boxes, this is ~/.VirtualBox. Just use whatever operating system tool is your favorite. Again, on Linux I just used "cp -rv .VirtualBox .v2"

Now, run VirtualBox and merge all the snapshots. You end up with no snapshots and a single VB hard disk image that's the latest version.

Move that image to wherever you want to use it. Now remove the new folder and rename your backup (.vb in my case) back to the original name (.VirtualBox). This leaves your original VB session with all its snapshots intact, while the new HD image includes all your changes.

share|improve this answer
add comment

I think the snapshot files contain everything that's happened since the snapshot was taken, so I don't see how you can get around transferring them. If you don't need all the intermediate snapshots anymore, you can discard them, and VirtualBox will merge the changes, which could save space.

share|improve this answer
    
It's a nitpick, but 'snapshots' don't change after they're taken. They freeze the machine state at the moment in time you request them. Things that change after the latest 'snapshot' are called "Current State" at the bottom of the snapshot list. "Current State" is really a snapshot that's being constantly updated without you having to request it. If I recall correctly Vbox can only export the current state, so if you want to revert and export a snapshot you might want to save the current state in its own snapshot before reverting to the one you want to export. –  hotei Sep 12 '10 at 3:26
    
@hotei You are correct, and I should have been clearer: What I meant when I wrote "snapshot files" was the files with indecipherable GUID-like filenames, as opposed to the "foo.dvi" that you start out with. –  coneslayer Sep 13 '10 at 16:16
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.