Makebootfat Bootable FAT Disk Creation(1) | General Commands Manual | Makebootfat Bootable FAT Disk Creation(1) |
makebootfat ‐ Makebootfat Bootable FAT Disk Creation
makebootfat [options] IMAGE
This utility creates a bootable FAT filesystem and populates it with files and boot tools.
It is mainly designed to create bootable USB and Fixed disk for the AdvanceCD project.
The official site of AdvanceCD and makebootfat is:
In Linux disk devices are named /dev/hdX or /dev/sdX where X is a letter. Partition devices are named /dev/hdXN or /dev/sdXN where X is a letter and N a digit.
In Windows disk devices are named \\.\PhysicalDriveN where N is a digit. Partition devices are named \\.\X: where X is a letter, but sometimes \\.\X: is a disk and not a partition, for example on floppies and on all the USB Mass Storage devices without a partition table.
To make a bootable FAT using syslinux you must use the ‐X option for syslinux version 2.xx or the ‐Y option for syslinux version 3.xx. You must also copy in the root directory of the disk the files:
ldlinux.sys The syslinux loader.
syslinux.cfg The syslinux configuration file.
linux The Linux kernel image (the file name may be different).
initrd.img The initrd filesystem (the file name may be different or missing).
You must also specify the ‘ldlinux.bss’ boot sector with the ‐b option and possibly the ‘mbr.bin’ MBR sector with the ‐m option. Both the sector images are present in the syslinux package.
For example:
‐Y \
‐b ldlinux.bss ‐m mbr.bin \
‐c ldlinux.sys ‐c syslinux.cfg \
‐c linux ‐c initrd.img \
image
To make a bootable FAT using loadlin and FreeDOS you must copy in the root directory of the disk the files:
kernel.sys The FreeDOS kernel. Remember to use the ˝32˝ kernel version to support FAT32.
command.com The FreeDOS shell.
autoexec.bat Used to start loadlin.
loadlin.exe The loadlin executable.
linux The Linux kernel image (the file name may be different).
initrd.img The initrd filesystem (the file name may be different or missing).
You must also specify the FreeDOS boot sectors available on the FreeDOS ‘sys’ source package with the ‐1, ‐2, ‐3 option. For the MBR you can use the sectors image available on the FreeDOS ‘fdisk’ source package.
For example:
‐E 255 \
‐1 fat12com.bin ‐2 fat16com.bin ‐3 fat32lba.bin \
‐c kernel.sys ‐c command.com \
‐c autoexec.bat ‐c loadlin.exe \
‐c linux ‐c initrd.img \
image
The BIOS USB boot support is generally differentiated in three categories: USB‐HDD, USB‐FDD and USB‐ZIP.
The USB‐HDD (Hard Disk Drive) standard is the preferred choice and it requires the presence of a partition table in the first sector of the disk. You can create this type of disk using the ‐m option.
The USB‐FDD (Floppy Disk Drive) standard requires the presence of a filesystem starting from the first sector of the disk without a partition table. You can create this type of disk without using the ‐m option.
The USB‐ZIP (ZIP Drive) standard requires the presence of a device with a very specific geometry. Specifically, it requires a geometry with 32 sectors and 64 heads. It also requires the presence of a partition table with only a bootable partition in the fourth entry. You can create this type of disk using the ‐m and ‐Z option.
Generally these standards are incompatible, but using the ‐m, ‐F and ‐Z options you can create a disk compatible with all of them.
To use the ‐F option, the MBR image specified must follow the constrains:
And example of such image is in the ‘mbrfat.bin’ file.
For example to create a syslinux image:
‐Y \
‐Z \
‐b ldlinux.bss ‐m mbrfat.bin ‐F \
‐c ldlinux.sys ‐c syslinux.cfg \
‐c linux ‐c initrd.img \
image
and for a FreeDOS and loadlin image:
‐E 255 \
‐Z \
‐1 fat12com.bin ‐2 fat16com.bin ‐3 fat32chs.bin \
‐m mbrfat.bin ‐F \
‐c kernel.sys ‐c command.com \
‐c autoexec.bat ‐c loadlin.exe \
‐c linux ‐c initrd.img \
image
Please note that FreeDos has some problems booting from USB. It works only on very few conditions.
To exclude some files or directories in the image copy, you can use the ‐x option using the same path specification which are you using for the image directory.
For example, if you need to exclude the ‘isolinux’ and ‘syslinux’ subdirectories from the ‘image’ directory you can use the command:
‐x image/isolinux \
‐x image/syslinux \
image
This file is Copyright (C) 2004, 2005 Andrea Mazzoleni