banner

Introduction

Answer files are text files that are used to automate the installation of Microsoft® Windows®. They provide the answers to some or all of the prompts that the end user must respond to during Setup and Sysprep. The answer file is specified with the /unattend option to the winnt32.exe command. This hands-free method of installing is convenient for original equipment manufacturers (OEMs), administrators in corporations, value added resellers (VARs), and other end users.

The simplest answer file specifies which features you want to include in the installation. However, you can also use the answer file to display company information during GUI-mode Setup, to specify a keyboard layout, to join a domain or workgroup, and to install device drivers, protocols, or network adapters.

This Windows Preinstallation Reference (Ref.chm) documents the syntax of the various answer files that you use when preinstalling Windows. This Reference is used by both OEMs and corporate administrators. The set of permitted OEM customizations corresponds only to a subset of the answer file entries documented in the Windows Preinstallation Reference.

Note

Winnt32.exe Command-line Options

From a command prompt, use Winnt32.exe to start Windows Setup from a computer that is running one of the following operating systems:

Note

The syntax of the winnt32 command is as follows:

winnt32 [/checkupgradeonly] [/cmd:command_line] [/cmdcons] [/copydir:{i386|ia64}\folder_name] [/copysource:folder_name] [/debug[level]:[filename]] [/dudisable] [/duprepare:pathname] [/dushare:pathname] [/emsport:{com1|com2|usebiossettings|off}] [/emsbaudrate:baudrate] [/m:folder_name] [/makelocalsource] [/noreboot] [/s:sourcepath] [/syspart:drive_letter:] [/tempdrive:drive_letter:] [/udf:id [,UDB_file]] [/unattend[num]:[answer_file]]

Option Action
/checkupgradeonly Checks your computer for upgrade compatibility with this version of Windows.

If you use this option with /unattend, no user input is required. Otherwise, the results are displayed on the screen, and you can save them under the file name that you specify. The default file name is Upgrade.txt in the %SYSTEMROOT% folder.

/cmd:command_line Instructs Setup to execute a specific command before the final phase of Setup. This occurs after your computer has restarted and after Setup has collected the necessary configuration information, but before Setup finishes.
/cmdcons Installs the Recovery Console as a startup option on a functioning x86-based computer. The Recovery Console is a command-line interface from which you can perform tasks such as starting and stopping services and accessing the local drive (including drives formatted with NTFS). You can use the /cmdcons option only after normal Setup finishes.
/copydir:{i386|ia64}\folder_name Creates an additional folder within the folder in which the Windows files are installed.

Folder_name refers to a folder that you have created to hold modifications just for your site. For example, for x86-based computers, create a folder called Private_drivers within the i386 source folder for your installation, and place driver files in the folder. Type /copydir:i386\Private_drivers to have Setup copy that folder to your newly installed computer, making the new folder location %SYSTEMROOT%\Private_drivers. You can use /copydir to create as many additional folders as you want.

/copysource:folder_name Creates a temporary additional folder within the folder in which the Windows files are installed.

Folder_name refers to a folder that you have created to hold modifications just for your site. For example, create a folder called Private_drivers within the source folder for your installation, and place driver files in the folder. Type /copysource:Private_drivers to have Setup copy that folder to your newly installed computer and use its files during Setup, making the temporary folder location %SYSTEMROOT%\Private_drivers. You can use /copysource to create as many additional folders as you want. Unlike the folders /copydir creates, /copysource folders are deleted after Setup finishes.

/debug[level]:[filename] Creates a debug log at the level specified, for example, /debug4:Debug.log. The default log file is C:\%SYSTEMROOT%\Winnt32.log, and the default debug level is 2. The log levels are as follows: 0 represents severe errors, 1 represents errors, 2 represents warnings, 3 represents information, and 4 represents detailed information for debugging. Each level includes the levels below it.
/dudisable Prevents Dynamic Update from running. Without Dynamic Update, Setup runs only with the original Setup files. This option disables Dynamic Update even if you set DUDisable equal to No in the [Unattended] section of the Unattend.txt file.
/duprepare:pathname Prepares an installation share to be used with Dynamic Update files that you downloaded from the Windows Update Web site. Use this share for installing Windows for multiple clients.
/dushare:pathname Specifies a share on which you previously downloaded Dynamic Update files (updated files for use with Setup) from the Windows Update Web site, and on which you previously ran /duprepare:pathname. When run on a client, specifies that the client installation uses the updated files on the share specified in pathname.
/emsport:{com1|com2|usebiossettings|off} Enables or disables Emergency Management Services (EMS) during Setup and after a member of the Windows Server 2003 family has been installed. With EMS, you can remotely manage a server in emergency situations that typically require a local keyboard, mouse, and monitor, such as when the network is unavailable or the server does not function properly. EMS has specific hardware requirements, and is available only for products in the Windows Server 2003 family.

