xref: /openbsd-src/sys/arch/hppa/stand/boot/boot.8 (revision bf205b9638c7c57bbb1ea133d350e2e30f2ccf83)
1.\"	$OpenBSD: boot.8,v 1.28 2024/11/05 09:42:48 miod Exp $
2.\"
3.\" Copyright (c) 2002 Miodrag Vallat
4.\" Copyright (c) 1997-2002 Michael Shalayeff
5.\" All rights reserved.
6.\"
7.\" Redistribution and use in source and binary forms, with or without
8.\" modification, are permitted provided that the following conditions
9.\" are met:
10.\" 1. Redistributions of source code must retain the above copyright
11.\"    notice, this list of conditions and the following disclaimer.
12.\" 2. Redistributions in binary form must reproduce the above copyright
13.\"    notice, this list of conditions and the following disclaimer in the
14.\"    documentation and/or other materials provided with the distribution.
15.\"
16.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
17.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
19.\" IN NO EVENT SHALL THE AUTHOR OR HIS RELATIVES BE LIABLE FOR ANY DIRECT,
20.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
22.\" SERVICES; LOSS OF MIND, USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
24.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
25.\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26.\" THE POSSIBILITY OF SUCH DAMAGE.
27.\"
28.\"
29.Dd $Mdocdate: November 5 2024 $
30.Dt BOOT 8 hppa
31.Os
32.Sh NAME
33.Nm boot ,
34.Nm boot.conf
35.Nd hppa-specific bootstrap
36.Sh DESCRIPTION
37The main purpose of this program is to load the system kernel while dealing
38with the various features of the PA-RISC hardware.
39.Pp
40As described in
41.Xr boot_hppa 8 ,
42this program is loaded by the PDC firmware
43and provides a convenient way to load the kernel.
44.Pp
45Basic operations include:
46.Pp
47.Bl -bullet -compact
48.It
49Loading kernels from any device supported by your system.
50.It
51Loading kernels compressed by
52.Xr gzip 1 .
53.It
54Providing an interactive command line.
55.It
56Detecting and switching between multiple consoles.
57.El
58.Pp
59The sequence of its operation is as follows: initialization,
60parsing the configuration file, then an interactive command line.
61While at the command line you have 5 seconds to type any commands, if needed.
62If time expires, the kernel will be loaded according to
63the current variable settings (see the
64.Nm set
65command).
66If the kernel load fails, a second attempt is made with the timeout increased
67by one second.
68The sequence of
69.Nm
70operations is as follows:
71.Bl -enum
72.It
73If the file
74.Pa /etc/boot.conf
75exists on the filesystem or LIF image
76.Nm
77was loaded from, open and parse it.
78Lines beginning with the
79.Sq #
80character,
81as well as whitespace at the beginning of lines,
82are ignored.
83The file may contain any commands
84.Nm
85accepts at the interactive prompt.
86Though default settings usually suffice, they can be changed here.
87.It
88The header line
89.Pp
90.Dl >> OpenBSD/hppa BOOT [x.xx]
91.Pp
92is displayed to the active console, where
93.Ar x.xx
94is the version number of the
95.Nm
96program, followed by the
97.Pp
98.Dl boot>
99.Pp
100prompt, which means you are in interactive mode and may enter commands.
101If you do not,
102.Nm
103will proceed to load the kernel with the current parameters after the
104timeout period has expired.
105.El
106.Pp
107By default,
108.Nm
109attempts to load the kernel executable
110.Pa /bsd .
111If it fails to find the kernel and no alternative kernel image has
112been specified, the system will be unable to boot.
113.Sh COMMANDS
114The following commands are accepted at the
115.Nm
116prompt:
117.Bl -tag -width shorten
118.It Ic boot Oo Oo Ar device : Oc Ns Ar image Oc Op Fl acds
119Boots the specified kernel image
120with any options given.
121If
122.Ar device
123or
124.Ar image
125are omitted, values from
126.Nm
127variables will be used.
128.Bl -tag -width _a_
129.It Fl a
130Causes the kernel to ask for the
131.Nm root
132device to use.
133.It Fl c
134Causes the kernel to go into
135.Xr boot_config 8
136before performing
137.Xr autoconf 4
138procedures.
139.It Fl d
140Causes the kernel to drop into
141.Xr ddb 4
142at the earliest convenient point.
143.It Fl s
144Causes the kernel to boot single-user.
145.El
146.It Ic echo Op Ar args
147Displays
148.Ar args
149on the console device.
150.It Ic help
151Prints a list of available commands and machine dependent
152commands, if any.
153.It Ic hexdump Ar addr size
154Show
155.Ar size
156bytes of memory at address
157.Ar addr .
158.It Ic machine Op Ar command
159Issues machine-dependent commands.
160These are defined for hppa architecture:
161.Bl -tag -width keyboard
162.It Ic console
163Displays or sets the console path.
164.Pp
165When invoked with no argument, this command will display the configured
166console path found in the stable storage area.
167.Pp
168Otherwise, the argument will be interpreted as a console path
169definition string, and
170.Nm
171will attempt to switch the console configuration to the desired device.
172The console definition attempts to follow the PDC syntax,
173and would have a form of:
174.Bd -filled
175graphics
176.Op _head
177.Op .mode
178.Ed
179for graphics console, and
180.Bd -filled
181rs232
182.Op _2
183.Op .speed Op .bits Op .parity
184.Ed
185for serial console.
186.Pp
187The default head and mode for graphics console are 0, that is the default
188videomode of the first graphics device.
189The default serial settings are 9600 bps, 8 data bits, and no parity.
190.It Ic keyboard
191Displays or sets the keyboard path.
192.Pp
193When invoked with no argument, this command will display the configured
194keyboard path found in the stable storage area.
195.Pp
196Otherwise, the argument will be interpreted as a keyboard path definition
197string, and
198.Nm
199will attempt to switch the keyboard configuration to the desired port.
200The keyboard definition attempts to follow the PDC syntax,
201and would have a form of:
202.Bd -filled
203hil
204.Ed
205for hil keyboard, and
206.Bd -filled
207ps2
208.Ed
209for PS/2 keyboard.
210.El
211.Pp
212After changing any path settings, the machine usually has to be restarted for
213the changes to have effect.
214.It Ic ls Op Ar directory
215Prints contents of the specified
216.Ar directory
217in long format including: attributes and file type, owner, group,
218size, filename.
219.It Ic reboot
220Reboots the machine by initiating a warm boot procedure.
221.It Ic set Op Ar varname Op Ar value
222If invoked without arguments, prints a list of variables and their values.
223If only
224.Ar varname
225is specified, displays contents of that variable.
226If
227.Ar varname
228and
229.Ar value
230are both specified, sets that variable to the given value.
231Variables include:
232.Pp
233.Bl -tag -compact -width db_console
234.It Ic db_console
235Boolean (0 or 1) to permit entry into the kernel debugger before the
236.Em ddb.console
237sysctl gets effective.
238.It Ic debug
239Debug flag if
240.Nm
241was compiled with DEBUG defined.
242.It Ic device
243Boot device name (i.e.,
244.Li lf0a ,
245.Li sd0a ) .
246.It Ic howto
247Options to pass to the loaded kernel.
248.It Ic image
249File name containing the kernel image.
250.It Ic timeout
251Number of seconds boot will wait for human intervention before
252booting the default kernel image.
253.It Ic time
254Displays system time and date.
255.El
256.Sh FILES
257.Bl -tag -width /etc/boot.conf -compact
258.It Pa /boot
259system bootstrap
260.It Pa /etc/boot.conf
261system bootstrap's startup file
262.It Pa /bsd
263kernel image
264.It Pa /bsd.rd
265kernel image for installation/recovery
266.El
267.Sh EXAMPLES
268Boot the default kernel:
269.Pp
270.Dl boot> boot
271.Pp
272Remove the 5 second pause at boot-time permanently, causing
273.Nm
274to load the kernel immediately without prompting:
275.Pp
276.Dl # echo \&"boot\&" > /etc/boot.conf
277.Pp
278Use serial console on the first serial port, with the usual 9600 8N1 settings.
279A null modem cable should connect the specified serial port to a terminal.
280Useful for debugging.
281.Pp
282.Dl boot> machine console rs232.9600.8.none
283.Pp
284Boot the kernel named
285.Pa /bsd
286from the second SCSI disk in
287.Dq User Kernel Configuration
288mode (see
289.Xr boot_config 8 ) .
290This mechanism allows for the explicit enabling and disabling of devices
291during the current boot sequence, as well as the modification
292of device parameters.
293Once booted, such changes can be made permanent by using
294.Xr config 8 Ns 's
295.Fl e
296option.
297.Pp
298.Dl boot> boot sd1a:/bsd -c
299.Sh SEE ALSO
300.Xr gzip 1 ,
301.Xr autoconf 4 ,
302.Xr ddb 4 ,
303.Xr boot_config 8 ,
304.Xr boot_hppa 8 ,
305.\" .Xr installboot 8 ,
306.Xr reboot 8
307.Sh HISTORY
308This program was written by Michael Shalayeff for
309.Ox 2.1 .
310The hppa specific parts were written by Michael Shalayeff and Miodrag Vallat
311for
312.Ox 3.1 .
313.Sh CAVEATS
314Making mistakes in console paths may cost you a toupee.
315.Sh BUGS
316Changing the display resolution (mode) on a graphics console does not work
317correctly.
318