The essential Win2K multiboot troubleshooter: Planning partitions and file systems

Plan partitions and file systems in a multiboot Windows 2000 system

I receive a lot of e-mail concerning problems setting up multiboots. If you’re frustrated with trying to make two or more operating systems boot from Windows 2000 or Windows NT, don’t give up yet. I’ve managed to make four OSs boot from Windows 2000 boot.ini: NT 4, Win2K, Windows Me, and Red Hat Linux 6.2. It wasn’t easy, although I read all the instructions I could find. In this article, I offer you a planning guide developed from my experience. My next article on this subject will be a symptom/solution troubleshooting guide.

What this article isn’t
This article isn’t a step-by-step manual for creating a multiboot hard drive. There are plenty of dual-booting guides on the Internet, and they’re more or less accurate. But often these guides lack cautions, warnings, and error recovery steps. That’s what I try to make up for here. While this list of tips isn’t exhaustive, it will help you get to your goal.

I also assume that you’re going for the grand prize—making all these OSs work with the Windows 2000 or Windows NT boot loader. Programs such as System Commander, BootMagic, and Lilo (the Linux Loader), and utilities such as Bootpart can do a lot of the work for you and get you out of a jam, but I’m guessing you won’t be satisfied unless you can make Windows NT and 2000 bend their knees to you and call you boot master or mistress.
If you find this article helpful, check out TechRepublic's TechProGuild subscription resource, which offers in-depth technical articles covering a variety of IT topics including Windows server and client platforms, Linux, troubleshooting issues, data networking challenges, NetWare, and more. With a TechProGuild account, you can also read the complete text of popular IT industry books online. Sign up now for a FREE 30-day TechProGuild trial.
Your goal
Your mission is to create an NT/2000 boot loader that resembles the beauty shown in Figure A. But as they say, beauty is skin deep—only when you can highlight any of the operating system choices and have your machine successfully boot that OS will you be allowed to add the honorific “SuperTech” to your e-mail signature block.

Figure A
This fully loaded Windows 2000 boot menu starts four operating systems, including Linux.

Partition and file system planning
You must know the partitioning requirements of each operating system and slavishly follow those requirements. This includes understanding the limitations of the file systems you plan on using and the size of the partitions you need to hold your operating system. Since misunderstood file systems are often a cause of dual-boot problems, this topic is a good place to start.

Don’t mix partitioning software—use PartitionMagic
Don’t use anything but PartitionMagic to set up your drives. If you must use another program, however, stick to it. You can run into a lot of problems mixing partitioning programs, as there’s more than one way of calculating partition sizes and of formatting and labeling partitions. That’s true even in FDISK, which comes in several DOS, Windows, and Linux versions. Some versions of the Linux FDISK have bugs that could result in overlapping partitions and an unbootable NT. (You’ll receive a blue screen memory dump with the message Boot Sector Not Found.) Windows NT setup and Disk Manager have a “feature” deadly to DOS-based operating systems: the ability to create primary FAT16 partitions of 4 GB by creating an incredibly wasteful FAT cluster size of 64 KB. While this extra partition size may seem like a good idea, Windows 9x and DOS can only work with FAT partitions up to 2 GB using 32 KB clusters. Another problem occurs with disks larger than 8.4 GB. Because Windows NT setup is running in text (DOS) mode at that point, it can’t recognize this extra space, which is beyond the 1024 cylinder limit (I discuss this below).

Therefore, your safest bet (really your only choice for complicated partitioning schemes) is to partition your disk using PartitionMagic. FDISK, unlike PartitionMagic, can’t merge, split, move, undelete, resize existing partitions, or format partitions with the NTSF and Linux Ext and Swap file systems. PartitionMagic is one of the best problem-solving utilities you’ll ever buy. Make sure you purchase the latest version that can support Windows 2000.

Don’t enable large disk support using FDISK
If you do run FDISK and it asks whether you want to enable large disk support, make sure you answer No. If you answer Yes, it will format any partition greater than 512 MB as FAT32.