The values com1 and com2 are applicable only for x86-based computers (not Itanium-based computers).

Usebiossettings is the default value, and uses the setting specified in the BIOS Serial Port Console Redirection (SPCR) table, or, in Itanium-based systems, through the Extensible Firmware Interface (EFI) console device path. If you specify usebiossettings and there is no SPCR table or appropriate EFI console device path, EMS is not enabled.

If you disable EMS by specifying /emsport:off, you can later enable it by modifying the boot settings. For information about modifying boot settings, see the Windows Resource Kits.

/emsbaudrate:baudrate For x86-based computers, specifies the baud rate for EMS. (The option is not applicable for Itanium-based computers.) Must be used with /emsport:com1 or /emsport:com2 (otherwise, /emsbaudrate is ignored).

Baudrate can be 9600, 19200, 57600, or 115200. 9600 is the default.

/m:folder_name Specifies that Setup copies replacement files from an alternate location. Instructs Setup to look in the alternate location first, and if files are present, to use them instead of the files from the default location.
/makelocalsource Instructs Setup to copy all installation source files to your local hard disk. Use /makelocalsource when installing from a CD to provide installation files when the CD is not available later in the installation.
/noreboot Instructs Setup not to restart the computer after the file copy phase of Setup finishes so that you can execute another command.
/s:sourcepath Specifies the location of the Windows files. To copy files simultaneously from multiple servers, type the /s:sourcepath option multiple times (up to a maximum of eight). For example:
winnt32 /s:server1 /s:server2

If you type the option multiple times, the first server specified must be available, or Setup fails.

/syspart:drive_letter: On an x86-based computer, specifies that you can copy Setup startup files to a hard disk, mark the disk as active, and then install the disk into another computer. When you start that computer, it automatically starts with the next phase of Setup. You must always use the /tempdrive parameter with the /syspart parameter.

You can start winnt32 with the /syspart option on an x86-based computer running Windows NT 4.0, Windows 2000, or Windows XP. The computer cannot be running Windows 95, Windows 98, or Windows Millennium Edition.

/tempdrive:drive_letter: Directs Setup to place temporary files on the specified partition. For a new installation, Windows will also be installed on the specified partition. For an upgrade, the /tempdrive option affects the placement of temporary files only; the operating system will be upgraded in the partition from which you run winnt32.
/udf:id[,UDB_file] Indicates an identifier (id) that Setup uses to specify how a Uniqueness Database (UDB) file modifies an answer file (see the /unattend entry).

The UDB overrides values in the answer file, and the identifier determines which values in the UDB file are used. For example, /udf:RAS_user,Our_company.udb overrides settings specified for the RAS_user identifier in the Our_company.udb file. If no UDB_file is specified, Setup prompts the user to insert a disk that contains the $Unique$.udb file.

If you start the computer from the Windows product CD and run an unattended Setup, you cannot use the /udf command-line option for Winnt32.exe.

/unattend Upgrades your previous version of Windows 98, Windows Millennium Edition, Windows NT 4.0, or Windows 2000 in unattended Setup mode. Setup downloads the Dynamic Update files from Windows Update and includes these files in the installation. All user settings are taken from the previous installation, so no user intervention is required during Setup.
/unattend[num]:[answer_file] Performs a fresh installation of Windows in unattended Setup mode. Setup downloads the Dynamic Update files from the Windows Update Web site and includes these files in the installation. The specified answer_file provides Setup with your custom specifications. num

The number of seconds between the time that Setup finishes copying the files and the time Setup restarts. You can use num on any computer running Windows 98, Windows Millennium Edition, Windows NT, Windows 2000, or Windows XP.

answer_file

The name of the answer file. For more information about answer files, see the Microsoft Windows XP Deployment Guide.

Using the /unattend command-line option to automate Setup affirms that you have read and accepted the End-User License Agreement (EULA) for Windows. Before using this command-line option to install Windows on behalf of an organization other than your own, you must confirm that the end user (whether an individual or a single entity) has received, read, and accepted the terms of the Microsoft End-User License Agreement for Windows. OEMs who use this option must run Sysprep on the resulting installation before distribution to the end user. Sysprep will clear the product key, so that on the next boot of the system, the end user will have the opportunity to accept the EULA.

icon Return to top

Unattended Setup on a Remote Installation Server

When using the Remote Installation Server (RIS) to install Windows on a computer that has a bootable network card, specify the network card as the first bootable device and demote all others. You then provide the maximum possible number of methods for successfully deploying Windows to computers in your environment. For more information about using RIS, see [RemoteInstall].

One method to simplify this process is to modify the basic input/output system (BIOS) to specify the CD-ROM as the first bootable device in the computer, the floppy disk as the second device, and the hard disk as the third.