New VM guestos windows password lock

I am currently working on a series of scripts that creates the virtual machine to a csv file and then configure a number of options and setting from a file source csv.

The problem I have is that when you create a computer virtual model or cloning of the guest operating system (windows server 2008R2 and 2003 in this case) goes to security and will not allow a connection until the password is changed.

This causes a significant hiccup as most of my scripts depend on invokevmscript and when they try to connect with the credentials that they bounce with error of incorrect credentials.

If manually, I log in and change the password for the same exact password, then all scripts will work fine.

I have the problem narrowed down, but I don't see another solution that does not use OScustomizationspec in the creation that is not an option for our production environment.

Possible ideas, I've had include applying the OScustomizationspec after the scripts, or to have a script to change password before the rest of the scripts, but I was not able to develop anything like that.

Help, advice or anything is appreciated!

It turns out that when you create the virtual machine, you need to let them rest for about 60 to 90 seconds after the first start, then they apply to the guestOS customizationSpec after the connection works fine.

Just add a timer 120 sec at the first start to the configuration script.

Tags: VMware

Similar Questions

Maybe you are looking for