Skip navigation

How can I dynamically choose which Microsoft Systems Management Server (SMS) OS Deployment Feature Pack OS program to deploy, depending on the client hardware?

A. In the standard SMS OS Deployment Feature Pack OS program properties, you can select custom actions for the Feature Pack to perform at each of the five deployment phases. These actions can be scripts that you've written to perform certain actions. However, these scripts are part of a particular OS deployment program that's already been chosen and thus can't be used to determine which OS deployment program to use. If you want to use a script to actually decide which OS deployment program to use (e.g., according to the machine type) or by performing a lookup against an SQL database, you need to select a special option when you create the Operating System Image Installation CD-ROM. You do so by performing these steps:

  1. Start the Microsoft Management Console (MMC) SMS Administrator Console snap-in (Start, Programs, Systems Management Server, SMS Administrator Console).
  2. Right-click Image Packages and select Create Operating System Image Installation CD from the All Tasks context menu.
  3. Click Next at the "Welcome to the Update Windows PE Wizard" screen.
  4. Clear the "Allow installation of Operating System Packages from a location provided by the local computer installer" check box and the "Allow the local computer installer to choose the name of the new computer" check box. Leave the first check box "Allow installation of Operating System Packages from SMS distribution points" checked. Then select the "Automatically choose the Operating System Package to install by running a custom program or script" check box, as the figure shows. Click Next.
  5. Select the OSs that might be installed, as decided by the script (it's usually best to check them all). Click Next.
  6. Enter the name of the script to run that will select the OS package and program to deploy. This name must be a Universal Naming Convention (UNC) pathname because the script isn't part of the installation CD-ROM. Instead, the OS Deployment shell reads it from the share each time the OS Deployment shell execution needs it (which means that you don't need to rebuild the image installation CD-ROM every time you change the script). You also need to enter user credentials that allow access to the share in which the script is located, as the figure shows. Click Next.
  7. As the wizard finishes, you'll need to specify any additional network or SCSI drivers, a group name for the machines that are deploying the OS, and a filename for the ISO file to create.

Remember that the Microsoft Windows Preinstallation Environment (WinPE) installation that's included in the SMS OS Deployment Feature Pack doesn't support things such as database access or Windows Management Instrumentation (WMI); therefore, to perform such functions, you need to create a custom WinPE installation.

As I stated earlier, the specified script isn't stored as part of the OS image CD-ROM. The reference to the script and the credentials used to access it are stored in the ripinfo.ini file, which is located in the root directory of the CD-ROM you create. You can view the file by using any text editor. The following sample ripinfo.ini file shows the reference to the script you specified in the \[UserCommand\] section.

WizTitle=Zero Touch
CommandLine=""\\Vsztisrv01\OSDXtra\osd_install.vbs" "
DisplayName=WindowsServer2003Std - Windows2003Std
DisplayName=WindowsXPProSP2 - WindowsXPProSP2Base
DisplayName=WindowsXPProSP2 - WindowsXPProSP2Loaded

Hide comments


  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.