USB Boot Disk (freeDOS)
From NBSWiki
Contents |
Intro
Try this first, otherwise, the following works up to booting the USB key and get the syslinux "boot:" prompt...at which point I don't know which "kernel" to tell it to boot. Note that the unetbootin program is in portage:
emerge unetbootin
The only thing to note is that the files on the USB disk are in B:\
Creating a USB disk drive. These are quick notes without the fluff (as in most refs.) and should "just work". We assume all to be at sane defaults (such as first partition to be the boot partition. Most of the procedure is from "Creating a KNOPPIX or FreeDOS USB Stick in Linux"
Packages
Here are the required packages:
emerge -qa \ sys-boot/syslinux \ app-admin/mbr \ sys-fs/dosfstools
Modules:
loop
Installation
Here, all operations are performed on the disk denoted by $disk
export disk=/dev/sdb
Partition
Make a bootable Win95 FAT16 partition (type 0E, zero-E)
cfdisk $disk
Install MBR
install-mbr -v -p 1 $disk
Create FS
To force FAT16 (<512MB):
mkdosfs -F 16 -vc ${disk}1
Otherwise:
mkdosfs -vc ${disk}1
Syslinux to first partition
syslinux -s ${disk}1
Mount the USB disk
We obviously assume /mnt/usb to be usable:
mkdir -p /mnt/usb
mount -v ${disk}1 /mnt/usb
Install FreeDOS files
We get them from http://odin.fdos.org/odin2005/, any size should do, we just need the contents (so smaller should be better) cd /tmp && wget http://odin.fdos.org/odin2005/odin1440.img modprobe loop && mount -o loop odin1440.img /mnt/floppy cp -pr /mnt/floppy/* /mnt/usb && umount /mnt/floppy
Next ...
The odin1440.img image is an example and contains lots of utilities. One may desire something more stripped down or not. Now keep the USB disk mounted and add to your leasure or unmount and use it as you please.
umount /mnt/usb
Refs
Create_a_bootable_DOS_flash_drive
Creating a KNOPPIX or FreeDOS USB Stick in Linux
FreeDOS Flash Drive
