A. Mikkelsen VMware ESX scripts, commands, tools and other nice to know things that will make your virtualization days easier!!!!

Tuesday, January 13, 2009

Windows Server 2008 and SYSPREP in a VMware enviroment

Filed under: Tools,Virtual Center,vSphere (ESX),White Papers — Tags: , , , , , , , , , — A. Mikkelsen @ 19:52 pm

After we have allowed Windows 2008 Servers in our VMware VI enviroment, we been having problems sysprepping Windows 2008 Server.
So here is a quick guide to sysprep a Windows 2008 server in a VMware VI enviroment.
(Use this workaround until VMware VI allows you run sysprep against a WIN2008 Server)

  1. Change the source or templates Guest Operating Systemsetting to “Vista (32 bit)” or “Vista (64 bit)” depending on the installation of the Windows 2008 server installation.
  2. Clone the VM or template and you are now able to customize your Win2008 server with sysprep.
  3. After the cloning is done Power On the new VM and let the customization complete.
  4. Shutdown the VM and change the Guest Operating Systemsetting back to “Windows Server 2008 (32/64 bit)”

The reason the above workaround works is that Vista and Server 2008 has sysprep build into the OS and the sysprep in both OS’s and are based on the same technology.

Read more here

http://www.vmwareinfo.com/2008/05/sysprep-windows-2008-in-vmware.html

http://communities.vmware.com/message/934733#934733

http://technet.microsoft.com/en-us/library/cc766514.aspx

