Showing posts with label SYSPREP. Show all posts
Showing posts with label SYSPREP. Show all posts

Monday, June 20, 2011

SYSPREP 2003

sysprep a windows 2003 R2 image, follow the  below:

  • Insert CD1
  • go to  Support\Tools\Deploy.cab
  • select everything and extract them to c:\sysprep ( a folder that you have created it)
  • Double click sysprep.exe.
  • Keep the default settings (Options un-selected, shutdown mode: shutdown)
  • click on Reseal
  • And press Ok

Monday, July 5, 2010

SYSPREP for 2k3

When working with Virtual Machines, Sysprep is a real timesaver. You can, on a virtual machine, install several configurations of servers (SMS 2003, SQL or SCCM or vNext, etc), sysprep the images, and then have these pre-configured images ready to deploy to a VPC or any Vcenter  installation when needed, by just copying the appropriate VHD file over and associating it with a new VM.

In order to run Sysprep, you first need to install it. You can get a hold of Sysprep in two ways: it is on the \Support\Tools\Deploy.cab file on the Windows Server installation media, or you can download it from here. Once you get a hold of the Deploy.cab file, you should extract the contents to a directory on your HD, for example c:\Deploy.

SYSPREP1

This directory contains several useful tools, and you should definitely read the deploy.chm file for instructions and details on the process. There are two files that are of particular importance to the process: sysprep.exe and setupmgr.exe.

For sysprep to work completely automated, it requires an answer file, called sysprep.inf. This answer file contains the “answers” to all the questions asked by the Windows installer during the setup process. The answer file can be created manually with any text editor, but fortunately there is a nice wizard-like tool that can help you generate this file. This tool is the setupmgr.exe program:

SYSPREP2

This program allows you to generate the sysprep.inf file by presenting you the options and letting you enter the default answer. In order to fully automate an installation, follow these steps on the Setup Manager:

  1. Click Next on the Welcome screen
  2. Select “Create new” and click “Next”
  3. Select “Sysprep setup” and click “Next”:
    SYSPREP2a
  4. Select the type of system you’re going to sysprep, and click “Next”
  5. Select “Yes, fully automate the installation” and click “Next”
  6. Now you need to fill in all the information required to complete the process:
    SYSPREP2b

Once you complete the execution of the Setup Manager, it creates a new directory in the root of the system drive called sysprep. This directory contains all the information necessary for the Sysprep tool to execute.

SYSPREP4

Now you need to execute the Sysprep tool, sysprep.exe:

In this tool:

  1. Click “OK” on the warning dialog that appears when running the tool.
  2. Select “Don’t reset grace period for activation”
  3. Set the “Shutdown mode” to “Shut down”
  4. Click on Reseal. That will leave the image ready for copying.

Once the image is copied, you can just configure a new virtual machine with the new image, and start it up. The last portion of the Windows setup process will execute:
SYSPREP5

After a little while (<10min), the machine will reboot, and the process will be completed. You now have a brand new sysprep’d and cloned server up and running!!

 

for more info http://technet.microsoft.com/en-us/library/cc765993(WS.10).aspx

 

For Windows XP SP3 :-

 

Step #1

The first step is to download the Sysprep App which is included in the CAB file for Windows XP Service Pack 3 Deployment Tools. (Download Sysprep Tool)

Step #2

Next go to the PC you are going to be sysprepping and create a folder on the root of the C: drive called sysprep.

Step #3

Next you will need to extract the contents of the deploy.cab file you downloaded in Step #1 to the sysprep folder on the root of the C: drive.

Step #4

Now we are going to run the sysprep Setup Manager. Double click on setupmgr.exe.

Sysprep Setup Manager

Sysprep Setup Manager

Step #5

Click Next and it is going to ask you whether you want to modify an existing Answer File or create a new one. We are wanting to create a new one, so again click next.

Sysprep - New or Existing Answer File

Sysprep - New or Existing Answer File

Step #6

You now have three options: Unattended Setup, Sysprep Setup, or Remote Installation Services (RIS). In this example we are going to select the Sysprep setup option and then click next. (This creates a sysprep.inf file)

Sysprep - Sysprep.inf File

Sysprep - Sysprep.inf File

