Dual-booting all versions of Windows and Linux

   Dual-Boot    |    Win 8    |    Win 7    |    Vista    |    Win XP/2K/NT    |    Win9x/Me    |    How to    |    Legacy 9x Tweaks    |    SiteMap   


Here: Home > Dual-Boot >

Create a new BOOTSECT.DOS

Last reviewed: April 2005

BTSECT creates Bootsect.dos if it's missing, incorrect, or corrupt.

A Windows cannot boot without its OS Boot Sector. This is a small bit of code at the start of the system partition (that's the Primary partition marked Active and it's also where all the bootfiles must reside). The sector's code is OS-specific because it points to a specific bootfile (NTLDR for a NT-type OS, or Io.sys for a Win9x/Me-type OS).

In a dual-boot of a Windows XP/200/NT with a Win9x/Me, the XP/2000/NT OS Boot Sector is still at the start of the system partition, while the OS Boot Sector for Win9x is stored in C:\Bootsect.dos. When XP/2K/NT is selected from the Boot Loader Menu, the XP/2K/NT Boot Sector is used in the normal manner and uses NTLDR. When, and only when, Win9x is selected, the OS Boot Sector held in Bootsect.dos is used (instead of the XP/2K/NT sector) and uses Io.sys. Please read Boot Sequence in a Windows Dual-Boot Explained if you require more information on this topic.

This page shows how to create a new Bootsect.dos
1. when Bootsect.dos is missing or corrupt, or
2. when setting up a dual-boot
even if the current OS Boot Sector on the system partition belongs to XP/2K/NT.

The utility used is THPC's (freeware). The download contains Btsect.bat and Bootread.scr (and a text file) which run in true MS-DOS from your Win9x/Me Startup Disk, or from an ordinary Win9x/Me boot disk.

• If using a Win98(+) Startup Disk, MUST be added to that floppy.

• If using an ordinary Win9x boot disk, you MUST ensure that floppy contains:
    Attrib.exe,, Debug.exe, (same Win9x/Me versions).

What Btsect.bat does

  1. All boot files on C:\ are first backed up to C:\Bootsbck\9x or C:\Bootsbck\NT.
  2. If found, an existing C:\Bootsect.DOS is renamed C:\Bootsect.PRV
  3. [Option] Run SYS C: to create a NEW Win9x OS Boot Sector on C:.
    (the Sys command overwrites the existing OS Boot Sector)
  4. [Option, if SYS was run] Restore saved Win9x boot files to C:\.
  5. Bootsect.dos is now created on C: (the first partition of first hard disk)
  6. The new Bootsect.DOS is backed up to c:\bootsbck\NT\bootsect.NEW

If dual-booted with Windows XP/2K/NT, the user must then restore the OS Boot Sector to one for Windows XP/2K/NT so that Windows can boot and control the dual-boot (read below, and Repair a Dual-Boot).

[top of page]

How to Use Btsect.bat

  1. Download (6 KB).
  2. Unzip (three files, 18 KB) to your boot disk for installed Win9x.
  3. If using a Startup Disk (Win98+), (6 KB) MUST ALWAYS BE ADDED to the Startup Disk.
    If using an ordinary Boot Disk (or Win95 Startup Disk), the floppy MUST contain these DOS files (same Win9x version):
    Attrib.exe,, Debug.exe,
  4. Cold boot with that floppy inserted.
  5. Type in at the A:\ prompt- and then press [Enter]
  6. Follow the on-screen instructions. Exit when finished.
  7. Then, to create or restore the dual-boot:
        Cold boot from XP/2000/NT CD (or Setup floppy 1)
        Press R to enter the Recovery Console (and then C for 2K)
        Type FIXBOOT at the prompt
        [NT users must select 'Inspect Boot Sector' instead of using the Recovery Console]

Missing DOS files can be copied from Win9x's \COMMAND\ folder, or from its CD, using Windows Explorer or DOS.

Note: If, and only if, you are stuck, you can try using any Win9x boot disk. However, the extra files added to that boot disk must be the same versions as the rest of the files on that boot disk. Mixing different versions does not work and should not be tried.

[top of page]

Btsect.bat Explained

In a Win9x + XP/2K/NT dual-boot, the first Primary (bootable, system) partition of the first hard disk always contains a XP/2K/NT Boot Sector. This first Primary is almost always the C: partition and its XP/2K/NT Boot Sector controls the initial part of boot up in this dual-boot. This will be true even if the Windows directories are installed elsewhere e.g. Win9x in D:\Windows and XP/2K/NT in E:\Winnt - boot control will still be from the first Primary (C:).