Use separate partitions for each operating system
I include this tip for the sake of inexperienced dual-booters. You’ve got to give each operating system a separate place to store its system files. Windows 9x and Me both place the operating system in the /Windows directory. Windows NT and 2000 both use /Winnt. Imagine the disaster you’ll create mixing files from different operating systems in the same folders. In addition, each Windows application you use will have to be installed more than once. That is, if you want to use Microsoft Word in all your Windows OSs, you’ll have to install it separately, along with all patches and updates, in the Me, NT, 9x, and 2000 drives. If you were to try this by installing all OSs in one partition, each version of Word would be placed in /Program Files, overwriting the previous version. It just wouldn’t work. Besides, you’ll most likely use the NTFS file system for NT and 2000, and FAT32 for 9x and Me. You can’t have both on the same partition.

Label all your partitions
If you’re multibooting four operating systems using good file system and partition planning, at some point you’ll have nine or more partitions! In addition, drive letters (in Microsoft OSs) or device numbers (in Linux) won’t be assigned in the order you created the partitions, won’t all be visible to all OSs, and the drive letters and partitions revealed may vary between Microsoft operating systems and Linux. Just wait until you’re in the middle of doing your installs, or if you manage to get all your OSs installed, just wait until you’re looking at Windows Explorer to try to figure out which data and which OSs are where. When you create partitions, create labels, such as Winme, Winnt, Win2K, Linux, etc. This tip leads directly into the next one.

Record your drive letter assignments
When you’re finished with PartitionMagic, you’ll have a table like the one in Figure B. When you’re finished setting up Linux, you’ll have information like that in Table 1. Before you do anything else, even if it’s only to take your next gulp of Mountain Dew, write this information on paper, including the size of each partition and its file system. At some point, Setup is going to want to know which partition to install in. Windows NT, for example, will offer to install in C:\Winnt. You’ll need to type in a different drive. Setup expects you to know this info, however. If you don’t, there’s no Browse feature and therefore no way to check without exiting Setup. Later, when you install applications, the installer will prompt you to accept a location or change it. When you’re told, for example, that Office will be placed in F:\Program Files\Microsoft Office, that’s not the time to ask yourself, “Which OS did I put in F?”

Linux setup will need you to indicate not only which partitions to use for boot, root, and swap files but also where to mount all the other partitions. In that case, labels may not be visible, and your best clue to which OS belongs to which drive number is going to be its size and file system type.

Figure B
Write down the disk letter assignments, labels, sizes, and file systems before you continue creating a multiboot hard drive.

Table 1: Linux drive assignments
Disk Number Description
hda1 C:\Boot
hda2 G:\Winnt4
hda5 D:\Data
hda6 E:\WinMe
hda7 F:\Win2K
hda8 RedHat62
hda9 Linux Swap
hda10 Linux /boot
When installing Linux, keep a record of the way it assigns numbers to your partitions.

First, you MUST create a small, bootable FAT16 primary partition
If you want your dual, triple, or quadruple boots to work under Windows NT or 2000, then this tip is nonnegotiable. FAT16, the 16-bit File Allocation Table file system used by MS-DOS, is the only file system all your operating systems are going to be able to boot from. MS-DOS, the original version of Windows 95, Windows NT, and Linux, can’t boot from FAT32, and Windows 9x and Me can’t boot from NTFS. None of the Windows products can boot from a Linux file system.

All Windows operating systems will automatically place part of their boot code in the Master Boot Record (MBR) on the first cylinder (cylinder 0) of the first primary partition on your first hard drive. This boot code points to the remainder of the boot information, which is stored on the partition containing that operating system, in that partition’s boot record. If you install Windows 98 in D, for example, Windows 98 setup will write the MBR with boot code pointing to the D partition’s boot sector. This code on D will guide the remainder of the boot process.

Linux is another story, as you can specify which partition contains its boot code during setup. After setup, you have to extract that Linux boot code and move it to the partition where Windows can read it, but the boot code must be below the 1024 cylinder limit, discussed in the next section.

Since the FAT16 file system is the only one that all operating systems can read and write to, this tip is worth repeating: Your first job is to create a small primary partition formatted in the FAT16 file system. This partition will be bootable and, when you’re finished, will contain all the boot code of all the operating systems you’ll be booting from Windows 2000. The MBR is limited to 512 bytes, so you won’t need much room. Since you’ll probably want to install DOS on that partition and have some room to play, any size from 10 to 50 MB is reasonable.