21 Comments »

  1. I have try implementing this solution but found out that when the template has 4 processors the esx becomes confuse and stops all actions towards the template.

    I had to manually edit the template configuration file and change the guest operating system back to windows server 2003.

    Comment by Daniel Quintero — Wednesday, January 14, 2009 @ 14:17 pm

  2. This only works for Win2008 not Win2003.
    Are you running ESX 3.5 U3 ?

    Comment by A. Mikkelsen — Wednesday, January 14, 2009 @ 16:03 pm

  3. This should now be supported with U4 without changing guest os to vista

    Cheers

    Comment by Michel Zehnder — Monday, April 27, 2009 @ 8:03 am

  4. Thanks for the update, I haven’t had time to verify it jet.
    \\Anders

    Comment by A. Mikkelsen — Monday, April 27, 2009 @ 23:12 pm

  5. Still need to change to Vista with ESX 4.0. Strange that it is supported under ESX 3.5u4 but not ESX 4.0

    Comment by NerdFrenzy — Tuesday, August 18, 2009 @ 14:03 pm

  6. Tested on ESX 3.5 U4 and it still doesn’t show the right OS in VC.
    Haven’t upgraded til vSpher 4.0 yet so don’t know if it has been fixed…
    A. Mikkelsen

    Comment by A. Mikkelsen — Wednesday, August 19, 2009 @ 7:18 am

  7. Clone from Win2k8 template without change Guest Operating System to Vista worked on vSphere 4 & vCenter Update 1.

    Comment by Malaysia VMware Communities — Friday, December 4, 2009 @ 4:29 am

  8. Hi All,

    i am working for win server 2008 template creation with vmware vsphere client. I have created the template but don’t know whether i have to run sysprep or not.
    if yes, then when i have to run it and where? i have gone through some of the forums where they have written as we have to copy sysprep to vmware folder and change the setting form win server 2008 to vista and customize..

    can any one here explain me this sysprep part again…i need to know how to sysprep win serevr 2008.

    pls help me out,
    my mail id is beckham007fifa@gmail.com

    Comment by Abhishek — Thursday, March 25, 2010 @ 6:51 am

  9. Hi,
    I would create a “Customization Specification” for each Microsoft operating system you want a template of.
    This way you can configure the computername, Serial Key, and much much more.

    If you are running ESX 3.x set the OS to “Vista” for Win2008 else use the right OS version.
    The SYSPREP files are included in WIN2008.

    If you want to run SYSPREP any other way, you’ll give your self to much manual work – and that we don’t like 🙂

    Hope this answers your question
    A. Mikkelsen

    Comment by A. Mikkelsen — Thursday, March 25, 2010 @ 17:33 pm

  10. thank you so much for your reply..so, i will be following the same and will update here after experimenting.

    Comment by Abhishek — Friday, March 26, 2010 @ 5:48 am

  11. Hi All,

    I have created one VM with win server 2008 OS changd the OS type to vista 32bit and cloned it to template,then tried to deploy from the template and got customization button enabled and given information regarding name and passwords when guest OS customization came. When click ok after giving inputs then encountered error “Failed to deploy template, customization of guest is not supported in this configuration.Microsoft vista TM and linux guest with logical volume manager are supported only for recent ESX host and VMware tool versions, pls refer to the virtual center documents for details.

    I ma having ESX 3.5 VC 2.5
    and I am in the need of testing it. In the live environment am having Vsphere client the latest VMware product but here in the test lab am not having it.

    So, is it possible to test this settings here with any updates of 3.x product of VM.

    Pls help me out and guide me in updating the Vm with the updates if required..

    thanx..

    Comment by Abhishek — Friday, March 26, 2010 @ 8:43 am

  12. What update for ESX and VC are you running ?
    If your running the latest version of ESX and VC then try to change to OS type to Win2008.

    I know it works because I have a ESX 3.5.5 and vCenter 2.5.x where it works.

    A. Mikkelsen

    Comment by A. Mikkelsen — Friday, March 26, 2010 @ 10:42 am

  13. Dear Mikkelsen,

    I admire your answers, could you please send me your no. I need your help badly.

    Thnks…

    Comment by Abhishek — Friday, March 26, 2010 @ 11:25 am

  14. Hi All,
    I have tried to update the VC version from VC 2.5.0 to VC 2.5.5.

    I have followed upto this..

    21. Launch the VMware Infrastructure Client and access your VirtualCenter Server.
    22. You must now configure and activate the Update Manager using VI Client.
    23. From the Plugins drop-down menu, select Manage Plugins.

    24. Select the Download and install option from the VMware Update Manager Extension.

    25. Click Next at the VMware Update Manager Client InstallShield Wizard.
    26. Accept the VMware Master EULA and click Next.
    27. Verify the installation location. Click Install to begin.

    28. When the installation wizard has completed, click Finish.
    29. Click OK to close the Plugin Manager window.
    30. Exit the VI Client and restart VI Client access to the VirtualCenter Server to activate the new plugin.
    31. Access the Plugin Manager again to enable the newly installed Update Manager. Check the enable checkbox under the Installed tab.
    32. Note the new Update Manager button in the toolbar. Close the Plugin Manager window.

    33. Verify the Update Manager has Internet connection and the setup is working.

    34. Browse to C:\Documents and Settings\All Users\Application Data\VMware\VMware Update Manager\Logs and open the vmware-vci-log4cpp.log file.
    35. You will notice the log file contain activities of the Update Manager. Close the log file.

    36. Select the Schedule Update Download option from the Plugins  Update Manager drop-down menu.

    37. Download only the ESX Server patches. Deselect all Windows and Linux updates. Click Next to continue.

    38. In the Schedule Update Download Wizard, select Frequency = Once, Start Time = Now.

    39. Click Next.
    40. Enter the information for email notification. Click Next to continue.
    41. Verify the summary information and click Finish.
    42. Check the Recent Tasks window of your VI Client. The VMware Update Manager task should now be running.

    43. Verify the task has completed successfully.

    Note
    To change the location of the patch store location, edit the C:\Program Files\VMware\Infrastructure\Update Manager\vci-integrity.xml file. Find the section where the label starts with C:\

    Exercise 2
    1. Launch VI Client and access your VirtualCenter Server.
    2. Click the Update Manager button on the VI Client task bar.
    3. From the Plugins drop-down menu, select Update Manager  Schedule Update Download.

    4. In addition to ESX Server updates, also download all Windows and Linux updates. Select all of them and click Next to continue.
    5. For this lab, select Frequency=Once, Start Time=Now.
    6. Click Next.
    7. Click Next in the email section.
    8. Click Finish.
    9. Go to the Update Manager Baselines tab. The number of available updates is displayed.

    Exercise 3
    1. In this exercise, we will create a baseline for ESX hosts.
    2. From the Baselines tab in Update Manager, click Add.

    3. In the New Baseline Wizard window, enter a Name for this new baseline.
    4. Select ESX Server Updates.

    5. In the Baseline Type section, select Dynamic and click the All Critical Updates option. Check the checkbox for Add or remove specific updates from this baseline.

    6. Click Next to continue.

    7. In the Exclusions section, if no update that matches your criteria has been found, click Next to continue. If any updates are available or selected, you can add or remove them from the baseline.

    8. This also applies to the Inclusions section. Click Next to continue.

    Is it a correct method for updating the VC???
    Pls help me out guys..

    Comment by Abhishek — Friday, March 26, 2010 @ 11:59 am

  15. Hi,
    If you have followed all steps upto 21, you have updated your vCenter Server.
    Have you also upgraded your Update management server?
    If so then just update your client and then update your Update Manager plugin.
    Then you can upgrade your ESX hosts using the baselines :-).

    If you upgrade your hosts to latest ESX 3 Update then you should be able to use WIn2008 templates 🙂

    Comment by A. Mikkelsen — Friday, March 26, 2010 @ 23:07 pm

  16. Hi Mikkelson,

    I have one doubt, is it possible to download newer esx 4.0 server and vsphere client freely?
    i am having these all things in production but not with my test environment…

    Comment by Abhishek Singh — Saturday, March 27, 2010 @ 11:51 am

  17. Hi All,

    My main problem is with checking the template(win server 2008) with sysprep and SID and all should be regenerated. So, can I go like running sysprep manually on the machine and shutdowing and then converting it into templates and then deploying…
    please help me on this….

    This method I have followed for creating win server 2008 physical image, so, please help me in confirmaing this……

    thanks

    Comment by Abhishek — Monday, March 29, 2010 @ 6:07 am

  18. You can always download the latest ESXi version for free, but the vCenter & ESX can only be downloaded in a trial version or as you would for production purpose.

    Comment by A. Mikkelsen — Monday, March 29, 2010 @ 20:29 pm

  19. I wouldn’t spend time on running sysprep before shutting down the win2008 OS.
    Just use the sysprep feature in the template function.

    This make you be able to update the template at a later date without completing the sysprep questions and then running sysprep again before shutting down the OS again.

    Comment by A. Mikkelsen — Monday, March 29, 2010 @ 20:33 pm

  20. I have ESXi 4.1 with a working, fully activated guest OS of Windows 2008 Standard Server R2. I have cloned it using a CLI command and have created a new VM with this clone. Windows is not activated. What can I do to resolve this? Will I be able to clone, sysprep and then use the clone and have Windows fully activated like the original? Help! Thanks.

    Comment by Gina — Thursday, August 25, 2011 @ 22:49 pm

  21. As far as I know you need to set up a KMS server om your network that the VM’s can authenticate against.

    A. Mikkelsen

    Comment by A. Mikkelsen — Saturday, August 27, 2011 @ 19:56 pm

RSS feed for comments on this post.

Leave a comment

Powered by WordPress