First post, by Hans Tork
- Rank
- Newbie
A bit of a disclaimer before I begin. I have only tested this method on the systems I own for retro Win 9x gaming, which include a Win 95 system on the Socket 370 ASUS CUV4x board and a Win 98 build using a LGA775 Gigabyte board. Older sockets or systems might be incompatible. I do not know if this guide would work for you, so try this at your own risk. I would not be liable for any damage if you brick your system using this guide nor can I guarantee you that the installation of Win 9x using this method will result in a stable system. Also, the specific drive letter variables might change depending on your system. You have to make sure that you modify the drive letters and other variables posted in the guide as per your drive letters and system specifications. Some of the commands if applied on the incorrect drive letter might result in you erasing the contents of your system and losing valuable data.
As floppy drives and CD/DVD roms are becoming ever so hard to come by, I think this guide might end up helping a lot of people. What prompted me to write this guide was the lack of any well explained youtube tutorial or a vogons thread to get Win 9x working on a PC without a floppy or CD/DVD drive or even a USB port. I would say even LLMs or AI assistants end up giving wrong or misleading advice on how to do the installation. However, I did find some AI advice helpful especially with respect to certain linux commands.
TL;DR of the guide: We will use qemu to make an active dos partition on our unallocated drive using the FDISK command, format the drive using the FORMAT utility present and transfer over the necessary Win 9x files(io.sys, msdos.sys, command.com) to make the drive bootable with the Win 9x system of our choice.
Prerequisites and preparation
The guide uses Qemu, an open source emulator and virtualizer. I used the 8.2.2 version for this guide.
You need a way to connect the drive(we will call this drive/disk the target drive in this guide) using a modern PC that can run qemu. For qemu, any system will do. Just make sure it can support virtualization, is able to connect our retro target drive to qemu and has enough resources to emulate a Win 9x bootup using qemu. I used a Linux-based(ubuntu) system for running qemu.
The target drive/disk I use for my retro system is an Acer 128 GB SSD. I am using a SATA to USB adapter to connect it to my modern PC with Ubuntu 24.04. Before you start, make sure you know what drive letter has been assigned to the target drive/disk(the place where you want to install your OS). On ubuntu this is done using the lsblk command.
lsblk
I used the gparted utility to remove it`s pre-existing partitions/contents and make it unallocated. As you can see my SSD shows up as "sda" with 111.8 GB.
Using the gparted tool, I can make it unallocated and also see it`s status.(Make sure you are selecting the right drive using the drop down menu on the top right of the gparted utility.)
IMPORTANT: You have to make sure that the target drive/disk is unallocated. Otherwise the Win 9x booting procedure will fail. Failure to make the drive unallocated will invalidate the rest of the guide. Simply formatting it as a FAT32 partition, then transferring over the boot files or even using FDISK on a pre-formatted partition does not work and leads to errors while booting up.
Once we have ensured we have an unallocated drive, we now require a Win 98 or a Win 95 boot floppy disk image file. This is an img file that needs to have the FDISK and FORMAT utilities. The standard FDISK utility would do but there is a patched FDISK utility that actually allows you to partition larger drives. However, for our guide we can go ahead with the standard FDISK.
Finally, we need to have the setup/installation files(the Win95 or Win98 folder) of the Win 9x system we want to install on the system. I prefer getting the Win 95 OSR 2.1(without IE) setup file and the Win 98 se (with RLOEW patched cabs) setup file. I recommend reading some of the really helpful Win 9x installation guides from people like Leonardo among others before carrying out the actual Win 9x installation. This guide mainly serves as a pre-installation for Win 9x. Finally, having the drivers for your OS and other utilities is also suggested but this can be done at a later stage.
Also, this might not be a hard requirement but it really helps if the retro system you want to install Win 9x on has a PS/2 keyboard. I have often run into several annoying issues with an USB keyboard/mouse when installing Win 98se.
Making the primary active DOS partition using qemu
This part requires using the Win 9x boot floppy disk, preferably the iso file and having the target drive ready. Before using the drive, I would recommend unmounting it. On ubuntu I use,
sudo umount /dev/sda*
You can also use gparted or the disks utility of ubuntu.
Now we will create a virtual system using qemu to access our ssd target drive and have the floppy and CD images attached. Go to the directory where your Win 95 boot floppy and iso are. On my system, my Win 95 boot disk is named W95bootdisk.img, the IE4 removed Win 95 ISO file is named as Win95_OSR21_NoIE.iso and the hda as sda. I am emulating an intel i386 system with 64 MB of RAM. Honestly, the system specifications do not matter too much but a 64 MB x86 system works good. On the ubuntu terminal, I use the command as shown below in the directory where the image and iso files of Win 95 are:
sudo qemu-system-i386 \
-m 64 \
-boot a \
-fda W95bootdisk.img \
-cdrom "Win95_OSR21_NoIE.iso" \
-hda /dev/sda
Note we use the "boot a" command to boot from the Win 95 boot floppy and use the target drive "sda" as the qemu virtual hard disk. Once again, make sure that the target drive is selected. If you put the wrong drive and format it, you might end up formatting the drives of your host PC.
After you have executed this command, qemu should open up with this DOS prompt.
Type any option from 1-4(ie have a CD drive) and then press enter.
Run dir to make sure that the required utilities like FDISK and FORMAT are there. Now there is a way to have the patched FDISK here but we are going to keep this simple. We will later put the patched FDISK on our bootable partition.
dir
We have all the goodies. In case you do not have the FDISK or the FORMAT utility try another boot floppy image that has these two utilities.
Now we use the FDISK command.
FDISK
Put "Y" here and then press enter. Our next step is to create a primary DOS partition, select "1" and press enter, and then again "1" and enter. FDISK will verify the integrity of the disk. After it is done, it should ask us if we want to use the max available size for the primary DOS partition. Here I select no. Win 9x systems generally do well with partition sizes less than 32 GB. I create a 30 GB partition for the OS.
Note, the unpatched FDISK is unable to use the entire 128 GB SSD I have. For people with patched FDISK, they will probably get the correct size of their target disk. Hit enter and now we have a primary DOS partition.
There is one more step which is setting this partition as the active(boot partition). Press ESC which brings us back to the FDISK options menu and this time select Option 2(Set Active Partition), Select the partition number(1 in our case) and hit enter. This will make the partition as active. You can also double check if everything is alright by using the display partition option. Hit ESC till you get to the floppy prompt and then reboot your system/quit out.
Transferring the system files and making the drive bootable
Once you have rebooted or reinitialized the qemu system, you now have to format the C partition and transfer over the boot files and create the file allocation table. This can be done with the format command with the /s option enabled. Depending on your specs and the target drive, this might take a while. Type the command, press "Y" and wait. Once the format is done, choose any label for the drive. I use OSA as I like calling it the first partition with the OS.
format C: /s
The format should transfer over the three important files(io.sys, msdos.sys, command.com) for making the drive bootable. To be doubly sure, you can also use the SYS command to transfer over the system files.
SYS C:
The final step is transferring over the Win 9x setup files over to the C drive. Since we already have the ISO file attached as a CD drive(drive D:), we can actually copy it over to the C drive.
md c:\win95
copy D:\WIN95\*.* C:\WIN95
Alternatively, simply shut down the qemu system and copy over the setup files(with all tweaks and patches you want) from the Win 9x CD over to the target drive. This has no bearing on the installation. As after we have created a boot partition and transferred the system files, we can place any file on the target drive. I also recommend putting the driver files for your chipset/video/audio and some utlities. You can also put patched FDISK there to create secondary logical partitions. I generally make a few partitions for games and other stuff so that if I have to nuke the OS I can keep my games and utilities. As far as I am aware if you want to reinstall the OS you do not have to again make the target drive unallocated. Simply format the C drive again using qemu(with the bootfloppy attached as it has the FORMAT utility).
Now we reboot/quit out one more time and test our bootable C partition
Testing out the boot partition
To test out the drive, simply load up the target disk without any attachments. Here is what I use for my SSD.
sudo qemu-system-i386 \
-m 64 \
-boot c \
-hda /dev/sda
If everything went well, you should briefly see the Win 95 logo and be brought right into the C prompt. Now quit out or shutdown the system. You can transfer the target drive over to the actual Win 9x PC and then complete the installation over there by going to the setup directory and using setup command.
cd WIN95
setup
Thanks!!!