Creating a New Bootable Windows 9x/200x Setup CD when you don't have the Original Bootable CD


Introduction

Why do we need to create bootable CD's? Well sometimes when you drop your Install CD on the floor, bend over to pick it up, accidently step on it instead, and then slide it along the floor with your foot. You are left with yet another expensive Coffee mug coaster. So you may need to create a new Bootable CD from your backup copy of the install files located on your Hard Disk which sadly don't contain a boot sector.

Another reason to perform this process is Microsoft frequently releases Service Packs which you can integrate with your original installation files using a technology Microsoft calls "Slip streaming". Doing this can bring future CD based installs up to the current service pack levels without doing it after you install.

If you use Linux at home and see enough of Windows at work This procedure will help you create a Windows Bootable CD under Linux

Following are step by step procedures on creating bootable CD's for Windows 9x and 200x under Linux

Creating a Windows 98 Bootable CD

You can create a Windows 98 Bootable CD by copying a windows Bootable CD Enabled Floppy  as follows

BUILD_DIR="win98cd"
mkdir $BUILD_DIR
mkdir -p $BUILD_DIR/boot
cd $BUILD_DIR

Copy the Windows 98 CD Aware Boot floppy image you want to the Hard Disk

dd if=/dev/fd0 of=boot/boot.img bs=1k count=1440

Add files and directories to the$BUILD_DIR note: make sure all the files work out to be <= CD Capacity minus Floppy Image Size(1.44MB)

This command is run from the $BUILD_DIR to create the iso file

mkisofs -r -b boot/boot.img -c boot/boot.catalog -o /home/user/bootcd.iso .

Adding a Windows W2K, XP, Longhorn Boot Sector to an ISO Image

Make a place to store the Install files

BUILD_DIR="winXPcd"

mkdir ~/$BUILD_DIR

Mount your CD and copy the files to your Hard Disk

mount /dev/hdc /media/cdrecorder
cp /media/recorder/* $BUILD_DIR

Download or extract a CD bootsector. 

Notes: 

If you downloaded a bootsector unzip it and then move it into the $BUILD_DIR

unzip wxp10.zip

This will leave a file named w2ksect.bin in the current directory

mv w2ksect.bin $BUILD_DIR/

Run the following command to burn the files to an on disk iso image

mkisofs -b w2ksect.bin -no-emul-boot \
     -c boot/boot.catalog -o /home/jamesm/longhorn5.iso \
     -boot-load-size 4 -no-iso-translate \
     -relaxed-filenames -l -J -N .

Editing the boot sector

The bootsector binary contains pointers to the setup program on the CD so it needs to point to the correct location. The interesting thing is you can edit the bootsector using a hex editor (such as khexedit or hexedit) to point to the correct files on the cd. For more on this checkout this site: Creating a Mult-Boot DVD

The setup loader code may be located in different directories on the CD

Windows XP has it's boot files in I386/bootfix.bin and I386/setupldr.bin

Longhorn Beta has it's boot files in BOOT/bootfix.bin and BOOT/setupldr.bin 

References

Creating a Mult-Boot DVD
Site containing information on Editing the Bootsector Code Under Windows

Bart's way to create bootable CD-Roms (for Windows/Dos)
This guy is amazing he has created a Batch scripted Boot Floppy/CD process based on Cygwin tools which runs on Windows


James McDonald