If Win9x is selected from the Boot Loader menu, Windows XP/2K/NT executes Bootsect.dos, simulating the Win9x system's normal boot procedure.

Btsect.bat uses the DOS Debug command to create an image of the current OS Boot Sector of the C: drive. That image is saved to c:\Bootsect.dos. Btsect.bat runs only from true/real MS-DOS. Note: Btsect saves the OS Boot Sector (512 bytes) irrespective of which OS created it.

Btsect.bat first backs up any Win9x or XP/2K/NT boot files it finds in root of C:. An existing Bootsect.DOS is saved as Bootsect.PRV

Use this utility only if C: is the PC system partition for a Windows 9x/Me (Win9x boots)
only if you are prepared to create one here (using the SYS C: command).

If using a third-party boot utility you should use its own Options.

If you currently have a Win9x Boot Sector (Win9x boots normally) then Btsect.bat will create a valid Win9x image of it in Bootsect.DOS

However, it is quite likely that you have a OS Boot Sector for XP/2K/NT, or the OS Boot Sector is corrupt. In these cases you should use the SYS Option from within Btsect.bat to first create a new Win9x Boot Sector on C:. A valid Bootsect.DOS is then created.

In all cases, when Btsect.bat has been run:
  Win9x will be bootable
  Win XP/2000/NT will not be bootable until its own OS Boot Sector has been restored.
Fortunately XP/2000/NT CD or Setup Disks cope with this quite reliably.

The download contains a text file with full instructions.

[top of page]

OS Boot Sector

It must be emphasized that it is the current OS Boot Sector of the first Primary partition (C:) that is copied. Therefore you must ensure that the current OS Boot Sector of C: is valid for Win9x, is not damager, and is not for the XP/2K/NT. Otherwise you would only create an image of a faulty, or a XP/2K/NT, OS Boot Sector.

If the PC boots naturally to Win9x, and not to XP/2K/NT, then C: is likely to be a valid Win9x Boot Sector.

However, do not rush to use the Sys option. Depending on circumstances your dual-boot 'may' be OK. If you can not dual-boot, you should first check the timeout= line in Boot.ini just in case you find it set to 0 AND the Default is set to Win9x. If that were the case then the OS Boot Sector could still be for XP/2K/NT but you never see the boot loader menu. If Timeout is 0 then set it to 15 and reboot (that 15 represents 15 seconds).

[top of page]

How to Edit Boot.ini

The Default OS and the Timeout settings are in Boot.ini.

Boot.ini can be edited from DOS or via the Control Panel. Be careful of typing errors if modifying Boot.ini because doing so may make your computer unusable.

From Control Panel:

  1. Boot to the Win XP/2K/NT.
  2. Go to Start > Control Panel > System > Advanced tab
  3. Under Startup and Recovery, click Settings.
  4. Under System startup, in the Default operating system list, click the OS that you want to start when you turn on, or restart, your computer.
  5. Now select the Display list of operating systems for check box,
    and then type the number of seconds for which you want the list displayed before the default OS starts automatically.
    You can also edit Boot.ini from here (click Edit).

Backup Boot.ini first.
Then from DOS Prompt or DOS:

  1. Type attrib -r -s -h c:\boot.ini
  2. Type edit c:\boot.ini
  3. Check that timeout does not =0. Or make it =15 or 20 or 25
  4. The default= will probably be for XP/2K/NT (but can be for Win9x)
  5. A line like C:\="Microsoft Windows 9x" must be present for a Win9x option.
  6. When finished, press Alt-F-X, and then S to Save.
  7. Type attrib +r +s +h c:\boot.ini

Remember: Always make a backup of Boot.ini before you edit it.

[top of page]

SYS Command

You don't need to use the SYS option if the current OS Boot Sector is for Win9x/Me.

Note: All versions of Win9x can boot from the same Win9x Boot Sector! But . . .
Note: All versions of Win9x must have their own system-specific boot files on C:\ !

SYS C: creates a new Win9x Boot Sector on C: (it will work with ALL Win9xs irrespective of the Win9x version creating it). It overwrites the current OS Boot Sector (which may be for Win XP/2000/NT but that can/must be repaired later).

BUT SYS also copies Win9x system-specific boot files from A: to C:.

The Win9x that made the Startup disk will be shown by Btsect.bat. It should match the Win9x installed. Using the correct version of Startup disk is important. An incorrect version of Startup disk will copy incorrect system boot files to C: !