Avoid the dreaded 1024 cylinder limit
The 1024 cylinder limit is a concept about which much is written but little is clear. To boil it down to essentials, operating systems depend on the BIOS to load the boot code. The BIOS has a limitation that makes it unable to see past 1024 cylinders of a hard disk (cylinders 0–1023). Where this limitation actually is on your disk depends on how the BIOS and the partition table “fake” hard drive geometry by reporting a larger number of heads than a disk really has in order to obtain a large addressable space.

For example, a hard disk with 16 heads, 1024 cylinders, and 63 sectors of 512 bytes each per track contains 16 x 1024 x 63 x 512 bytes, or 528,482,304 bytes (528 MB). If the BIOS deliberately misreports the number of heads as 255, then voila!—it can read/write up to 8.4 GB.

For all practical purposes, on a modern computer with a large capacity hard drive, your 1024 cylinder limit will be at 8.4 GB. Any operating systems whose boot code is placed in a partition’s boot sector beyond 8.4 GB won’t be able to boot, so don’t install them there.

Earlier, I wrote that Windows operating systems will place their boot code partially in the MBR and partially in the boot sector of the partition they’re installed on. This tip refers to the additional boot code that’s not in the MBR.

PartitionMagic graphically shows this boundary by placing an arrow at the 1024 cylinder limit. Figure C shows this display.

Figure C
On this system, the 1024 cylinder limit occurs midway through the Linux root partition.

Each rectangle in the above illustration represents one partition. What can’t be seen is the label on the partition to the right of RedHat62. This small, 12-MB area contains the Red Hat boot code. Because it is beyond the 1024 cylinder limit, Red Hat won’t be able to boot from a hard drive—only from a floppy disk. To fix this, you could use PartitionMagic first to shrink and move the Red Hat system partition to make room for the Red Hat boot partition and then move the boot partition into the space created for it below the 8.4-GB boundary. Otherwise, you would have to delete, repartition, and reinstall Linux so that the code is placed within the 8.4-GB limit.

Size your partitions correctly
Now that you know some of the boundaries you need to avoid so that you can boot your operating systems, you need to take into consideration how large to make your partitions. Preformatting your partitions in advance rather than relying on OS setup programs will save you much trouble. The maximum partition size for a FAT16 partition is 2 GB. That would create a wasteful 32 KB allocation unit, however, so if you’re using FAT16 partitions, keep them below 1,023 MB to use a more reasonable allocation unit of 16 KB. FAT16 partitions are good for shared data storage since all operating systems can read them. You could create more than one data partition in FAT16 format.

For other file systems, use a reasonable partition size that will fit the operating system plus your applications. Windows NT has a maximum limit for a bootable partition of 7.8 GB. Using Windows NT’s Setup to format its system partition limits the size to 4 GB. Some DOS (IO.SYS) and NT (Ntloader.exe) system files must be placed within the first 2 GB of your hard drive. Using the technique mentioned above of creating a small FAT16 boot partition will help you avoid problems with DOS and NT system file limitations.

Install your operating systems in the right order
I’ll cover this topic more in the next article of this series. Just be aware that you need to know how different operating systems work together. For instance, Windows NT is intelligent about handling Windows 9x boot sectors, but the reverse isn’t true for Windows 9x. If you install Windows 98 after Windows NT, NT will extract 98’s boot code from the MBR before installing its own. It will use the code it extracted to enable you to dual-boot NT and 98. If you install NT first, however, Windows 98 may overwrite NT’s boot code in the MBR. As a consequence, you will no longer be able to boot NT. This example gives you an idea of why you must carefully consider the order in which you install the operating systems you want to multiboot. In our scheme, what you need to end up with is an intact Windows 2000 boot loader and copies of the boot code from all the other operating systems in files on the C:\ partition.

The most important step in successfully multibooting operating systems in the Windows 2000 or Windows NT boot loader is to carefully plan your partition and file system layout. In this article, I’ve gone over many issues that are left out of most instructions on setting up a multiboot. In my next article on this topic, I’ll troubleshoot problems specific to each operating system, including the boot order. If you have a tip you’d like to share, please please post a commentor write to Mike Jackman.
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.

Editor's Picks