Step #7

Select Windows XP Professional and click next. (This will also work on Windows XP Home, Windows Server 2003 Standard, Web, and Enterprise.)

Sysprep - Windows XP Professional

Sysprep - Windows XP Professional

Step #8

In this step it is asking you if you want to fully automate the installation. That is up to you, either way works fine. In this example I will be using the “No, do not fully automate the installation.”

Sysprep - Fully Automate or Not?

Sysprep - Fully Automate or Not?

Step #9

Now we are at the configuration page. There is a lot in here so I am not going to go into detail. In fact, you don’t even need to input anything here for the sysprep to just work. However, everything you input in here will save you time and help shape your image.

Sysprep - Configuration Page

Sysprep - Configuration Page

Step #10

Once you are all done, you should be at the bottom and selected on “Identification String”; click Finish and it is going to prompt you for a location to create and save the sysprep.inf file. The default location is fine, as it will need to be within that sysprep folder on your C: drive. Once you hit ok you will then need to click “Cancel”. There is no close button.

Sysprep - Saving the Sysprep.inf File

Sysprep - Saving the Sysprep.inf File

Step #11

Now you should verify the sysprep.inf file by double clicking on it and opening it up with Notepad.

Sysprep - Verifying the Sysprep.inf File

Sysprep - Verifying the Sysprep.inf File

Step #12

There were a few changes with Windows XP Service Pack 3 and sysprep. The administrator’s profile is no longer copied over to the default profile. You will need to add a line within the sysprep.inf file to regain this important function. Under the InstallFilesPath section add this:

UpdateServerProfileDirectory=1

Once done, hit save.

Sysprep - Adding line to sysprep.inf so the administrator profile will copy over to default profile

Sysprep - Adding line to sysprep.inf so the administrator profile will copy over to default profile

Step #13

Now you are ready to start the sysprep, reboot, and capture your sysprepped image. Double click on the sysprep.exe and then select the following three options in order: Use Mini-Setup, Shutdown Mode: Reboot, and click Reseal. Make sure you have your media ready to capture your image. If you reboot fully without booting to your capturing software it will ruin the sysprep and you will have to redo the sysprep.

Sysprep - Preparation Tool 2.0

