several copy of same machine

Discussions about using Windows guests in VirtualBox.
Post Reply
upaco
Posts: 5
Joined: 29. Nov 2010, 10:41
Primary OS: MS Windows 7
VBox Version: OSE Debian
Guest OSses: Win7, Win XP

several copy of same machine

Post by upaco »

Hi!
I am new to vm and virtualbox, so this might come of as a easy question for you.

I have just installed VirtualBox (3.2.10) on my Windows 7 computer. I have installed a windows xp pro guest virtual machine. (just starting to try the product out).
I have taken two snapshots so far, 1 when the win xp OS is installed with the latest service pack and patches and, 1 when it is a member of the domain.
I am about to do a sysprep on the machine and take a third snapshot.

Now I would like to take the sysprep version and send to a work buddy of mine so that he quickly can set up his vm test machine.
I also would like to send the first snapshot version to another work buddy who needs a clean machine (before domain and gpo restrictions are put on).

Can one do this and how?

all help is appretiated
Paco Serveras
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: several copy of same machine

Post by Sasquatch »

It's difficult to nearly impossible to clone a VDI that has snapshots, especially if you want to create clones from intermediate snapshots. One thing you can try is to use Mpacks CloneVDI tool (see Windows Hosts) to create a clone of the last state. Then with the command line VBoxManage, you can try to clone the base VDI of the VM, where it has all the patches but no domain membership. To use the command line, you open a command prompt window, navigate to the VB install directory and run VBoxManage clonehd <full path of base VDI> <full path of new file>.

Good luck. But keep in mind, this might not work.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
upaco
Posts: 5
Joined: 29. Nov 2010, 10:41
Primary OS: MS Windows 7
VBox Version: OSE Debian
Guest OSses: Win7, Win XP

Re: several copy of same machine

Post by upaco »

Hi and thank you for a quick reply.

Is there an easy way to do a copy without the snapshot?
I could reinstall the vm guest, take a copy. Install everything that should be there and run a sysprep and take a new copy to send out and then install it for myself with domain rights.
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: several copy of same machine

Post by Sasquatch »

Ehm, well, what are the exact differences between the clean install and the sysprep, other than domain membership? If there is none, then you can just as well send the base to both of them. I just remembered that you should be able to just copy the base VDI and send it to the other users without doing anything special. However, VB might complain about missing snapshots for the base VDI because of the original snapshots being hooked up to it. There are hooks made in the base when you create a snapshot.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
upaco
Posts: 5
Joined: 29. Nov 2010, 10:41
Primary OS: MS Windows 7
VBox Version: OSE Debian
Guest OSses: Win7, Win XP

Re: several copy of same machine

Post by upaco »

The clean installation is just the os and sp, the one I am doing sysprep on has a little more applications etc. installed on it.
But I will try and copy the base vdi to another machine and see what it says.
Else if I do a sysprep and then remove all the snapshots I should be able to just copy that vdi to someone else?
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: several copy of same machine

Post by Sasquatch »

Yes, if you merge the snapshots into the base VDI, you can safely send it to someone else. But Mpacks tool allows you to clone a VDI with snapshots into a base VDI ready for sending, without breaking your snapshots.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
upaco
Posts: 5
Joined: 29. Nov 2010, 10:41
Primary OS: MS Windows 7
VBox Version: OSE Debian
Guest OSses: Win7, Win XP

Re: several copy of same machine

Post by upaco »

Sasquatch wrote:One thing you can try is to use Mpacks CloneVDI tool (see Windows Hosts) to create a clone of the last state.
I just don't get it, starting to feel dumb.
I downloaded the Mpack Clonedvi and ran it. I can choose the .VirtualBox\HardDisks\VM002.vdi
but not the .VirtualBox\Machines\VM002\Snapshots\{6c03be19-dfb2-4978-bd87-a31a5ebb96ad}.vdi file.

So the clone I am getting out is the same base os+sp that I get when just copying it.
Am I not to get the vdi with the latest snapshot in here or is the latest snapshot added with the vboxmanage?
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: several copy of same machine

Post by Sasquatch »

When you select the base VDI, you get the base VDI clone. When you select a snapshot, you get a single VDI with the snapshot data in it as if you merged the two. The full working of the tool is in his usage document and the topic itself.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
upaco
Posts: 5
Joined: 29. Nov 2010, 10:41
Primary OS: MS Windows 7
VBox Version: OSE Debian
Guest OSses: Win7, Win XP

Re: several copy of same machine

Post by upaco »

Which version of CloneVDI are you using? I am running v.2.03 and I cannot pick a snapshot to make a clone of.
I only get the error msg. 'source is a difference image...'.

Also found a detailed description of clonevdi, and it also wants you to merge all the snapshots with the base vdi before cloning.
If you know of a version or way to clone the base and snapshot together please direct me to it.

Thank you
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: several copy of same machine

Post by Sasquatch »

I don't use CloneVDI. If you have some questions with the latest version, then ask in the discussion topic. Mpack will reply once he reads it.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: several copy of same machine

Post by mpack »

upaco wrote:Which version of CloneVDI are you using? I am running v.2.03 and I cannot pick a snapshot to make a clone of.
v2.03 is the latest version, and it supports cloning of snapshots. You would only get the validation error you mention if the tool was unable to resolve the chain of links back to the base VDI - this chain is required in order that CloneVDI can access all of the data necessary for a merged clone.

Background: each VDI header has a UUID to identify itself, and another UUID to identify the parent (in non-snapshot VDIs the parent UUID is 0). In order to turn the parent-UUID into a filename I have to look up the UUID in the VirtualBox media registry (in VirtualBox.xml). So if you've messed up the media registry, or you moved or renamed the files then that step will fail, and you'll get that error message. As a last resort you can create your own media registry - see the CloneVDI release notes for a description of CloneVDI_Media.xml.
upaco wrote:Also found a detailed description of clonevdi, and it also wants you to merge all the snapshots with the base vdi before cloning.
I think I know the tutorial you mean. It's wrong. It was wrong at the time of writing, I said so to the author, but he never corrected it. In his defence the procedure he outlines should work, it's just isn't necessary, and that one sentence we're talking about - is just plain wrong. The CloneVDI release notes document is the definitive guide as to what CloneVDI can and can't do.
rogerdpack
Posts: 85
Joined: 31. Oct 2008, 13:00

Re: several copy of same machine

Post by rogerdpack »

Since google led me here, http://superuser.com/questions/22671/ho ... pshot?rq=1 may have an idea or 2 for you.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: several copy of same machine

Post by mpack »

That external discussion seems quite worthless to me.

The easiest, current, way to clone a VM, with snapshots or without, whether you want to keep the snapshots or not, is to use the built in "Clone" feature (available since v4.1.0). It easily handles all of these scenarios.
Post Reply