Corrupted boot.ini file Might be the Culprit When You Can't Find an Existing Windows Installation
How to find and repair problems in boot.ini files
April 20, 2009
Recently I needed to repair a Windows Server 2003 installation. I wanted to repair it rather than install a fresh copy because I wanted to keep the files and data intact. I booted up the computer with the Windows 2003 CD-ROM and went through basic steps until I reached the point where it should have searched for previous installations. Instead, it went directly to the partitioning page.
I knew that Windows uses the boot.ini file, which is located in the root of the active partition, to determine whether there's a previous Windows installation. A missing or incorrect boot.ini file can cause Windows to not display the existing installations.
The contents of a boot.ini file might look something like this:
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)WINDOWS="Microsoft Windows 2003 Server, Standard"
As you can see, the boot.ini file contains two sections: the [boot loader] section and the [operating systems] section.
The [boot loader] Section
In the [boot loader] section, the timeout entry specifies how many seconds the boot menu will remain onscreen before trying to boot up the default OS, which the default entry identifies. Note that the default value for the timeout entry is 30 seconds, but you can change this value.
The default entry's value contains a pointer to the default OS. The pointer is made up of several elements, the first of which specifies the disk controller. If the OS uses IDE or SATA drives or if the OS uses a SCSI adapter that has an enabled BIOS, multi(0) is used. Although this example doesn't include it, you might see scsi(0) instead of multi(0), which indicates a SCSI controller is used. If there are two SCSI controllers, and the OS is associated with the second controller, the entry will read scsi(1).
The second element provides disk parameter information. When scsi() is the first element, the second element specifies the SCSI LUN being used. Like the first element, the second element's numbering starts with 0, such as disk(0), disk (1), and so on. When multi() is the first element, the second element will always be disk(0).
The third element specifies the physical disk. In this case, rdisk(0) refers to physical disk 1. For example, if you have two IDE controllers installed and both controllers have two drives attached
The first drive on first controller would be multi(0)disk(0)rdisk(0)
The second drive on first controller would be multi(0)disk(0)rdisk(1)
The first drive on second controller would be multi(1)disk(0)rdisk(0)
The second drive on second controller would be multi(1)disk(0)rdisk(1)
The fourth element indicates the partition that contains the OS. Unlike the other three elements whose numbering starts at 0, the partition element's numbering starts at 1. So, if there's one partition, it would be partition(1). If there are two partitions, you'd have partition(1) and partition(2).
The last element specifies the name of the folder where OS is installed. In this case, it's WINDOWS.
By putting it all together, multi(0)disk(0)rdisk(0)partition(1)WINDOWS tells you that the default OS is in the Windows folder on the first partition on the first drive on first controller. To find out which Windows OS version is installed, you need to look at the [operating systems] section of the boot.ini file.
The [operating systems] Section
The [operating systems] lists all the OSs installed. For example, the [operating systems] entry in
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)WINDOWS="Microsoft Windows 2003 Server, Standard"
lets you know that the default OS is running the Windows Server 2003, Standard Edition. Note that changing the entry here won't change what you see on boot menu.
Troubleshooting boot.ini Files
The best way to show you how to troubleshoot boot.ini files is with an example. Suppose you have two hard drives (C and D). Windows 2003 was initially installed on the first partition on the first drive (C), but you removed it and installed it on the first partition of the second drive (D). The boot.ini file should look like this
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(1)partition(1)WINDOWS
[operating systems]
multi(0)disk(0)rdisk(1)partition(1)WINDOWS="Microsoft Windows 2003 Server, Standard"
But for some reasons boot.ini file hasn't changed and looks like this
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)WINDOWS="Microsoft Windows 2003 Server, Standard"
To correct the file, you need to change rdisk(0) to rdisk(1) in the default entry in the [boot loader] section and in the entry in the [operating systems] section.
Now let's say you add Windows XP to the second partition on the D drive. The boot.ini file should look like
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(1)partition(1)WINDOWS
[operating systems]
multi(0)disk(0)rdisk(1)partition(1)WINDOWS="Microsoft Windows 2003 Server, Standard"
multi(0)disk(0)rdisk(1)partition(2)WINDOWS="Microsoft Windows XP Professional"
Oguzhan Oguz |
The default entry's value should still point to the first partition (1) where Windows 2003 is installed.
Now that you have two OSs installed, the boot.ini file will show you a boot menu at the beginning of system startup. The default OS (Windows 2003) will be highlighted. After 30 seconds, the default OS will boot, unless you select the other OS (XP).
About the Author
You May Also Like