Hack 85 Make a Bare Disk Bootable 
The
original PC hard drive
partitioning software comes with each
Microsoft operating system—either as the
DOS FDISK.EXE program or the
installation and disk management utilities with Windows NT, 2000, and
XP. Creating multiple partitions with FDISK can be a tedious and slow
process that requires deliberate planning and keeping track of your
work as you work your way through the process. Once you have
completed the partitioning processes with FDISK, you then need to
format each partition's filesystem or let the
operating system installation process do that for you.
If you are setting up to multiboot to DOS or Windows 9x by
adding Windows NT, 2000, or XP, you need only establish the first
system partition and format it with DOS: the Windows setup processes
take care of partitioning and formatting themselves, making the rest
of the process much easier. Complete documentation for
FDISK
can be found at
Microsoft's web
site at http://support.microsoft.com:80/support/kb/articles/q255/8/67.asp).
Additional tips for FDISK and alternative partitioning utilities can
be found at http://www.fdisk.com/fdisk/.
The basics of
partitioning are:
Determine how much space you want to
allocate for the primary DOS/Windows 9x partition, which will be the
foundation for multibooting using Windows's
capabilities or a third-party boot utility. Two to four GB should be
enough to hold the operating system and critical files for a few
games. It is not necessary to use
FDISK to partition the rest of the drive into an extended partition
and various logical partitions within the extended partition because
Windows 2000, XP, and Linux provide partitioning and formatting tools
in their setup process and disk management utilities. However, if you
do continue to create additional partitions, they will be FAT-32
partitions and need to be converted to NTFS if so desired (unless you
are installing Linux and need to access the same file space). Create an extended partition to be used
for additional operating systems and data storage space. You may
create only one extended partition, which can be split into different
logical partitions and drives. Determine how much space you want to preallocate for one or
more additional operating systems—perhaps 10-30 GB for Windows
2000 and another 10-30 GB for Windows XP, depending on the size of
your drive. Remember that 2000 and XP can share files on either
FAT-32 or NTFS partitions, so you may wish to allocate a mere 4-6 GB
to hold each operating system and leave the remainder of the drive
for applications and data storage. Allow space for applications that
may be unique to each operating system. Create logical drive areas in the extended partition for each
operating system and for data storage as described in the preceding
item.
9.2.1 Partitioning Quick Steps with FDISK With
the preplanning completed, you are ready
to create your partition(s), format the drive, and then begin the
operating system installation processes. The process is
straightforward, but the changes are permanent.
Boot with a DOS diskette or bootable CD
containing the FDISK.EXE program. Use a Windows
98 or Me boot diskette to get a version of MS-DOS and the FDISK and
FORMAT programs that support large hard drives and FAT-32. At the DOS
prompt, execute the FDISK program. Select large-disk support, as
shown in Figure 9-1. If you elect not to enable
large-disk support, DOS and your partitions will be limited to 2 GB
in size and you will not be able to create extended partitions.
 At the FDISK menu, shown in Figure 9-2,
select option 4 to view any existing partitions: note what you find
for DOS and non-DOS partitions including volume labels.
  |
If your PC lacks a diskette drive to boot from, you can use
Symantec GHOST or Ahead's Nero program to create a
bootable CD from a bootable
DOS image containing the programs you need.
Many variations of DOS diskette images are
available from http://www.bootdisk.com. Another alternative
is the Ultimate Boot CD, http://www.ultimatebootcd.com, which contains
many useful disk utilities. |
|
If there are existing partitions, you will need to delete them
so you have a clean slate to work from. Press Escape to go back to
the main FDISK menu and select option 3 to delete any and all
existing partitions, as shown in Figure 9-3. This
may be an iterative process performed until there are no more
partitions on the hard drive. Next, return to the main menu.  |
If you have some partitions that FDISK refuses to recognize, boot from the rescue disk mentioned
in [Hack #50],
use that
disk's utilities to delete the sticky disk
partition, shut down, and reboot into DOS when you are done.
|
|
Select option 1 to create a
primary DOS partition. You do not need and probably do not want to
make one partition using the entire drive, so instead make a
modest-size DOS-only partition, as in Figure 9-4.
FDISK will let you select the size of the partition by percentage of
the whole drive or a specific number of megabytes.
When you have
created the primary DOS partition, return to the main FDISK menu.
  |
If you will be
multibooting and one of your operating systems will be DOS or Windows
9x-Me, that operating system must be installed on the first
partition. |
|
Select option
2 and make the first partition active/bootable, as in Figure 9-5. You may quit FDISK at this point, leaving the
rest of the partitioning up to subsequent Windows or Linux
installation processes. If you decide to stop here, restart the
system so you can format the primary partition.  If
your alternate operating system will be Windows 9x-Me and use the
rest of the drive, select option 1 to create an extended partition in
the remaining drive space. You may skip this step and Step 7 if your
second and subsequent operating systems will be Windows NT, 2000, XP,
or Linux, since they can partition and format when they are
installed. Create logical drives
within the extended partition—one logical drive using a
fraction of the remaining space per operating system. Return to the
main FDISK menu when finished. Exit FDISK and reboot your PC from diskette so you can format
the primary partition.
9.2.2 Formatting Once
the
primary partition is created and you are through with any additional
partitioning, you need to establish a bootable filesystem in the
first/primary/active
partition as a place for
the boot manager to start from. The DOS FORMAT program
is very simple (see Figure 9-6). To format a hard
drive and make it bootable, use the following command:
FORMAT C: /S

That's it. You're formatting
drive C: to be a bootable system partition (with the
/S).
When the formatting is finished, drive C:
will be bootable but will contain nothing more than boot information
and the main DOS program COMMAND.COM.
I recommend making the partition bootable with
/S for these reasons:
In case you want to try booting from
the hard drive to make sure things are OK. Some versions of Windows setup check for
the existence of a bootable drive before installing. In case you want to copy Windows
installation files to the hard drive and install from there [Hack #88] . If you are installing an upgrade version
of Windows that checks to see if DOS exists before proceeding.
At this point, you can leave
the partition as is, copy more DOS files onto the drive, or install
Windows 95, 98, or 98SE and then any applications or games you
prefer. The next step is to install other operating systems (such as
Windows NT, 2000, XP, or Linux) in the unpartitioned or unformatted
with separate disk drives, follow the steps in this hack for your
DOS/Windows 9x drive, then let Windows NT, 2000, or XP install onto
your second hard drive. The initial boot files will be installed on
the first hard drive and the second operating system itself on the
second drive. The second drive will not be bootable, so the first
drive must remain in the system. If the first drive fails or is
reformatted, you will have no access to the operating system(s) on
the second drive.
|
Main Menu
|