BIOSBOOT(8)         OpenBSD System Manager's Manual (i386)         BIOSBOOT(8)

NAME
     biosboot - i386-specific first-stage system bootstrap

DESCRIPTION
     This small program (roughly 256 bytes of code) is responsible for loading
     the second stage boot(8) program, which in turn, will load the kernel.
     It takes no input or options directly.

     In order for biosboot to load the second-stage bootstrap, it has a table
     inside it which describes boot(8)'s location.  biosboot must be installed
     by, and have its block table filled in by, the installboot(8) program.
     As this data is BIOS dependent, you must re-run installboot(8) each time
     you reinstall boot(8) or move your disk or software between machines
     and/or controllers.

     When biosboot receives control from either the BIOS or the MBR it will
     print the message:

           loading /boot

     followed by a dot for every successfully loaded block, and then put cur-
     sor on the next line right before switching into protected mode and
     transferring control to the just loaded /boot program.

DIAGNOSTICS
     Diagnostics consist of two error messages:

     Read error   Some kind of error returned by the BIOS read call. This
                  might be any media error, including bad sectors (common on
                  floppy disks), and invalid sectors (can occur with messed up
                  geometry translations).

     Bad magic    The just loaded /boot image contains a bad magic in its
                  header.  This might indicate some kind of hardware problem,
                  the boot argument to the installboot(8) command was not a
                  valid /boot program, or /boot or has been moved or changed.

     Other common reasons for these errors to appear is that a wrong BIOS ge-
     ometry has been used in installboot(8) for the device you are booting
     from.

NOTES
     The practice of making OpenBSD use the whole disk (ie: having biosboot as
     the MBR) has been deprecated, and will not work on certain BIOS versions.
     There is a lot of strange behaviour with different BIOS's, one of well
     known lobotomy cases is that the BIOS does not pass the right boot drive
     number to the biosboot program.  This is one of the main reasons that
     having biosboot as the MBR has been deprecated.

FILES
     /usr/mdec/mbr         Master Boot Record block
     /usr/mdec/biosboot    primary bootstrap
     /boot                 secondary bootstrap
     /bsd                  system code

SEE ALSO
     boot(8), boot_i386(8), fdisk(8), installboot(8)

BUGS
     It should do a checksum over the loaded /boot image, and check that
     against a value that installboot(8) has precomputed.

     There is no BIOS error number reported nor is the location of the error
     reported.

     You can pick your motherboard, and you can pick your BIOS, but you can't
     pick your motherboard's BIOS.

HISTORY
     This program was written by Michael Shalayeff for OpenBSD 2.1.  However
     it's based on bootstrap code from older versions of this operating sys-
     tem, other operating systems, other programs, and other people's work.

OpenBSD 2.9                    September 1, 1997                             2
