lonecedar2
Contributor
Contributor

How to clone an XP vm many times quickly

Jump to solution

Hello

I need to know how to clone a VM 60 times quickly. We need 60 sysprep'd copies of a an XP template. I have not been able to find a script that works correctly. I am using the scheduler function at the moment but the problem I am having is you cannot tell the scheduler to clone more that once because it wants to create the same vm name in Virtual Center. If there is a way around this or something I am missing please point me in the right direction.

Any assistance would be greatly appreciated.

-Pat

0 Kudos
1 Solution

Accepted Solutions
mcowger
Immortal
Immortal

You will need to write your own script against the SDK.

Thgough the vmclone.pl in the latest perl toolkit works fine for me, and you could wrpa it in a shell script.

--Matt

--Matt VCDX #52 blog.cowger.us

View solution in original post

0 Kudos
4 Replies
DCasota
Hot Shot
Hot Shot

Hi,

Why do you want to do that? you should consider the fact that the more VMs you want to create simultaneously on the same LUN, the longer the process goes because of heavy read&write IO. (Therefore it's better to select different LUNs.)

If you need to recreate all VMs for testing purposes again and again, have a look to the new product VMware stage manager (formerly known as Dunes Orchestrator)

If you still want to realize an own solution, you can script it with the vmclone.pl script from the SDK (and the vmware-cmd commands). Maybe this thread is helpful: http://communities.vmware.com/message/876223#876223

Hope it helps.

lonecedar2
Contributor
Contributor

Thanks for the Reply Decasota

I don't think I was very clear on my question. I don't want to create them simultaneously but I do want to create them one after the other. As one completes then start the next - automatically! The scheduler has the option to clone a virtual machine and you can choose to have it occur every hour or multiple times - but the issue I have is you cannot have it automatically increment the vm name in vmware vi console - atleast I have not found a way to do it. It will allow you to add a number to the end of the DNS name when it customizes it but not to the name it assigns as a label in Virtual center hence the scheduled job has to be changed manually everytime I run it.

The script vmclone.pl that is included with the newest version of the virtual center pearl toolkit appears to not be compatable with Esx versions 3.0 and later.

-Pat

0 Kudos
mcowger
Immortal
Immortal

You will need to write your own script against the SDK.

Thgough the vmclone.pl in the latest perl toolkit works fine for me, and you could wrpa it in a shell script.

--Matt

--Matt VCDX #52 blog.cowger.us

View solution in original post

0 Kudos
lonecedar2
Contributor
Contributor

Thanks for the reply mcowger

If you have any useful scripts that may work in this situation I would appreciate it.

My skills as a perl scripter are beginner class.

Thanks

Pat

0 Kudos