Advanced Unattended Installs

Use $OEM$ to solve new network cards' installation problems

Last December, I bought a Compaq Presario 4860 that didn't want me to install Windows NT. The Presario shipped with the OSR2.1 version of Wintendo (oops, I mean Windows 95), and its hard disk came preformatted as FAT32--as if I'd buy a 333MHz computer with 128MB of RAM and run only Win95 on it.

When I tried to repartition the disk as a 2GB FAT disk, Win95 insisted on repartitioning the entire disk to FAT32 and reinstalling the operating system (OS). I called Compaq technical support. The representative I spoke with told me that the Presario doesn't have a hidden switch to let me reinstall Win95 without repartitioning the disk, and that Compaq wouldn't support the computer if I installed NT on it.

Thank goodness for PowerQuest's PartitionMagic (which you can download from PartitionMagic let me resize the 8GB FAT32 disk to 2GB, then converted the disk from FAT32 to FAT without damaging one byte of data. If you don't have PartitionMagic, get it.

After repartitioning the hard disk to FAT, I was ready to install NT on the system. When I performed an attended setup on the Presario, NT installed and ran like a champ. However, when I tried to perform an unattended NT installation on the machine, I ran into trouble.

Unattended Installation Basics

NT Setup is good at detecting hardware, but it can't detect hardware it doesn't look for.
I keep a copy of the i386 directory on the hard disks of the machines I have NT licenses for, and I use winnt /b or winnt32 /b to install and reinstall NT. For unattended installations, I use (and recommend highly) two tools. The first tool is GHOST, a program that copies a disk partition or logical drive to another drive or a network server. You can purchase GHOST or download a trial version at

The other tool is an unattended installation script, an ASCII file I created to answer all the questions that NT asks during setup. Writing a basic setup script is simple with the help of NT Setup Manager, which you can find in the \support\opk\n subdirectory of the NT Server CD-ROM, in which n stands for the NT platform you're using. Setup Manager creates an ASCII setup script that you can alter if you need to. (For details about writing setup scripts for unattended installations, see Christa Anderson, "Designing Unattended NT Installations," March 1997.) Then, you provide the NT setup program (winnt.exe or winnt32.exe) with the setup script's name and i386's location. For example, if you save the ASCII file as C:\unattend.txt and i386 is at C:\i386, type

winnt /b /s:c:\i386 /u:c:\unattend.txt

from DOS or the Win95 safe mode command prompt, or

winnt32 /b /s:c:\i386 /u:c:\unattend.txt

from NT to start the installation process. Add the line


to the setup script's \[Unattended\] section, and you have everything you need to perform an unattended installation. Usually.

Smooth Installations on New Machines
The problem I ran into with the Presario is the same problem I've faced with many new computers: NT 4.0 shipped during summer 1996, but many new machines have video cards, network cards, and SCSI cards that didn't exist in 1996. NT Setup is good at detecting hardware, but it can't detect hardware it doesn't look for. The Presario has a 3Com 3C900 EtherLink PCI card. The 3C900 NIC runs fine under NT, but its drivers aren't on the original NT Server 4.0 CD-ROM.

I used NT Setup's OEM Preinstall feature to automate NT's detection of the 3C900 NIC. To add a NIC to the list of hardware NT automatically detects, you need a functioning copy of NT on the computer housing the NIC, the NIC's installation files (the drivers disk), and an ASCII setup script that's complete except for instructions for setting up the NIC.

You need to install the drivers manually on the first computer you install the NIC on so you can gather the information you need to perform subsequent unattended installations. Then, you need to perform a series of steps.

First, determine the internal product name of the NIC. For example, the 3C900's internal product name is El90x. To find the NIC's internal product name, look in the Registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\1. The value for the ProductName entry is the NIC's internal product name.

Second, add the line

OemPreinstall = Yes

to the \[Unattended\] section of your setup script to tell NT Setup that you're going to use a new driver. If you add the lines

NoWaitAfterTextMode = 1

NoWaitAfterGUIMode = 1

to the setup script's \[Unattended\] section, you'll remove two instances in which NT Setup would otherwise wait for you to press a key before continuing.

Third, create $OEM$ and $OEM$\C\DRIVERS directories in \i386. In my example, you'll have directories named C:\i386\$OEM$ and C:\i386\$OEM$\C\DRIVERS. Place the NIC's installation files in C:\i386\$OEM$\C\DRIVERS. NT Setup will automatically create a C:\DRIVERS directory and copy everything in C:\i386\$OEM$\C\DRIVERS to C:\DRIVERS.

Fourth, insert the following lines into your setup script:


InstallAdapters = Adapterslist

DoNotInstallInternetServer = Yes

JoinDomain = BigDomain

CreateComputerAccount = Administrator,password


NIC'sInternalName = adapterparameters, c:\drivers


Replace the variable BigDomain in the fourth line with the name of the domain you want the machine to join. Replace Administrator,password in the fifth line with the name and password of a domain account with administrator privileges, or remove the fifth line and create an account in the domain for the machine before performing the installation. Replace NIC'sInternalName in the seventh line with your NIC's internal product name, which you identified in step one.

Your setup script probably has \[Network\], \[Adapterslist\], and \[adapterparameters\] sections. The previous lines replace those sections. However, if your \[Network\] section contains lines that refer to protocols and services for NT to load, leave those lines in your setup script.

You might need to specify parameters such as the I/O address, IRQ, or media type for older NICs in the \[adapterparameters\] section. The \[adapterparameters\] section of my example is empty because the 3C900, like most modern PCI cards, is self-configuring.

If you're configuring an ISA or PC Card NIC, you might have to specify adapter parameters. The names of the parameters you need to include vary from card to card. To determine which parameters you need to specify, you must do a little Registry digging. In the same Registry key (HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\1) where you found the ProductName value in step one, you'll find the ServiceName value entry. The ServiceName value is usually just the ProductName value followed by a 1; the 3Com NIC's ServiceName entry is El90x1. The ServiceName value is the name of a key in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services that controls the NIC. That key contains the Parameters key, which you use to set the NIC's parameters in your setup script.

For example, I have an older computer that has a 3Com ISA Ethernet card. The ISA NIC is not self-configuring, so I must tell NT Setup that the NIC is set to I/O address 300 and IRQ 10. The NIC's ProductName is Elnk3, and its ServiceName is Elnk31. In the computer's Registry, the key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Elnk31\Parameters contains value entries InterruptNumber = 0xA and IoBaseAddress = 0x300. I specify the \[adapterparameters\] and \[Adapterslist\] sections of the ISA NIC's setup script as follows:


Elnk3 = adapterparameters, c:\drivers


IoBaseAddress = 768

InterruptNumber = 10

Notice the IoBaseAddress' value of 768 and the InterruptNumber's value of 10. The Registry displays the values in hexadecimal, but NT setup scripts need numeric values in decimal, so I converted the values.

After you build the setup script, feed it to winnt or winnt32. In about half an hour, you'll have a fresh copy of NT on your system, even if the system uses new or unusual NT-compatible hardware.

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.