xref: /openbsd/sys/arch/hppa/stand/boot/boot.8 (revision 4cfece93)
1.\"	$OpenBSD: boot.8,v 1.26 2019/12/23 12:44:34 bluhm 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: December 23 2019 $
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).
66Each time a kernel load fails, the timeout is increased by one second.
67The sequence of
68.Nm
69operations is as follows:
70.Bl -enum
71.It
72If the file
73.Pa /etc/boot.conf
74exists on the filesystem or LIF image
75.Nm
76was loaded from, open and parse it.
77Lines beginning with the
78.Sq #
79character,
80as well as whitespace at the beginning of lines,
81are ignored.
82The file may contain any commands
83.Nm
84accepts at the interactive prompt.
85Though default settings usually suffice, they can be changed here.
86.It
87The header line
88.Pp
89.Dl >> OpenBSD/hppa BOOT [x.xx]
90.Pp
91is displayed to the active console, where
92.Ar x.xx
93is the version number of the
94.Nm
95program, followed by the
96.Pp
97.Dl boot>
98.Pp
99prompt, which means you are in interactive mode and may enter commands.
100If you do not,
101.Nm
102will proceed to load the kernel with the current parameters after the
103timeout period has expired.
104.El
105.Pp
106By default,
107.Nm
108attempts to load the kernel executable
109.Pa /bsd .
110If it fails to find the kernel and no alternative kernel image has
111been specified, the system will be unable to boot.
112.Sh COMMANDS
113The following commands are accepted at the
114.Nm
115prompt:
116.Bl -tag -width shorten
117.It Ic boot Oo Oo Ar device : Oc Ns Ar image Oc Op Fl acds
118Boots the specified kernel image
119with any options given.
120If
121.Ar device
122or
123.Ar image
124are omitted, values from
125.Nm
126variables will be used.
127.Bl -tag -width _a_
128.It Fl a
129Causes the kernel to ask for the
130.Nm root
131device to use.
132.It Fl c
133Causes the kernel to go into
134.Xr boot_config 8
135before performing
136.Xr autoconf 4
137procedures.
138.It Fl d
139Causes the kernel to drop into
140.Xr ddb 4
141at the earliest convenient point.
142.It Fl s
143Causes the kernel to boot single-user.
144.El
145.It Ic echo Op Ar args
146Displays
147.Ar args
148on the console device.
149.It Ic help
150Prints a list of available commands and machine dependent
151commands, if any.
152.It Ic hexdump Ar addr size
153Show
154.Ar size
155bytes of memory at address
156.Ar addr .
157.It Ic machine Op Ar command
158Issues machine-dependent commands.
159These are defined for hppa architecture:
160.Bl -tag -width keyboard
161.It Ic console
162Displays or sets the console path.
163.Pp
164When invoked with no argument, this command will display the configured
165console path found in the stable storage area.
166.Pp
167Otherwise, the argument will be interpreted as a console path
168definition string, and
169.Nm
170will attempt to switch the console configuration to the desired device.
171The console definition attempts to follow the PDC syntax,
172and would have a form of:
173.Bd -filled
174graphics
175.Op _head
176.Op .mode
177.Ed
178for graphics console, and
179.Bd -filled
180rs232
181.Op _2
182.Op .speed Op .bits Op .parity
183.Ed
184for serial console.
185.Pp
186The default head and mode for graphics console are 0, that is the default
187videomode of the first graphics device.
188The default serial settings are 9600 bps, 8 data bits, and no parity.
189.It Ic keyboard
190Displays or sets the keyboard path.
191.Pp
192When invoked with no argument, this command will display the configured
193keyboard path found in the stable storage area.
194.Pp
195Otherwise, the argument will be interpreted as a keyboard path definition
196string, and
197.Nm
198will attempt to switch the keyboard configuration to the desired port.
199The keyboard definition attempts to follow the PDC syntax,
200and would have a form of:
201.Bd -filled
202hil
203.Ed
204for hil keyboard, and
205.Bd -filled
206ps2
207.Ed
208for PS/2 keyboard.
209.El
210.Pp
211After changing any path settings, the machine usually has to be restarted for
212the changes to have effect.
213.It Ic ls Op Ar directory
214Prints contents of the specified
215.Ar directory
216in long format including: attributes and file type, owner, group,
217size, filename.
218.It Ic reboot
219Reboots the machine by initiating a warm boot procedure.
220.It Ic set Op Ar varname Op Ar value
221If invoked without arguments, prints a list of variables and their values.
222If only
223.Ar varname
224is specified, displays contents of that variable.
225If
226.Ar varname
227and
228.Ar value
229are both specified, sets that variable to the given value.
230Variables include:
231.Pp
232.Bl -tag -compact -width db_console
233.It Ic addr
234Address at which to load the kernel.
235.It Ic db_console
236Boolean (0 or 1) to permit entry into the kernel debugger before the
237.Em ddb.console
238sysctl gets effective.
239.It Ic debug
240Debug flag if
241.Nm
242was compiled with DEBUG defined.
243.It Ic device
244Boot device name (i.e.,
245.Li lf0a ,
246.Li sd0a ) .
247.It Ic howto
248Options to pass to the loaded kernel.
249.It Ic image
250File name containing the kernel image.
251.It Ic timeout
252Number of seconds boot will wait for human intervention before
253booting the default kernel image.
254.\" .It Nm tty
255.\" Active console device name (i.e.,
256.\" .Li ttya ,
257.\" .Li ttyb ,
258.\" .Li ite0) .
259.El
260.\" .It stty Op Ar device Op Ar speed
261.\" Displays or sets the
262.\" .Ar speed
263.\" for a console
264.\" .Ar device .
265.\" If changing the baudrate for the currently active console,
266.\" .Nm
267.\" offers you five seconds of grace time before committing the change
268.\" to allow you to change your terminal's speed to match.
269.\" If changing speed
270.\" .Em not
271.\" for the active console, the baudrate is set for the
272.\" .Em next
273.\" time you switch to a serial console.
274.\" The baudrate value is not used for the
275.\" .Li ite0
276.\" console.
277.\" .Pp
278.\" The default baudrate is 9600bps.
279.It Ic time
280Displays system time and date.
281.El
282.Sh FILES
283.Bl -tag -width /etc/boot.conf -compact
284.It Pa /boot
285system bootstrap
286.It Pa /etc/boot.conf
287system bootstrap's startup file
288.It Pa /bsd
289kernel image
290.It Pa /bsd.rd
291kernel image for installation/recovery
292.El
293.Sh EXAMPLES
294Boot the default kernel:
295.Pp
296.Dl boot> boot
297.Pp
298Remove the 5 second pause at boot-time permanently, causing
299.Nm
300to load the kernel immediately without prompting:
301.Pp
302.Dl # echo \&"boot\&" > /etc/boot.conf
303.Pp
304Use serial console on the first serial port, with the usual 9600 8N1 settings.
305A null modem cable should connect the specified serial port to a terminal.
306Useful for debugging.
307.Pp
308.Dl boot> machine console rs232.9600.8.none
309.Pp
310Boot the kernel named
311.Pa /bsd
312from the second SCSI disk in
313.Dq User Kernel Configuration
314mode (see
315.Xr boot_config 8 ) .
316This mechanism allows for the explicit enabling and disabling of devices
317during the current boot sequence, as well as the modification
318of device parameters.
319Once booted, such changes can be made permanent by using
320.Xr config 8 Ns 's
321.Fl e
322option.
323.Pp
324.Dl boot> boot sd1a:/bsd -c
325.Sh SEE ALSO
326.Xr gzip 1 ,
327.Xr autoconf 4 ,
328.Xr ddb 4 ,
329.Xr boot_config 8 ,
330.Xr boot_hppa 8 ,
331.\" .Xr installboot 8 ,
332.Xr reboot 8
333.Sh HISTORY
334This program was written by Michael Shalayeff for
335.Ox 2.1 .
336The hppa specific parts were written by Michael Shalayeff and Miodrag Vallat
337for
338.Ox 3.1 .
339.Sh CAVEATS
340Making mistakes in console paths may cost you a toupee.
341.Sh BUGS
342Changing the display resolution (mode) on a graphics console does not work
343correctly.
344