table of contents
MKOFBOOT(8) | System Manager's Manual | MKOFBOOT(8) |
NAME¶
mkofboot - format bootstrap partition and install the yaboot boot loader
SYNOPSIS¶
mkofboot [ -b|--boot device ] [ -o|--ofboot of-path ] [ -i|--install boot-file ] [ -C|--config config-file ] [ -m|--magicboot chrp-file ] [ --filesystem hfs|msdos|raw ] [ --nobless ] [ -M|--mount ] [ --hide ] [ --protect ] [ --nonvram ] [ --force ] [ -v|--verbose ] [ --debug ] [ -h|--help ] [ -V|--version ]
DESCRIPTION¶
This manual page explains mkofboot the initial installer for the yaboot(8) boot loader enabling GNU/Linux to be booted by OpenFirmware.
mkofboot does exactly the same thing as ybin(8) except that it erases and creates a new filesystem (specified by --filesystem) on the bootstrap(8) partition before copying the boot loader files to it. See the ybin(8) man page for more details on the installation process.
The bootstrap(8) need not and should not be mounted anywhere on your filesystem, especially not on top of /boot. Yaboot(8) is able to load the kernels from the ext2fs root partition so that is where they should be kept. Mkofboot will refuse to operate on the bootstrap(8) partition if it is mounted.
OPTIONS¶
NOTE: mkofboot uses the exact same command line options as ybin(8) so if you have already read the ybin(8) man page you can skip this section.
- -b, --boot device
- Install the boot loader onto the specified device. This device should be that of your bootstrap(8) partition. For example, if your bootstrap partition is located on your first primary IDE drive in the second partition, your device would be: /dev/hda2.
- -o, --ofboot of-path
- The OpenFirmware device path to the bootstrap(8) partition. This is needed so the first stage ofboot loader can be configured properly. It should include the OpenFirmware path including the partition number (but not any filename). Example: if your bootstrap(8) partition is /dev/hda2, the OF path will likely be hd:2. As of mkofboot 0.18 you no longer are required to specify this option. If left undefined mkofboot will attempt to figure out the OpenFirmware path automatically using the ofpath(8) utility. You should only need to define this option if ofpath(8) fails.
- -i, --install boot-file
- Use boot-file as the primary boot loader executable, instead of the default/usr/lib/yaboot/yaboot(8).
- -C, --config config-file
- Use config-file as the mkofboot/yaboot(8) configuration file instead of the default /etc/yaboot.conf.
- -m, --magicboot chrp-script
- Use chrp-script as the boot loader “wrapper”. This script is needed to either provide a boot menu for dual boot with MacOS or to load yaboot (due to an OpenFirmware bug).
- --filesystem hfs|msdos|raw
- Set the filesystem type that mkofboot will create on the bootstrap(8). The “raw” filesystem type causes mkofboot to copy the bootloader (the value of install= directly to the bootstrap(8) partition without creating a filesystem. “raw” is required on IBM hardware. CAUTION: this will destroy any data or filesystem on the bootstrap(8) partition (value of boot=) if you specify something like boot=/dev/sda you will destroy the partition table and lose ALL data on the disk. The default is HFS.
- -M, --mount
- Do not use the userspace hfsutils(1) to modify the bootstrap(8), instead try and mount the filesystem directly. NOTE: Attributes cannot be set on the filesystem or the boot loader files using this method, your system will NOT be bootable without modifying OpenFirmware's “boot-device” variable to something like: “hd:2,ofboot” (no quotes).
- --nobless
- Do not “bless” the root directory of the bootstrap(8) partition's filesystem. Only use this option if the bootstrap(8) partition is actually a MacOS boot partition. This option is ignored unless the filesystem is HFS, and is ignored when used with --mount.
- --hide
-
Set the invisible bit on all the boot loader files once copied to the bootstrap(8) partition. This setting is useful if you must install the boot loader onto a MacOS boot partition and do not with to see the boot loader files cluttering up the MacOS root directory. This option is ignored unless the filesystem is HFS, and will not work with --mount. - --protect
- Set the read-only bit on all boot loader files once copied to the bootstrap(8) partition. This setting is useful if you must install the bootloader onto a MacOS boot partition and want to discourage alterations/deletion of the boot loader. This option works for both HFS and MSDOS filesystems.
- --nonvram
- Prevent mkofboot from setting the OpenFirmware boot-device variable with nvsetenv(8).
- -v, --verbose
- This option causes mkofboot to be more verbose as it proceeds.
- -f, --force
- This option suppresses any confirmation questions.
- --debug
- This option causes mkofboot to output some boring details useful only for debugging mkofboot itself.
- -h, --help
- Print out usage information and exit.
- -V, --version
- Print out the version number and exit.
FILES¶
/usr/lib/yaboot/yaboot - boot loader executable /usr/lib/yaboot/ofboot - OpenFirmware boot script /etc/yaboot.conf - boot loader/mkofboot configuration file
ENVIRONMENT¶
- TMPDIR
-
The temporary directory mkofboot will use.
SECURITY¶
Temporary files are created with mktemp(1) it is important that your system use a secure mktemp(1) program otherwise mkofboot will be vulnerable to race conditions. The Debian mktemp is derived from OpenBSD and thus should be secure.
/usr/lib/yaboot/ofboot now contains code executed by /bin/sh (by mkofboot) it is thus critical that it not be writable by anyone but root. It is also critical that /etc/yaboot.conf not be writable by anyone but root since a different ofboot script could be specified there.
BUGS¶
Mkofboot should be able to take care of OpenFirmware variables as needed on IBM hardware.
AUTHORS¶
mkofboot(8) , and this man page written by Ethan Benson.
yaboot(8) was written by Benjamin Herrenschmidt.
REPORTING BUGS¶
Report bugs to <erbenson@alaska.net>
SEE ALSO¶
bootstrap(8), hfsutils(1), mkofboot(8), mktemp(1), mount(8), nvsetenv(8), ofpath(8), yaboot(8), yaboot.conf(5).
21 November 2001 | GNU/Linux PowerPC |