Also Note: If a Win9x version of Msdos.sys does not already exist on the C: drive, then the Sys C: command will copy the version from the floppy over to C:. This floppy version is nearly empty (it's a dummy) and it will not boot your Win9x.

An incorrect version of Win9x Startup disk will sometimes work.
Btsect.bat first backs up all Win9x & XP/2K/NT boot files (before SYS can be run).
Then, if SYS has been used, Btsect.bat allows you to restore the Win9x boot files back to C:\. The correct Win9x system boot files will then be on C:\.
Problem solved? Well, maybe!
If you use an incorrect Win9x boot disk:
  a Me Startup disk WILL NOT LET YOU RUN SYS AT ALL (it checks C:\Msdos.sys).
  a 98 Startup disk WILL LET YOU RUN SYS after a warning (that can be ignored).
  a 95 Startup disk WILL RUN SYS without even warning you!
If you do use a boot disk made by an incorrect version of Win9x, then you MUST allow Btsect.bat to restore the Win9x boot files when you are asked!
This is for your information only, and is best avoided.

[top of page]

Repair XP/2K/NT

You can read about repairing a Windows XP/200/NT on the Repair a Dual-Boot page.

As you will have realised, a valid Win9x Bootsect.DOS can only be created when a Win9x Boot Sector exists. This inevitably means the XP/2K/NT Boot Sector must always be repaired after Bootsect.DOS has been created.

This applies whether or not you have to use the SYS command.

Fully research repairing the XP/2000/NT Boot Sector before you start.
Always backup Bootsect.dos, and all other boot files, before you execute a Repair.

In general, you boot up with the XP/2000/NT CD or Setup Disks, enter the Recovery Console,
and run FIXBOOT at the prompt (use Inspect Boot Sector for NT).

Running the repair is easier if you have made the XP/2K/NT Rescue Boot Disk as recommended by THPC.

Now Windows XP/2000/NT will boot again, and you should also be able to dual-boot to the Win9x.

The dual-boot function sometimes needs a little help:

If the Boot Loader menu is missing, copy
NTLDR & NTDETECT.COM from the i386 folder on the CD to C:\,
(or copy them from another PC).

If a Win9x boot option is missing from the Boot Loader Menu, you need to
edit C:\Boot.ini
Look in the [operating systems] section for a line like
C="Window 9x"
Add that line if it's missing. Those quotes (" ") ARE used. The line shown will work as it is.
Boot.ini is a Read-only, System, Hidden file on the root of C:\.

[top of page]


Some NT 4 users may encounter an error suggesting that Bootss is missing or corrupt. This is itself a wee bug! It is Bootsect.dos that is missing.

The Ntldr file displays the erroneous file name Bootss instead of the correct file name of Bootsect.dos. Microsoft has confirmed this Bootss error to be a problem in Windows NT version 4.0.

[top of page]

What Microsoft says on "Reconstructing BOOTSECT.DOS"

Microsoft says, when referring to Windows NT 3.1-4.0 (Microsoft Knowledge Base Article - 101789):

Bootsect.dos is created by Windows NT Setup. The OS Boot Sector found in sector 0 of drive C is copied into Bootsect.dos before Setup writes the Windows NT boot sector. (Setup will not overwrite an existing Bootsect.dos.) If you choose a previous operating system, Windows NT executes Bootsect.dos, simulating the previous operating system's normal boot procedure.

Because the information in Bootsect.dos is really created by the previous operating system, it is very difficult to re-create. You must transfer the BIOS parameter block (BPB) from the boot drive (C) at sector 0 into the boot code from the previous operating system and write this into Bootsect.dos. To do this, use the following procedure:

  1. Use the proper utility to regenerate a boot sector for the previous operating system. For example, if the previous operating system is MS-DOS, boot MS-DOS from a floppy disk and run the SYS C: command.
  2. Start Windows NT Setup from the boot floppy disk (this may be disk 1 of the Windows NT floppy disk set, the boot floppy disk for the Windows NT CD-ROM, or may have been created during a setup using WINNT.EXE), and initiate repairs by pressing R at the first Setup screen.
  3. Follow the instructions provided by Setup. When Setup presents you with the list of optional repair tasks, make sure you have enabled the "Verify boot files on your C: drive" item.
  4. Follow instructions until you see a message stating "Setup Repair is complete."

Bootsect.dos should now be restored to its original state. You should be able to boot your previous operating system.

Note that MS says "Setup will not overwrite an existing Bootsect.dos".
It appears a repair of XP/2K/NT does not always produce the required Bootsect.dos.

THPC suggests you should always create it yourself if/when you can!

[top of page]

Please remember that you alone are responsible for the consequences of any changes you make to your computer hardware or software.

Copyright © LarryM 1998-2015