From 2a2fb130ab9c696d66929f9c5da489e3f0c55480 Mon Sep 17 00:00:00 2001 From: Thomas Nikolajsen Date: Sat, 6 Sep 2008 12:14:08 +0000 Subject: [PATCH] Adapt manual pages to change in boot code to support using either / or /boot on boot file system. --- sys/boot/common/loader.8 | 64 +++++++++++++++++++++++++++++++++----------- sys/boot/forth/loader.4th.8 | 22 +++++++-------- sys/boot/forth/loader.conf.5 | 16 +++++------ 3 files changed, 68 insertions(+), 34 deletions(-) diff --git a/sys/boot/common/loader.8 b/sys/boot/common/loader.8 index 96879d57c3..daf5459f76 100644 --- a/sys/boot/common/loader.8 +++ b/sys/boot/common/loader.8 @@ -23,11 +23,11 @@ .\" SUCH DAMAGE. .\" .\" $FreeBSD: src/sys/boot/common/loader.8,v 1.57 2003/06/29 20:57:55 brueffer Exp $ -.\" $DragonFly: src/sys/boot/common/loader.8,v 1.21 2008/09/02 11:50:46 matthias Exp $ +.\" $DragonFly: src/sys/boot/common/loader.8,v 1.22 2008/09/06 12:14:08 thomas Exp $ .\" .\" Note: The date here should be updated whenever a non-trivial .\" change is made to the manual page. -.Dd September 2, 2008 +.Dd September 6, 2008 .Dt LOADER 8 .Os .Sh NAME @@ -44,10 +44,39 @@ On IA32 (i386) architectures, it is a client. It is linked statically to .Xr libstand 3 -and usually located in the directory +and located in the +.Pa /boot +or +.Pa / +directory. +.Pp +If a +.Pa /boot +directory exist on the boot file system, then +.Dq /boot/ +is prepended to all relative file names used by +.Nm . +This makes it possible to locate all files used by +.Nm +in either +.Pa / +or +.Pa /boot +directory on the boot file system. +If boot and root are the same file systems, then files used by +.Nm +are located in .Pa /boot . +If boot and root are different file systems, then files used by +.Nm +are located in +.Pa / +on the boot file system, which is mounted as +.Pa /boot +on the root file system when the kernel is running. .Pp -It provides a scripting language that can be used to +.Nm +provides a scripting language that can be used to automate tasks, do pre-configuration or assist in recovery procedures. This scripting language is roughly divided in @@ -78,7 +107,7 @@ is set to 24. Next, .Tn FICL is initialized, the builtin words are added to its vocabulary, and -.Pa /boot/boot.4th +.Pa boot.4th is processed if it exists. No disk switching is possible while that file is being read. The inner interpreter @@ -91,9 +120,9 @@ which is .Tn FICL Ns 's default. After that, -.Pa /boot/loader.rc +.Pa loader.rc is processed if available, and, failing that, -.Pa /boot/boot.conf +.Pa boot.conf is read for historical reasons. These files are processed through the .Ic include @@ -177,7 +206,7 @@ For debugging purposes only. .Pp .It Ic help Op topic Op subtopic Shows help messages read from -.Pa /boot/loader.help . +.Pa loader.help . The special topic .Em index will list the topics available. @@ -327,7 +356,7 @@ If set to no .Ic autoboot will be automatically attempted after processing -.Pa /boot/loader.rc , +.Pa loader.rc , though explicit .Ic autoboot Ns 's will be processed normally, defaulting to 10 seconds delay. @@ -500,6 +529,11 @@ Overrides the compile-time set value of .Va TCBHASHSIZE or the preset default of 512. Must be a power of 2. +.It Va vfs.root.mountfrom +File system type and partition, separated by colon, +for kernel root file system. +For example +.Dq hammer:da8s1a . .El .Ss BUILTIN PARSER When a builtin command is executed, the rest of the line is taken @@ -690,7 +724,7 @@ The constants and .Dv O_RDWR are defined in -.Pa /boot/support.4th , +.Pa support.4th , indicating read only, write only, and read-write access, respectively. .It Xo .Ic fread @@ -781,14 +815,14 @@ Notice that a kernel must be loaded before any other command is attempted. .Bd -literal -offset indent load kernel -load -t userconfig_script /boot/kernel.conf +load -t userconfig_script kernel.conf .Ed .Pp Load the kernel, a splash screen, and then autoboot in five seconds. .Bd -literal -offset indent load kernel load splash_bmp -load -t splash_image_data /boot/chuckrulez.bmp +load -t splash_image_data chuckrulez.bmp autoboot 5 .Ed .Pp @@ -797,14 +831,14 @@ This would be needed in a system with two IDE disks, with the second IDE disk hardwired to wd2 instead of wd1. .Bd -literal -offset indent set root_disk_unit=2 -boot /boot/kernel +boot kernel .Ed .Pp See also: .Bl -tag -width /usr/share/examples/bootforth/X -.It Pa /boot/loader.4th +.It Pa loader.4th Extra builtin-like words. -.It Pa /boot/support.4th +.It Pa support.4th .Pa loader.conf processing words. .It Pa /usr/share/examples/bootforth/ diff --git a/sys/boot/forth/loader.4th.8 b/sys/boot/forth/loader.4th.8 index e643de81b1..b700dd6ca8 100644 --- a/sys/boot/forth/loader.4th.8 +++ b/sys/boot/forth/loader.4th.8 @@ -23,9 +23,9 @@ .\" SUCH DAMAGE. .\" .\" $FreeBSD: src/sys/boot/forth/loader.4th.8,v 1.14 2002/08/13 15:09:33 ru Exp $ -.\" $DragonFly: src/sys/boot/forth/loader.4th.8,v 1.5 2008/09/02 11:50:46 matthias Exp $ +.\" $DragonFly: src/sys/boot/forth/loader.4th.8,v 1.6 2008/09/06 12:14:08 thomas Exp $ .\" -.Dd September 2, 2008 +.Dd September 6, 2008 .Dt LOADER.4TH 8 .Os .Sh NAME @@ -38,7 +38,7 @@ is a set of commands designed to manipulate .Xr loader.conf 5 files. The default -.Pa /boot/loader.rc +.Pa loader.rc includes .Nm and uses one of its commands to automatically read and process @@ -64,7 +64,7 @@ through the command: .Dl include loader.4th .Pp This line is present in the default -.Pa /boot/loader.rc +.Pa loader.rc file, so it isn't needed (and should not be re-issued) in a normal setup. .Pp The commands provided by it are: @@ -92,13 +92,13 @@ so it can be stopped. .Pp .It Ic start Reads -.Pa /boot/defaults/loader.conf , +.Pa defaults/loader.conf , all other .Xr loader.conf 5 files specified in it, and then proceeds to boot as specified in them. This is the command used in the default -.Pa /boot/loader.rc +.Pa loader.rc file, and it uses the .Pa autoboot command (see @@ -114,7 +114,7 @@ first. Like .Ic start , reads -.Pa /boot/defaults/loader.conf +.Pa defaults/loader.conf and all other .Xr loader.conf 5 files specified in it. @@ -174,17 +174,17 @@ command. .El .Sh EXAMPLES Standard -.Pa /boot/loader.rc : +.Pa loader.rc : .Pp .Bd -literal -offset indent -compact -include /boot/loader.4th +include loader.4th start .Ed .Pp Load a different kernel with the standard configuration: .Pp .Bd -literal -offset indent -compact -set kernel="/boot/kernel.old" +set kernel="kernel.old" unload boot-conf .Ed @@ -193,7 +193,7 @@ Read an additional configuration file and then proceed to boot: .Pp .Bd -literal -offset indent -compact unload -read-conf /boot/special.conf +read-conf special.conf boot-conf .Ed .Pp diff --git a/sys/boot/forth/loader.conf.5 b/sys/boot/forth/loader.conf.5 index f4a145288c..4a0f5e2956 100644 --- a/sys/boot/forth/loader.conf.5 +++ b/sys/boot/forth/loader.conf.5 @@ -23,8 +23,8 @@ .\" SUCH DAMAGE. .\" .\" $FreeBSD: src/sys/boot/forth/loader.conf.5,v 1.18 2002/08/27 01:02:56 trhodes Exp $ -.\" $DragonFly: src/sys/boot/forth/loader.conf.5,v 1.9 2008/09/02 11:50:46 matthias Exp $ -.Dd September 2, 2008 +.\" $DragonFly: src/sys/boot/forth/loader.conf.5,v 1.10 2008/09/06 12:14:08 thomas Exp $ +.Dd September 6, 2008 .Dt LOADER.CONF 5 .Os .Sh NAME @@ -39,13 +39,13 @@ it, and additional modules to be loaded; and generally set all variables described in .Xr loader 8 . .Pp -The file -.Pa /boot/loader.rc +A file +.Pa loader.rc must contain the following two lines for .Nm to be automatically processed: .Pp -.Dl include /boot/loader.4th +.Dl include loader.4th .Dl start .Pp If no @@ -146,7 +146,7 @@ If set to .Dq YES , a bitmap will be loaded to be displayed on screen while booting. .It Va bitmap_name -.Pq Dq /boot/splash.bmp +.Pq Dq splash.bmp Name of the bitmap to be loaded. Any other name can be used. .It Va console .Pq Dq vidconsole @@ -167,7 +167,7 @@ boot menu appears. To make his life a bit more colorful, consider setting to .Dq YES . .It Va kernel -.Pq Dq /boot/kernel +.Pq Dq kernel .It Va loader_color .Pq Dq NO If set to @@ -181,7 +181,7 @@ to .Dq NO for this to work.) .It Va loader_conf_files -.Pq Do /boot/loader.conf /boot/loader.conf.local Dc +.Pq Do loader.conf loader.conf.local Dc .It Va splash_bmp_load .Pq Dq NO If set to -- 2.11.4.GIT