As we showed you in the article “Diagnosing Windows NT boot problems,” one of the files that can cause you the biggest headaches is the Boot.ini file. But what is the Boot.ini file? In this Daily Feature, we’ll take a look.
Be very careful when working with your server’s Boot.ini file. If you accidentally make a change in this file or make a change without knowing its impact, you may render your server unbootable. Make sure you have full system backups of your server before making any changes to this or any system files.
These Boot.ini’s were made for—walking?
The Boot.ini file exists in both Windows NT and Windows 2000. For the purposes of this Daily Feature, unless I specifically mention differences, any time I reference Windows NT, you can assume that the same information applies to Windows 2000.
You’ll only find the Boot.ini file on Intel-based servers. There are two reasons: First, Windows NT doesn’t use the Boot.ini file on RISC systems; and second, Windows 2000 only runs on Intel servers.
Boot.ini is a hidden, read-only system file that resides in the root of your server’s partition. When your server boots, it invokes the Ntldr program to boot NT. As a part of its boot process, the Ntldr program reads Boot.ini to find out what operating system to boot and where to find the operating system on your server’s hard drives.
Boot.ini contains two sections—the [boot loader] and [operating systems]. The [boot loader] section tells Ntldr which operating system to boot by default. The [operating systems] section defines the other operating systems that can be booted and where to find their boot files. A typical Boot.ini file would look like this:
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(5)\WINNT
[operating systems]
multi(0)disk(0)rdisk(0)partition(5)\WINNT=”Microsoft Windows 2000 Server” /fastdetect
multi(0)disk(0)rdisk(0)partition(4)\WINNT=”Windows NT Server Version 4.00″
multi(0)disk(0)rdisk(0)partition(4)\WINNT=”Windows NT Server Version 4.00 [VGA mode]” /basevideo /sos
C:\=”PC-DOS”
[boot loader]
The [boot loader] section contains two items. The first item is timeout=. The value you specify for this item defines the amount of time in seconds that the initial NT boot menu appears.
Windows sets the default value for this item to 30 seconds. The maximum value is 999. If you set this value to zero, the default operating system option will boot immediately after the NT boot menu appears. Alternatively, if you set the timeout value to –1, Ntldr pauses until you manually select an operating system.
The second item in the [boot loader] section is default=. This item controls which menu item in the [operating system] section to load by default. However, it’s not a pointer. It contains all of the same information as one of the entries in the [operating system] section.
[operating system]
The [operating system] section provides the information about which operating system to load. The [operating system] section can boot as many as 10 operating system configurations. You can enter more than 10 lines, but NT will ignore everything after the tenth line in the [operating system] section.
The entries on each line may initially look a little confusing. However, once you understand what the different variables on each line mean, you’ll quickly understand what’s going on. Each line contains a path, a description, and optional switches for the operating system.
The easiest part of the line to understand is the description. It’s the second part of each line and is enclosed by quotes.
The other parts of the line are more confusing. The first section, identifiable by all of the ()’s it contains, is known as the ARC path. ARC paths define the location of a file based on physical location. It breaks down the location based on the controller card, physical disk, and partition on which the directory is stored.
For example, let’s look at the ARC path multi(0)disk(0)rdisk(0)partition(1)\WINNT. The first part—either multi or scsi—identifies the physical disk controller number beginning with a value of 0. Scsi usually refers to a SCSI control with its BIOS disabled. Multi normally refers to an IDE drive, but it can also identify any non-SCSI controller or a SCSI controller with its BIOS enabled.
The second and third parts—disk and rdisk—are dependent on the multi or scsi values mentioned above. Only one is used, even though the ARC path always contains both entries. Both the disk and rdisk parameters indicate the physical disk used. If the first parameter is multi, the disk parameter is ignored. Alternatively, if the first parameter is scsi, the disk parameter is used and the rdisk parameter is ignored. Like the controller parameter, the counter associated with the hard disk parameter begins at 0 and increases from there.
The fourth part—partition—indicates the partition on the disk specified in either the second or the third part. Unlike the first three parts, the counter for the partition begins at 1 and goes up from there.
The final part is the path on the partition described in which the NT boot files are located. Normally, this path is set to WINNT.
The third part of the entry on an [operating system] line contains optional switches for the operating system. These switches allow you to boot special configurations of the operating system. An example of this is the familiar “VGA Mode” choice with its respective options. Switches are always preceded by a/. There are many different switches you can use, including:
- /basevideo—Causes NT to boot using the standard VGA driver, set to 640X480 resolution. This can be handy if your regular video driver becomes damaged.
- /baudrate—Specifies the baud rate to be used for debugging. If you do not set the baud rate, the default baud rate is 9600 with a modem attached, and 19200 for a null-modem cable.
- /bootlog—Makes Windows 2000 write a log of the boot to the file %SystemRoot%\NTBTLOG.TXT.
- /crashdebug—Turns on Automatic Recovery And Restart, which controls how Windows reacts when it crashes.
- /debug—Turns on the NT debugger which can then be activated by a host debugger connected via modem or null-modem cable. You’ll probably only use this if you’re a programmer.
- /debugport= comx—Specifies the com port to use for debugging.
- /fastdetect—Turns off serial and bus mouse detection at boot time.
- /maxmem:n—Specifies the maximum amount of RAM that Windows can use.
- /nodebug—Turns off debugging.
- /noguiboot—Turns off the GUI splash screen when the server starts.
- /noserialmice[=comx,y,z]—Disables detection of serial mice on the specified com port(s).
- /numproc=n—Only allows a certain number of processors to work in a multiprocessor system.
- /onecpu—Only uses the first CPU in a multiple processor system.
- /pae—Allows a server that supports physical address extension (PAE) mode to start normally. In safe mode, the computer starts using normal kernels even if the /PAE switch is specified.
- /safeboot:xxx—This switch forces Windows 2000 to launch in safe mode. You must specify one of three additional switches: MINIMAL, NETWORK, or DSREPAIR. The MINIMAL switch doesn’t load network support. The NETWORK switch corresponds to a safe boot with network support. The DSREPAIR (Directory Services Repair) switch causes NT to boot into a mode where you can restore Active Directory from backup.
- /sos—Displays the driver names while they are being loaded.
- /win95—You’ll probably never use this switch. It only works on a triple-boot system that has DOS, Win9x, and Windows NT installed. Specifying the /win95 switch directs NTLDR to boot the Win9x boot sector stored in BOOTSECT.W40.
- /win95dos—Like the /win95 switch, you’ll probably never use this switch. It only works on a triple-boot system that has DOS, Win9x, and Windows NT installed. Specifying the /win95dos switch directs NTLDR to boot the DOS boot sector stored in BOOTSECT.DOS.
The [operating system] section may contain entries that don’t include ARC paths. Normally, this represents an entry for a previous operating system, such as MS-DOS or Windows9x. If this is the case, you’ll see a conventional path such as c:/.
Conclusion
Many of Windows’ system files can be confusing. One of the most important system files Windows uses is the Boot.ini file. Boot.ini controls how Windows NT and Windows 2000 behave at boot time. In this Daily Feature, I’ve taken you on a tour of the Boot.ini file.
The authors and editors have taken care in preparation of the content contained herein but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for any damages. Always have a verified backup before making any changes.