xref: /openbsd/sys/arch/luna88k/stand/boot/boot.8 (revision 4bdff4be)
1.\"	$OpenBSD: boot.8,v 1.2 2023/02/23 19:48:22 miod Exp $
2.\"
3.\" Copyright (c) 1997-2001 Michael Shalayeff
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\"
15.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18.\" IN NO EVENT SHALL THE AUTHOR OR HIS RELATIVES BE LIABLE FOR ANY DIRECT,
19.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
21.\" SERVICES; LOSS OF MIND, USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
23.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
24.\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
25.\" THE POSSIBILITY OF SUCH DAMAGE.
26.\"
27.\"
28.Dd $Mdocdate: February 23 2023 $
29.Dt BOOT 8 luna88k
30.Os
31.Sh NAME
32.Nm boot ,
33.Nm boot.conf
34.Nd luna88k-specific bootstrap
35.Sh DESCRIPTION
36The main purpose of this program is to load the system kernel.
37.Pp
38As described in
39.Xr boot_luna88k 8 ,
40this program is loaded by the luna88k ROM monitor
41and provides a convenient way to load the kernel.
42This program acts as an enhanced boot monitor for luna88k systems, providing
43a common interface for the kernel to start from.
44.Pp
45Basic operations include:
46.Pp
47.Bl -bullet -compact
48.It
49Loading kernels from the network, or any SCSI device.
50.\" not yet...
51.\" .It
52.\" Loading kernels compressed by
53.\" .Xr gzip 1 .
54.It
55Providing an interactive command line.
56.El
57.Pp
58The sequence of its operation is as follows: initialization,
59parsing the configuration file, then an interactive command line.
60While at the command line you have 5 seconds to type any commands, if needed.
61If time expires, the kernel will be loaded according to
62the current variable settings (see the
63.Ic set
64command).
65Each time a kernel load fails, the timeout is increased by one second.
66The sequence of
67.Nm
68operations is as follows:
69.Bl -enum
70.It
71If the file
72.Pa /etc/boot.conf
73exists on the filesystem
74.Nm
75was loaded from, open and parse it.
76Lines beginning with the
77.Sq #
78character,
79as well as whitespace at the beginning of lines,
80are ignored.
81The file may contain any commands
82.Nm
83accepts at the interactive prompt.
84Though default settings usually suffice, they can be changed here.
85.It
86The header line
87.Pp
88.Dl >> OpenBSD/luna88k BOOT [x.xx]
89.Pp
90is displayed to the active console, where
91.Ar x.xx
92is the version number of the
93.Nm
94program, followed by the
95.Pp
96.Dl boot>
97.Pp
98prompt, which means you are in interactive mode and may enter commands.
99If you do not,
100.Nm
101will proceed to load the kernel with the current parameters after the
102timeout period has expired.
103.El
104.Pp
105By default,
106.Nm
107attempts to load the kernel executable
108.Pa /bsd .
109If it fails to find the kernel and no alternative kernel image has
110been specified, the system will be unable to boot.
111.Sh COMMANDS
112The following commands are accepted at the
113.Nm
114prompt:
115.Bl -tag -width shorten
116.It Ic boot Oo Oo Ar device : Oc Ns Ar image Oc Op Fl acds
117Boots the specified kernel image
118with any options given.
119If
120.Ar device
121or
122.Ar image
123are omitted, values from
124.Nm
125variables will be used.
126.Pp
127Available devices are:
128.Bl -tag -width tenletters
129.It sd(d,l,p)
130SCSI device number
131.Ar d ,
132logical unit number
133.Ar l ,
134and partition
135.Ar p .
136The last two arguments can be omitted,
137in which case they will have a default value of zero.
138The encoding of the device number will match the encoding used by the ROM:
139devices numbered 0 to 6 on the first SCSI controller will use numbers 6 to 0,
140and devices numbered 0 to 6 on the second SCSI controller (on Luna88k-2 systems
141only) will use numbers 16 to 10.
142.It le()
143Onboard Ethernet.
144.El
145.Bl -tag -width _a_
146.It Fl a
147Causes the kernel to ask for the
148.Nm root
149device to use.
150.It Fl c
151Causes the kernel to go into
152.Xr boot_config 8
153before performing
154.Xr autoconf 4
155procedures.
156.It Fl d
157Causes the kernel to drop into
158.Xr ddb 4
159at the earliest convenient point.
160.It Fl s
161Causes the kernel to boot single-user.
162.El
163.It Ic echo Op Ar args
164Displays
165.Ar args
166on the console device.
167.It Ic help
168Prints a list of available commands.
169.It Ic hexdump Ar addr size
170Show
171.Ar size
172bytes of memory at address
173.Ar addr .
174.It Ic ls Op Ar directory
175Prints contents of the specified
176.Ar directory
177in long format including: attributes and file type, owner, group,
178size, filename.
179.It Ic reboot
180Reboots the machine by initiating a warm boot procedure.
181.It Ic set Op Ar varname Op Ar value
182If invoked without arguments, prints a list of variables and their values.
183If only
184.Ar varname
185is specified, displays contents of that variable.
186If
187.Ar varname
188and
189.Ar value
190are both specified, sets that variable to the given value.
191Variables include:
192.Pp
193.Bl -tag -compact -width db_console
194.It Ic debug
195Debug flag if
196.Nm
197was compiled with DEBUG defined.
198.It Ic device
199Boot device name (e.g.,
200.Li sd(6,0) ) .
201.It Ic howto
202Options to pass to the loaded kernel.
203.It Ic image
204File name containing the kernel image.
205.It Ic timeout
206Number of seconds boot will wait for human intervention before
207booting the default kernel image.
208.El
209.\" Intentionally undocumented at the moment
210.\" .It Ic time
211.\" Displays system time and date.
212.El
213.Sh FILES
214.Bl -tag -width /usr/mdec/boot -compact
215.It Pa /usr/mdec/boot
216system bootstrap
217.It Pa /etc/boot.conf
218system bootstrap's startup file
219.It Pa /bsd
220kernel image
221.It Pa /bsd.sp
222kernel image for single processor machines
223.It Pa /bsd.mp
224kernel image for multiprocessor machines
225.It Pa /bsd.rd
226kernel image for installation/recovery
227.El
228.Sh EXAMPLES
229Boot the default kernel:
230.Pp
231.Dl boot> boot
232.Pp
233Remove the 5 second pause at boot-time permanently, causing
234.Nm
235to load the kernel immediately without prompting:
236.Pp
237.Dl # echo \&"boot\&" > /etc/boot.conf
238.Pp
239Boot the kernel named
240.Pa /bsd
241from the SCSI disk with ID 2 in
242.Dq User Kernel Configuration
243mode (see
244.Xr boot_config 8 ) .
245This mechanism allows for the explicit enabling and disabling of devices
246during the current boot sequence, as well as the modification
247of device parameters.
248Once booted, such changes can be made permanent by using
249.Xr config 8 Ns 's
250.Fl e
251option.
252.Pp
253.Dl boot> boot sd(4):/bsd -c
254.Sh SEE ALSO
255.\" .Xr gzip 1 ,
256.Xr autoconf 4 ,
257.Xr ddb 4 ,
258.Xr boot_config 8 ,
259.Xr boot_luna88k 8 ,
260.Xr reboot 8
261.Sh HISTORY
262This program was written by Michael Shalayeff for
263.Ox 2.1
264on the i386 platform, and was later ported to the luna88k platform.
265