Performing Unattended Setups with Answer Files


Last week, I presented an overview of the different technologies that you can use to automate Windows 2000 deployments. This week, I discuss unattended setups using answer files, the text files that give the Win2K or Windows NT setup program the responses it needs during the setup process. With answer files, you can install Win2K Server and Win2K Professional using a network share or a bootable CD-ROM. I'll discuss each method after I explain the process of building an answer file.

Building Answer Files
Not long ago, building answer files was time consuming. You had to build a text file that specified all the correct configuration information, including the machine name, the IP address, and network card settings. To simplify the process, Microsoft included a utility called Setup Manager in the Microsoft Windows NT Server 4.0 Resource Kit. The Win2K Advanced Server, Win2K Server, and Win2K Pro CD-ROMs include an improved version of this utility. You can find the utility in the Support\Tools directory's cabinet file To use Setup Manager, extract setupmgr.exe and setupmgx.dll to a folder on your hard drive, and run setupmgr.exe to begin creating your answer files.

Setup Manager provides an easy-to-use wizard interface that helps you build answer files. After the initial welcome screen, you encounter a configuration screen that prompts you to specify what kind of answer file you want to create. You can either create an answer file from scratch or create one that pulls its base settings from the machine you're running Setup Manager on. You can also use Setup Manager to modify an existing answer file by specifying its location, as Screen 1 shows.

On the next screen, you can use Setup Manager to create the full answer files that the system uses for traditional unattended installations. (You can also create the files that provide similar functionality for Sysprep and Remote Installation Services; I'll discuss these options in the next two installments of Windows 2000 Ready.) After indicating that you want to create an unattended answer file and specifying the OS you're installing, Setup Manager walks you almost completely through the process of creating your answer file, asking you all the questions you face during a typical manual setup and writing the information to the answer file in the proper syntax.

With Win2K, it's easier to use answer files to automate the setup process because there's less to automate than with NT. In most cases, Win2K uses Plug and Play (PnP) to identify hardware and configure it automatically. If the OS doesn't have a driver for hardware you're installing, you can add it to the distribution folder on the server you connect to when you perform the installation. Other improvements to Win2K's answer file functionality include support for multiple adapter cards and the ability to customize Internet Explorer (IE) and proxy settings.

Making Manual Additions to the Answer File
If you watch closely as Setup Manager runs, you'll notice that it prompts you for everything that a typical manual installation asks for except one piece of information—the product ID. You have to add the product ID to the answer file manually to prevent your automated process from pausing. To do so, add the product ID value with a valid license key in the User Data section of the answer file, as Listing 1 shows.

You're now ready to start using your answer files to perform setups either by installing over the network or using a bootable CD-ROM. To install over the network, run winnt.exe (for a clean install) or winnt32.exe (for an upgrade), and use the /u command switch to specify that this is for an unattended installation. To install from a bootable CD-ROM, name the answer file winnt.sif and place it on a diskette. Then, insert the diskette in the machine that you want to do the clean install on, insert the Win2K CD-ROM, and set the machine to boot from the CD-ROM drive.

As always, remember to test your installs to make sure they work properly and pass the correct configuration settings before running them in a production environment. And take a look at the unattend.doc file located in the Support\Tools directory for a complete list of values that you can use in your answer files. Even if you don’t need to add any values to the files that you create with the wizard, it's good to know how much capability is available.

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.