Sysprep - Preparation Tool 2.0

  • Sysprep will now get rid of any machine specific identifiers and shutdown the computer.
  • The hard disk is now ready to be imaged.  You can at this stage use tools such as Ghost or boot using your WinPE CD and capture the image to a WIM file.
  • Deploy your image to a computer and restart it.
  • If you start the new computer using the newly deployed image, sysprep will now setup Windows according to the settings in sysprep.inf.
    Image-0273
  •  

    For Windows Vista / 7 / 2008

     

    Type this command with administrative privileges in command prompt

     

    c:\windows\system32\sysprep\sysprep.exe /quiet /generalize /shutdown /oobe

    c:\Windows\System32\sysprep\sysprep.exe

    The experience is also streamlined considerably. Simply run sysprep.exe above and you are presented with:

    image

    Check the “Generalize” checkbox (regenerates system SID), change the Shutdown Options to “Shutdown”, and click OK. The system will go through the sysprep process and shut itself down.

     

    Using Your SysPrep’d Image to Create a New Virtual Machine

    Now, creating a new virtual machine will only take just a couple minutes.

    1. First, you need to copy your SysPrep’d image to a new name and to a new location where you will use this new virtual machine.  Copy your SysPrep’d image files (.vmc & .vhd) to a new location where you want your new virtual machine file to reside.
    2. Rename them to a new, appropriate name.  For example, if you are going to create a SharePoint server you might name them something like:
      1. MySharePoint2007.vmc
      2. MySharePoint2007.vhd
    3. Add this new virtual machine to you Virtual PC or Virtual Server; which ever you are using;
    4. Edit the configuration and make sure the virtual hard drive (VHD) is pointing to your new .vhd file.  In this example, the MySharePoint2007.vhd file.
    5. Configure any other items such as memory allocation and network cards as necessary.
    6. Start the virtual machine.
    7. You will receive a few prompts such as the name for you new machine.
    8. If you wish, you can now join you virtual machine to a domain.

    SysPrep is a must have time-saving tool for anyone who uses Virtual PC and/or Virtual Server.

    Thursday, June 10, 2010

    Sysprep parameters

    Sysprep parameters
    You can use the following optional parameters with the Sysprep command in Windows XP:
    • -activated - Do not reset the grace period for Windows product activation. Use this parameter only if you have activated the Windows installation in the factory.
      Important The product key that you use to activate the Windows installation must match the product key that is located on the COA sticker that is attached to that particular computer.
    • -audit - Restarts the computer in Factory mode without having to generate new security IDs (SIDs) or process any items in the [OEMRunOnce] section of the Winbom.ini file. Use this command-line parameter only if the computer is already in Factory mode.
    • -bmsd - Populates all the available mass storage devices in the [SysprepMassStorage] section.
    • -clean - Clears the critical devices database that is used by the [SysprepMassStorage] section in the Sysprep.inf file.
    • -factory - Restarts in a network-enabled state without displaying Windows Welcome or mini-Setup. This parameter is useful for updating drivers, running Plug and Play enumeration, installing programs, testing, configuring the computer with customer data, or making other configuration changes in your factory environment. For companies that use disk imaging (or cloning) software, Factory mode can reduce the number of images that are required.
      When all the tasks in Factory mode are complete, run the Sysprep.exe file by using the -reseal parameter to prepare the computer for end-user delivery.
    • -forceshutdown - Shuts down the computer after the Sysprep.exe file finishes.
      Note Use this parameter with computers that have an ACPI BIOS that do not shut down correctly with the default behavior of the Sysprep.exe file.
    • -mini - Configures Microsoft Windows XP Professional to use Mini-Setup instead of Windows Welcome. This parameter does not affect Microsoft Windows XP Home Edition, where the first-run experience is always Windows Welcome.
      Note that if you plan to use the Sysprep.inf file to automate Mini-Setup, you must either run the Sysprep tool by using the -mini switch, or click to select the MiniSetup check box in the GUI interface. By default, if you do not choose to run Mini-Setup, Windows XP Professional runs the Windows Welcome.
    • -noreboot - Modifies registry entries (SID, OemDuplicatorString, and other registry entries) without the computer restarting or preparing for duplication. This parameter is mainly used for testing, specifically to see if the registry is modified correctly. Microsoft does not recommend this option because making changes to a computer after the Sysprep.exe file has run may invalidate the preparation that was completed by the Sysprep.exe file. Do not use this parameter in a production environment.
    • -nosidgen - Runs the Sysprep.exe file without generating new SIDs. You must use this parameter if you are not duplicating the computer where you are running the Sysprep.exe file or if you are preinstalling domain controllers.
    • -pnp - Runs the full Plug and Play device enumeration and installation of previous devices during Mini-Setup. This command-line parameter has no effect if the first-run experience is Windows Welcome.
      Use the -pnp command-line parameter only when you must detect and install previous, non-Plug and Play devices. Do not use the sysprep -pnp command-line parameter on computers that only use Plug and Play devices. Otherwise, you will increase the time that it takes for the first-run experience without providing any additional benefit to the user.
      Note When unsigned drivers are unavoidable, use the UpdateInstalledDrivers=yes parameter in conjunction with OemPnPDriversPath= and DriverSigningPolicy=ignore instead of the -pnp command-line parameter to provide a more seamless installation.
    • -quiet - Runs the Sysprep.exe file without displaying onscreen confirmation messages. This is useful if you are automating the Sysprep.exe file. For example, if you plan to run the Sysprep.exe file immediately after the unattended Setup program finishes, add the sysprep -quiet command to the [GuiRunOnce] section of the Unattend.txt file.
    • -reboot - Forces the computer to automatically restart, and then starts Windows Welcome Mini-Setup, or Factory mode, as specified. This is useful when you want to audit the computer and verify that the first-run experience is operating correctly.
    • -reseal - Clears the Event Viewer logs and prepares the computer for delivery to the customer. Windows Welcome or Mini-Setup is set to start the next time that the computer restarts. If you run the sysprep -factory command, you must seal the installation as the last step in your preinstallation process. To do this, run the sysprep -reseal command or click the Reseal button in the Sysprep dialog box.