Gentoo Wiki




Almost every BIOS/firmware update needs DOS to work, this howto is about creating a USB flash drive to boot on FreeDOS and run those medieval programs

I've read a lot of Howtos about just that, most overly complicated, this one aims to be simple and clean.


You will need several packages to do that, most of which you should already have : syslinux, grub, cfdisk, and dosfstools.
If not, emerge them, no special USE needed.



First thing you need to do is create a partition, let's assume the usb flash drive is /dev/sdb :

# cfdisk /dev/sdb

Remove everything, create a primary partition, set its type to 0E (W95 FAT16 (LBA)), mark it bootable, write the partition table and quit.


Now you can format the partition in FAT16, you can try FAT32 but FAT16 is recommended :

# mkdosfs -F16 /dev/sdb1


There is a nice image of FreeDOS with all you need, you just have to copy a file from it to the partition :

# mount /dev/sdb1 /mnt/usb
# cd /mnt/usb
# wget
# unzip fdodin06.144
# rm -f


Next thing you need to do is make the USB flash drive boot on something, that would be GRUB. You will also need a file from Syslinux to boot FreeDOS.

# cd /mnt/usb
# mkdir grub
# cp /lib/grub/<your-arch>/* grub/
# cp /usr/lib/syslinux/memdisk .

A nice configuration for GRUB :

File: /mnt/usb/grub/menu.lst
title FreeDOS
        kernel /memdisk
        initrd /fdodin06.144

And finally, you can install GRUB :

# grub
grub> root (hd1,0)
grub> setup (hd1)
grub> quit
Note: GRUB might give you two "... failed (this is not fatal)" warnings, just ignore them.

Last touch

Now you can copy your BIOS update/whatever to the USB flash drive (/mnt/usb).

Last step : umount

# umount /dev/sdb1

That's it, you can boot on your USB flash drive. Once you are in FreeDOS, your flash drive will be c:\, enjoy...

External Links

Retrieved from ""

Last modified: Fri, 05 Sep 2008 09:49:00 +0000 Hits: 604