xref: /dflybsd-src/share/man/man5/loader.conf.5 (revision 30e3ae034c9501c319c415ada6d5e23372649c88)
1.\" Copyright (c) 1999 Daniel C. Sobral
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\"    notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\"    notice, this list of conditions and the following disclaimer in the
11.\"    documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.\" $FreeBSD: src/sys/boot/forth/loader.conf.5,v 1.18 2002/08/27 01:02:56 trhodes Exp $
26.\" $DragonFly: src/sys/boot/forth/loader.conf.5,v 1.13 2008/09/15 21:23:44 thomas Exp $
27.Dd September 6, 2008
28.Dt LOADER.CONF 5
29.Os
30.Sh NAME
31.Nm loader.conf
32.Nd system bootstrap configuration information
33.Sh DESCRIPTION
34The file
35.Nm
36contains descriptive information on bootstrapping the system.
37Through
38it you can specify the kernel to be booted, parameters to be passed to
39it, and additional modules to be loaded; and generally set all variables
40described in
41.Xr loader 8 .
42.Pp
43A file
44.Pa loader.rc
45must contain the following two lines for
46.Nm
47to be automatically processed:
48.Pp
49.Dl include loader.4th
50.Dl start
51.Pp
52If no
53.Pa /boot/loader.rc
54exists at installworld time, one with the above lines will be installed.
55.Sh SYNTAX
56Though
57.Nm Ns 's
58format was defined explicitly to resemble
59.Xr rc.conf 5 ,
60and can be sourced by
61.Xr sh 1 ,
62some settings are treated in a special fashion.
63Also, the
64behavior of some settings is defined by the setting's suffix;
65the prefix identifies which module the setting controls.
66.Pp
67The general parsing rules are:
68.Bl -bullet
69.It
70Spaces and empty lines are ignored.
71.It
72A
73.Ql #
74sign will mark the remainder of the line as a comment.
75.It
76Only one setting can be present on each line.
77.El
78.Pp
79All settings have the following format:
80.Pp
81.Dl variable="value"
82.Pp
83Unless it belongs to one of the classes of settings that receive special
84treatment, a setting will set the value of a
85.Xr loader 8
86environment variable.
87The settings that receive special
88treatment are listed below.
89Settings beginning with
90.Aq Ar module
91below define the modules to be loaded.
92All such settings sharing a common
93prefix refer to the same module.
94.Bl -tag -width Ar
95.It Ar exec
96Immediately executes a
97.Xr loader 8
98command.
99This type of setting cannot be processed by programs other
100than
101.Xr loader 8 ,
102so its use should be avoided.
103Multiple instances of it will be processed
104independently.
105.It Ar loader_conf_files
106Defines additional configuration files to be processed right after the
107present file.
108.It Ar kernel
109Name of the kernel to be loaded.
110If no kernel name is set, no additional
111modules will be loaded.
112.It Ar kernel_options
113Flags to be passed to the kernel (see
114.Xr boot 8 ) .
115.It Ar password
116Provides a password to be required by check-password before execution is
117allowed to continue.
118.It Ar verbose_loading
119If set to
120.Dq YES ,
121module names will be displayed as they are loaded.
122.It Ao Ar module Ac Ns Ar _load
123If set to
124.Dq YES ,
125that module will be loaded.
126If no
127.Ao Ar module Ac Ns Ar _name
128is defined (see below), the
129module's name is taken to be
130.Aq Ar module .
131.It Ao Ar module Ac Ns Ar _name
132Defines the name of the module.
133.It Ao Ar module Ac Ns Ar _type
134Defines the module's type.
135If none is given, it defaults to a kld module.
136.It Ao Ar module Ac Ns Ar _flags
137Flags and parameters to be passed to the module.
138.It Ao Ar module Ac Ns Ar _before
139Commands to be executed before the module is loaded.
140Use of this setting
141should be avoided.
142.It Ao Ar module Ac Ns Ar _after
143Commands to be executed after the module is loaded.
144Use of this setting
145should be avoided.
146.It Ao Ar module Ac Ns Ar _error
147Commands to be executed if the loading of a module fails.
148Except for the
149special value
150.Dq abort ,
151which aborts the bootstrap process, use of this setting should be avoided.
152.El
153.Sh DEFAULT SETTINGS
154Most of
155.Nm Ns 's
156default settings can be ignored.
157The few of them which are important
158or useful are:
159.Bl -tag -width bootfile -offset indent
160.It Va bitmap_load
161.Pq Dq NO
162If set to
163.Dq YES ,
164a bitmap will be loaded to be displayed on screen while booting.
165.It Va bitmap_name
166.Pq Dq splash.bmp
167Name of the bitmap to be loaded.
168Any other name can be used.
169.It Va console
170.Pq Dq vidconsole
171.Dq comconsole
172selects serial console,
173.Dq vidconsole
174selects the video console, and
175.Dq nullconsole
176selects a mute console
177(useful for systems with neither a video console nor a serial port).
178.It Va fred_disable
179.Pq Dq NO
180Shows a monochrome version of Fred, the official
181.Dx
182mascot, when the
183boot menu appears.
184To make his life a bit more colorful, consider setting
185.Pa loader_color
186to
187.Dq YES .
188.It Va kernel
189.Pq Dq kernel
190.It Va loader_color
191.Pq Dq NO
192If set to
193.Dq YES ,
194you'll meet Fred, the official
195.Dx
196mascot, in technicolor when the
197boot menu appears (remember to set
198.Pa fred_disable
199to
200.Dq NO
201for this to work.)
202.It Va loader_conf_files
203.Pq Do loader.conf loader.conf.local Dc
204.It Va splash_bmp_load
205.Pq Dq NO
206If set to
207.Dq YES ,
208will load the splash screen module, making it possible to display a bmp image
209on the screen while booting.
210.It Va splash_pcx_load
211.Pq Dq NO
212If set to
213.Dq YES ,
214will load the splash screen module, making it possible to display a pcx image
215on the screen while booting.
216.It Va userconfig_script_load
217.Pq Dq NO
218If set to
219.Dq YES ,
220will load the userconfig data.
221.It Va vesa_load
222.Pq Dq NO
223If set to
224.Dq YES ,
225the vesa module will be loaded, enabling bitmaps above VGA resolution to
226be displayed.
227.El
228.Sh FILES
229.Bl -tag -width /boot/defaults/loader.conf -compact
230.It Pa /boot/defaults/loader.conf
231default settings -- do not change this file.
232.It Pa /boot/loader.4th
233defines the commands used by loader to read and process
234.Nm .
235.It Pa /boot/loader.conf
236user defined settings.
237.It Pa /boot/loader.conf.local
238machine-specific settings for sites with a common loader.conf.
239.It Pa /boot/loader.rc
240contains the instructions to automatically process
241.Nm .
242.El
243.Sh SEE ALSO
244.Xr boot 8 ,
245.Xr loader 8
246.Sh HISTORY
247The file
248.Nm
249first appeared in
250.Fx 3.2 .
251.Sh AUTHORS
252This manual page was written by
253.An Daniel C. Sobral Aq dcs@FreeBSD.org .
254