xref: /netbsd-src/usr.sbin/installboot/installboot.8 (revision 9aa0541bdf64142d9a27c2cf274394d60182818f)
1.\"	$NetBSD: installboot.8,v 1.78 2011/08/29 14:09:01 alnsn Exp $
2.\"
3.\" Copyright (c) 2002-2009 The NetBSD Foundation, Inc.
4.\" All rights reserved.
5.\"
6.\" This code is derived from software contributed to The NetBSD Foundation
7.\" by Luke Mewburn of Wasabi Systems.
8.\"
9.\" Redistribution and use in source and binary forms, with or without
10.\" modification, are permitted provided that the following conditions
11.\" are met:
12.\" 1. Redistributions of source code must retain the above copyright
13.\"    notice, this list of conditions and the following disclaimer.
14.\" 2. Redistributions in binary form must reproduce the above copyright
15.\"    notice, this list of conditions and the following disclaimer in the
16.\"    documentation and/or other materials provided with the distribution.
17.\"
18.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
19.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
20.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
21.\" PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
22.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28.\" POSSIBILITY OF SUCH DAMAGE.
29.\"
30.Dd August 3, 2011
31.Dt INSTALLBOOT 8
32.Os
33.Sh NAME
34.Nm installboot
35.Nd install disk bootstrap software
36.
37.Sh SYNOPSIS
38.Nm
39.Op Fl fnv
40.Op Fl B Ar s2bno
41.Op Fl b Ar s1bno
42.Op Fl m Ar machine
43.Op Fl o Ar options
44.Op Fl t Ar fstype
45.Ar filesystem
46.Ar primary
47.Op Ar secondary
48.Nm
49.Fl c
50.Op Fl fnv
51.Op Fl m Ar machine
52.Op Fl o Ar options
53.Op Fl t Ar fstype
54.Ar filesystem
55.Nm
56.Fl e
57.Op Fl fnv
58.Op Fl m Ar machine
59.Op Fl o Ar options
60.Ar bootstrap
61.
62.Sh DESCRIPTION
63The
64.Nm
65utility installs and removes
66.Nx
67disk bootstrap software into a file system.
68.Nm
69can install
70.Ar primary
71into
72.Ar filesystem ,
73or disable an existing bootstrap in
74.Ar filesystem .
75.Pp
76On some architectures the options of an existing installed bootstrap,
77or those of a bootstrap file can be changed.
78Installing a new primary bootstrap will reset those options to default
79values.
80.Pp
81Generally,
82.Nx
83disk bootstrap software consists of two parts: a
84.Dq primary
85bootstrap program usually written into the disklabel area of the
86file system by
87.Nm ,
88and a
89.Dq secondary
90bootstrap program that usually resides as an ordinary file in the file system.
91.Pp
92When booting, the primary bootstrap program is loaded and invoked by
93the machine's PROM or BIOS.
94After receiving control of the system it loads and runs the secondary
95bootstrap program, which in turn loads and runs the kernel.
96The secondary bootstrap may allow control over various boot parameters
97passed to the kernel.
98.Pp
99Perform the following steps to make a file system bootable:
100.Bl -enum
101.It
102Copy the secondary bootstrap (usually
103.Pa /usr/mdec/boot. Ns Sy MACHINE
104or
105.Pa /usr/mdec/boot )
106to the root directory of the target file system.
107.Pp
108.
109.It
110Use
111.Nm
112to install the primary bootstrap program
113(usually
114.Pa /usr/mdec/bootxx_ Ns Sy FSTYPE )
115into
116.Ar filesystem .
117.Pp
118The following platforms do not require this step if the primary bootstrap
119already exists and the secondary bootstrap file is just being updated:
120.Sy alpha ,
121.Sy amd64 ,
122.Sy amiga ,
123.Sy i386 ,
124.Sy pmax ,
125.Sy sparc64 ,
126and
127.Sy vax .
128.Pp
129The following platform does not require the first step since a
130single bootstrap file is used.
131The single bootstrap is installed like the primary bootstrap on
132other platforms:
133.Sy next68k .
134.Pp
135.El
136.Pp
137The options and arguments recognized by
138.Nm
139are as follows:
140.
141.Bl -tag -width "optionsxxx"
142.
143.It Fl B Ar s2bno
144When hard-coding the blocks of
145.Ar secondary
146into
147.Ar primary ,
148start from block
149.Ar s2bno
150instead of trying to determine the block numbers occupied by
151.Ar secondary
152by examining
153.Ar filesystem .
154If this option is supplied,
155.Ar secondary
156should refer to an actual secondary bootstrap (rather than the
157file name of the one present in
158.Ar filesystem )
159so that its size can be determined.
160.
161.It Fl b Ar s1bno
162Install
163.Ar primary
164at block number
165.Ar s1bno
166instead of the default location for the machine and file system type.
167.Sy [ alpha ,
168.Sy pmax ,
169.Sy vax ]
170.
171.It Fl c
172Clear (remove) any existing bootstrap instead of installing one.
173.
174.It Fl e
175Edit the options of an existing bootstrap.
176This can be use to change the options in bootxx_xxxfs files,
177raw disk partitions, and the
178.Pa pxeboot_ia32.bin
179file.
180With
181.Fl v
182and without
183.Fl o ,
184show the current options.
185.Sy [ amd64 , i386 ]
186.
187.It Fl f
188Forces
189.Nm
190to ignore some errors.
191.
192.It Fl m Ar machine
193Use
194.Ar machine
195as the target machine type.
196The default machine is determined from
197.Xr uname 3
198and then
199.Ev MACHINE .
200The following machines are currently supported by
201.Nm :
202.Bd -ragged -offset indent
203.Sy alpha ,
204.Sy amd64 ,
205.Sy amiga ,
206.Sy ews4800mips ,
207.Sy hp300 ,
208.Sy hp700 ,
209.Sy i386 ,
210.Sy landisk ,
211.Sy macppc ,
212.Sy news68k ,
213.Sy newsmips ,
214.Sy next68k ,
215.Sy pmax ,
216.Sy sparc ,
217.Sy sparc64 ,
218.Sy sun2 ,
219.Sy sun3 ,
220.Sy vax ,
221.Sy x68k
222.Ed
223.
224.
225.It Fl n
226Do not write to
227.Ar filesystem .
228.
229.It Fl o Ar options
230Machine specific
231.Nm
232options, comma separated.
233.Pp
234Supported options are (with the machines for they are valid in brackets):
235.
236.Bl -tag -offset indent -width alphasum
237.
238.It Sy alphasum
239.Sy [ alpha ]
240Recalculate and restore the Alpha checksum.
241This is the default for
242.Nx Ns Tn /alpha .
243.
244.It Sy append
245.Sy [ alpha ,
246.Sy pmax ,
247.Sy vax ]
248Append
249.Ar primary
250to the end of
251.Ar filesystem ,
252which must be a regular file in this case.
253.
254.It Sy bootconf
255.Sy [ amd64 ,
256.Sy i386 ]
257(Don't) read a
258.Dq boot.cfg
259file.
260.
261.It Sy command=\*[Lt]boot command\*[Gt]
262.Sy [ amiga ]
263Modify the default boot command line.
264.
265.It Sy console=\*[Lt]console name\*[Gt]
266.Sy [ amd64 ,
267.Sy i386 ]
268Set the console device, \*[Lt]console name\*[Gt] must be one of:
269pc, com0, com1, com2, com3, com0kbd, com1kbd, com2kbd or com3kbd.
270.
271.It Sy ioaddr=\*[Lt]ioaddr\*[Gt]
272.Sy [ amd64 ,
273.Sy i386 ]
274Set the IO address to be used for the console serial port.
275Defaults to the IO address used by the system BIOS for the specified port.
276.
277.It Sy keymap=\*[Lt]keymap\*[Gt]
278.Sy [ amd64 ,
279.Sy i386 ]
280Set a boot time keyboard translation map.
281Each character in \*[Lt]keymap\*[Gt] will be replaced by the one following it.
282For example, an argument of
283.Dq zyz
284would swap the lowercase letters
285.Sq y
286and
287.Sq z .
288.
289.It Sy modules
290.Sy [ amd64 ,
291.Sy i386 ]
292(Don't) load kernel modules.
293.
294.It Sy password=\*[Lt]password\*[Gt]
295.Sy [ amd64 ,
296.Sy i386 ]
297Set the password which must be entered before the boot menu can be accessed.
298.
299.It Sy resetvideo
300.Sy [ amd64 ,
301.Sy i386 ]
302Reset the video before booting.
303.
304.It Sy speed=\*[Lt]baud rate\*[Gt]
305.Sy [ amd64 ,
306.Sy i386 ]
307Set the baud rate for the serial console.
308If a value of zero is specified, then the current baud rate (set by the
309BIOS) will be used.
310.
311.It Sy sunsum
312.Sy [ alpha ,
313.Sy pmax ,
314.Sy vax ]
315Recalculate and restore the Sun and
316.Nx Ns Tn /sparc
317compatible checksum.
318.Em Note :
319The existing
320.Nx Ns Tn /sparc
321disklabel should use no more than 4 partitions.
322.
323.It Sy timeout=\*[Lt]seconds\*[Gt]
324.Sy [ amd64 ,
325.Sy i386 ]
326Set the timeout before the automatic boot begins to the given number of seconds.
327.El
328.
329.It Fl t Ar fstype
330Use
331.Ar fstype
332as the type of
333.Ar filesystem .
334The default operation is to attempt to auto-detect this setting.
335The following file system types are currently supported by
336.Nm :
337.
338.Bl -tag -offset indent -width raid
339.
340.It Sy ffs
341.Bx
342Fast File System.
343.
344.It Sy raid
345Mirrored RAIDframe File System.
346.
347.It Sy raw
348.Sq Raw
349image.
350Note: if a platform needs to hard-code the block offset of the secondary
351bootstrap, it cannot be searched for on this file system type, and must
352be provided with
353.Fl B Ar s2bno .
354.El
355.
356.It Fl v
357Verbose operation.
358.
359.It Ar filesystem
360The path name of the device or file system image that
361.Nm
362is to operate on.
363It is not necessary for
364.Ar filesystem
365to be a currently mounted file system.
366.
367.It Ar primary
368The path name of the
369.Dq primary
370boot block to install.
371The path name must refer to a file in a file system that is currently
372mounted.
373.
374.It Ar secondary
375The path name of the
376.Dq secondary
377boot block, relative to the root of
378the file system in the device or image specified by the
379.Ar filesystem
380argument.
381Note that this may refer to a file in a file system that is not mounted.
382Most systems require
383.Ar secondary
384to be in the
385.Dq root
386directory of the file system, so the leading
387.Dq Pa /
388is not necessary on
389.Ar secondary .
390.Pp
391Only certain combinations of
392platform
393.Pq Fl m Ar machine
394and file system type
395.Pq Fl t Ar fstype
396require that the name of the secondary bootstrap is
397supplied as
398.Ar secondary ,
399so that information such as the disk block numbers occupied
400by the secondary bootstrap can be stored in the primary bootstrap.
401These are:
402.Bl -column "Platform" "File systems" -offset indent
403.It Sy "Platform" Ta Sy "File systems"
404.It macppc Ta ffs, raw
405.It news68k Ta ffs, raw
406.It newsmips Ta ffs, raw
407.It sparc Ta ffs, raid, raw
408.It sun2 Ta ffs, raw
409.It sun3 Ta ffs, raw
410.El
411.El
412.Pp
413.Nm
414exits 0 on success, and \*[Gt]0 if an error occurs.
415.
416.Sh ENVIRONMENT
417.Nm
418uses the following environment variables:
419.
420.Bl -tag -width "MACHINE"
421.
422.It Ev MACHINE
423Default value for
424.Ar machine ,
425overriding the result from
426.Xr uname 3 .
427.
428.El
429.
430.Sh FILES
431Most
432.Nx
433ports will contain variations of the following files:
434.Pp
435.Bl -tag -width /usr/mdec/bootxx_ustarfs
436.
437.It Pa /usr/mdec/bootxx_ Ns Sy FSTYPE
438Primary bootstrap for file system type
439.Sy FSTYPE .
440Installed into the bootstrap area of the file system by
441.Nm .
442.
443.It Pa /usr/mdec/bootxx_fat16
444Primary bootstrap for
445.Tn MS-DOS
446.Sy FAT16
447file systems.
448This differs from
449.Nm bootxx_msdos
450in that it doesn't require the filesystem to have been initialised with
451any
452.Ql reserved sectors .
453It also uses the information in the
454.Ql Boot Parameter Block
455to get the media and filesytem properties.
456.
457.It Pa /usr/mdec/bootxx_ffsv1
458Primary bootstrap for
459.Sy FFSv1
460file systems
461(the "traditional"
462.Nx
463file system).
464Use
465.Xr dumpfs 8
466to confirm the file system format is
467.Sy FFSv1 .
468.
469.It Pa /usr/mdec/bootxx_ffsv2
470Primary bootstrap for
471.Sy FFSv2
472file systems.
473Use
474.Xr dumpfs 8
475to confirm the file system format is
476.Sy FFSv2 .
477.
478.It Pa /usr/mdec/bootxx_lfsv1
479Primary bootstrap for
480.Sy LFSv1
481file systems.
482.
483.It Pa /usr/mdec/bootxx_lfsv2
484Primary bootstrap for
485.Sy LFSv2
486file systems
487(the default LFS version).
488.
489.It Pa /usr/mdec/bootxx_msdos
490Primary bootstrap for
491.Tn MS-DOS
492.Sy FAT
493file systems.
494.
495.It Pa /usr/mdec/bootxx_ustarfs
496Primary bootstrap for
497.Sy TARFS
498boot images.
499This is used by various install media.
500.
501.It Pa /usr/mdec/boot. Ns Sy MACHINE
502Secondary bootstrap for machine type
503.Sy MACHINE .
504This should be installed into the file system before
505.Nm
506is run.
507.
508.It Pa /usr/mdec/boot
509Synonym for
510.Pa /usr/mdec/boot. Ns Sy MACHINE
511.
512.It Pa /boot. Ns Sy MACHINE
513Installed copy of secondary bootstrap for machine type
514.Sy MACHINE .
515.
516.It Pa /boot
517Installed copy of secondary bootstrap.
518Searched for by the primary bootstrap if
519.Pa /boot. Ns Sy MACHINE
520is not found.
521.
522.El
523.
524.Ss Nx Ns Tn /macppc files
525.
526.Bl -tag -width /usr/mdec/bootxx_ustarfs
527.
528.It Pa /usr/mdec/bootxx
529.Nx Ns Tn /macppc
530primary bootstrap.
531.
532.It Pa /usr/mdec/ofwboot
533.Nx Ns Tn /macppc
534secondary bootstrap.
535.
536.It Pa /ofwboot
537Installed copy of
538.Nx Ns Tn /macppc
539secondary bootstrap.
540.
541.El
542.
543.Ss Nx Ns Tn /next68k files
544.
545.Bl -tag -width /usr/mdec/bootxx_ustarfs
546.
547.It Pa /usr/mdec/boot
548.Nx Ns Tn /next68k
549bootstrap.
550.
551.El
552.
553.Ss Nx Ns Tn /sparc64 files
554.
555.Bl -tag -width /usr/mdec/bootxx_ustarfs
556.
557.It Pa /usr/mdec/bootblk
558.Nx Ns Tn /sparc64
559primary bootstrap.
560.
561.It Pa /usr/mdec/ofwboot
562.Nx Ns Tn /sparc64
563secondary bootstrap.
564.
565.It Pa /ofwboot
566Installed copy of
567.Nx Ns Tn /sparc64
568secondary bootstrap.
569.
570.El
571.
572.Sh EXAMPLES
573.
574.Ss common
575Verbosely install the Berkeley Fast File System primary bootstrap on to disk
576.Sq sd0 :
577.Dl Ic installboot -v /dev/rsd0c /usr/mdec/bootxx_ffs
578Note: the
579.Dq whole disk
580partition (c on some ports, d on others) is used here, since the a partition
581probably is already opened (mounted as
582.Pa / ) ,
583so
584.Nm
585would not be able to access it.
586.Pp
587Remove the primary bootstrap from disk
588.Sq sd1 :
589.Dl Ic installboot -c /dev/rsd1c
590.
591.Ss Nx Ns Tn /amiga
592Modify the command line to change the default from "netbsd -ASn2" to
593"netbsd -S":
594.Dl Ic installboot -m amiga -o command="netbsd -S" /dev/rsd0a /usr/mdec/bootxx_ffs
595.
596.Ss Nx Ns Tn /ews4800mips
597Install the System V Boot File System primary bootstrap on to disk
598.Sq sd0 ,
599with the secondary bootstrap
600.Sq Pa /boot
601already present in the SysVBFS partition on the disk:
602.Dl Ic installboot /dev/rsd0c /usr/mdec/bootxx_bfs
603.
604.Ss Nx Ns Tn /i386 and Nx Ns Tn /amd64
605Install new boot blocks on an existing mounted root file system on
606.Sq wd0 ,
607setting the timeout to five seconds, after copying a new secondary
608bootstrap:
609.Dl Ic cp /usr/mdec/boot /boot
610.Dl Ic installboot -v -o timeout=5 /dev/rwd0a /usr/mdec/bootxx_ffsv1
611.
612.Pp
613Create a bootable CD-ROM with an ISO9660
614file system for an i386 system with a serial console:
615.Dl Ic mkdir cdrom
616.Dl Ic cp sys/arch/i386/compile/mykernel/netbsd cdrom/netbsd
617.Dl Ic cp /usr/mdec/boot cdrom/boot
618.Dl Ic cp /usr/mdec/bootxx_cd9660 bootxx
619.Dl Ic installboot -o console=com0,speed=19200 -m i386 -e bootxx
620.Dl Ic makefs -t cd9660 -o 'bootimage=i386;bootxx,no-emul-boot' boot.iso \
621	cdrom
622.
623.Pp
624Create a bootable floppy disk with an FFSv1
625file system for a small custom kernel (note: bigger kernels needing
626multiple disks are handled with the ustarfs file system):
627.Dl Ic newfs -s 1440k /dev/rfd0a
628.Bd -ragged -offset indent-two -compact
629.Em Note :
630Ignore the warnings that
631.Xr newfs 8
632displays; it can not write a disklabel,
633which is not a problem for a floppy disk.
634.Ed
635.Dl Ic mount /dev/fd0a /mnt
636.Dl Ic cp /usr/mdec/boot /mnt/boot
637.Dl Ic gzip -9 \*[Lt] sys/arch/i386/compile/mykernel/netbsd \*[Gt] /mnt/netbsd.gz
638.Dl Ic umount /mnt
639.Dl Ic installboot -v /dev/rfd0a /usr/mdec/bootxx_ffsv1
640.
641.Pp
642Create a bootable FAT file system on
643.Sq wd1a ,
644which should have the same offset and size as a FAT primary partition
645in the Master Boot Record (MBR):
646.Dl Ic newfs_msdos -r 16 /dev/rwd1a
647.Bd -ragged -offset indent-two -compact
648.Em Notes :
649The
650.Fl r Ar 16
651is to reserve space for the primary bootstrap.
652.Xr newfs_msdos 8
653will display an
654.Dq MBR type
655such as
656.Ql 1 ,
657.Ql 4 ,
658or
659.Ql 6 ;
660the MBR partition type of the appropriate primary partition should be
661changed to this value.
662.Ed
663.Dl Ic mount -t msdos /dev/wd1a /mnt
664.Dl Ic cp /usr/mdec/boot /mnt/boot
665.Dl Ic cp path/to/kernel /mnt/netbsd
666.Dl Ic umount /mnt
667.Dl Ic installboot -t raw /dev/rwd1a /usr/mdec/bootxx_msdos
668.Pp
669Make the existing FAT16 filesystem on
670.Sq sd0e
671bootable.
672This can be used to make USB memory bootable provided it has 512 byte
673sectors and that the manufacturer correctly initialised the file system.
674.Dl Ic mount -t msdos /dev/sd0e /mnt
675.Dl Ic cp /usr/mdec/boot /mnt/boot
676.Dl Ic cp path/to/kernel /mnt/netbsd
677.Dl Ic umount /mnt
678.Dl Ic installboot /dev/rsd0e /usr/mdec/bootxx_fat16
679It may also be necessary to use
680.Nm fdisk
681to make the device itself bootable.
682.
683.Pp
684Switch the existing installed bootstrap to use a serial console without
685reinstalling or altering other options such as timeout.
686.Dl Ic installboot -e -o console=com0 /dev/rwd0a
687.Ss Nx Ns Tn /macppc
688Note the
689.Nm
690utility is only required for macppc machines with OpenFirmware version 2
691to boot.
692OpenFirmware 3 cannot load bootblocks specified in the Apple partition
693map.
694.Pp
695Install the Berkeley Fast File System primary bootstrap on to disk
696.Sq wd0 :
697.Dl Ic installboot /dev/rwd0c /usr/mdec/bootxx /ofwboot
698.Pp
699The secondary
700.Nx Ns Tn /macppc
701bootstrap is located in
702.Pa /usr/mdec/ofwboot .
703.Pp
704The primary bootstrap requires the raw
705.Pa ofwboot
706for the secondary bootstrap, not
707.Pa ofwboot.xcf ,
708which is used for the OpenFirmware to load kernels.
709.Ss Nx Ns Tn /next68k
710Install the bootstrap on to disk
711.Sq sd0 :
712.Dl Ic installboot /dev/rsd0c /usr/mdec/boot
713.Pp
714.
715.Ss Nx Ns Tn /pmax
716Install the Berkeley Fast File System primary bootstrap on to disk
717.Sq sd0 :
718.Dl Ic installboot /dev/rsd0c /usr/mdec/bootxx_ffs
719.Pp
720.Nx Ns Tn /pmax
721requires that this file system starts at block 0 of the disk.
722.Pp
723Install the ISO 9660 primary bootstrap in the file
724.Pa /tmp/cd-image :
725.Dl Ic installboot -m pmax /tmp/cd-image /usr/mdec/bootxx_cd9660
726.Pp
727Make an ISO 9660 filesystem in the file
728.Pa /tmp/cd-image
729and install the ISO 9660 primary bootstrap in the filesystem, where the
730source directory for the ISO 9660 filesystem contains a kernel, the
731primary bootstrap
732.Pa bootxx_cd9660
733and the secondary bootstrap
734.Pa boot.pmax :
735.Dl Ic mkisofs -o /tmp/cd-image -a -l -v iso-source-dir
736.Dl ...
737.Dl 48 51 iso-source-dir/bootxx_cd9660
738.Dl ...
739.Dl Ic installboot -b `expr 48 \e* 4` /tmp/cd-image /usr/mdec/bootxx_cd9660
740.
741.Ss Nx Ns Tn /sparc
742Install the Berkeley Fast File System primary bootstrap on to disk
743.Sq sd0 ,
744with the secondary bootstrap
745.Sq Pa /boot
746already present:
747.Dl Ic installboot /dev/rsd0c /usr/mdec/bootxx /boot
748.
749.Ss Nx Ns Tn /sparc64
750Install the Berkeley Fast File System primary bootstrap on to disk
751.Sq wd0 :
752.Dl Ic installboot /dev/rsd0c /usr/mdec/bootblk
753.Pp
754The secondary
755.Nx Ns Tn /sparc64
756bootstrap is located in
757.Pa /usr/mdec/ofwboot .
758.
759.Ss Nx Ns Tn /sun2 and Nx Ns Tn /sun3
760Install the Berkeley Fast File System primary bootstrap on to disk
761.Sq sd0 ,
762with the secondary bootstrap
763.Sq Pa /boot
764already present:
765.Dl Ic installboot /dev/rsd0c /usr/mdec/bootxx /boot
766.
767.Sh SEE ALSO
768.Xr uname 3 ,
769.Xr boot 8 ,
770.Xr disklabel 8 ,
771.Xr dumpfs 8 ,
772.Xr fdisk 8 ,
773.Xr pxeboot 8
774.
775.Sh HISTORY
776This implementation of
777.Nm
778appeared in
779.Nx 1.6 .
780.
781.Sh AUTHORS
782The machine independent portion of this implementation of
783.Nm
784was written by Luke Mewburn.
785The following people contributed to the various machine dependent
786back-ends:
787Simon Burge (pmax),
788Chris Demetriou (alpha),
789Matthew Fredette (sun2, sun3),
790Matthew Green (sparc64),
791Ross Harvey (alpha),
792Michael Hitch (amiga),
793Paul Kranenburg (sparc),
794David Laight (i386),
795Christian Limpach (next68k),
796Luke Mewburn (macppc),
797Matt Thomas (vax),
798Izumi Tsutsui (news68k, newsmips),
799and
800UCHIYAMA Yasushi (ews4800mips).
801.
802.Sh BUGS
803There are not currently primary bootstraps to support all file systems
804types which are capable of being the root file system.
805.Pp
806If a disk has been converted from
807.Sy FFS
808to
809.Sy RAID
810without the contents of the disk erased, then the original
811.Sy FFS
812installation may be auto-detected instead of the
813.Sy RAID
814installation.
815In this case, the
816.Fl t Ar raid
817option must be provided.
818.
819.Ss Nx Ns Tn /alpha
820The
821.Nx Ns Tn /alpha
822primary bootstrap program can only load the secondary bootstrap program
823from file systems starting at the beginning (block 0) of disks.
824Similarly, the secondary bootstrap program can only load kernels from
825file systems starting at the beginning of disks.
826.Pp
827The size of primary bootstrap programs is restricted to 7.5KB, even
828though some file systems (e.g., ISO 9660) are able to accommodate larger
829ones.
830.
831.Ss Nx Ns Tn /hp300
832The disk must have a boot partition large enough to hold the bootstrap code.
833Currently the primary bootstrap must be a LIF format file.
834.
835.Ss Nx Ns Tn /i386 and Nx Ns Tn /amd64
836The bootstrap must be installed in the
837.Nx
838partition that starts at the beginning of the mbr partition.
839If that is a valid filesystem and contains the
840.Pa /boot
841program then it will be used as the root filesystem, otherwise the
842.Sq a
843partition will be booted.
844.Pp
845The size of primary bootstrap programs is restricted to 8KB, even
846though some file systems (e.g., ISO 9660) are able to accommodate larger
847ones.
848.
849.Ss Nx Ns Tn /macppc
850Due to restrictions in
851.Nm
852and the secondary bootstrap implementation, file systems where kernels exist
853must start at the beginning of disks.
854.Pp
855Currently,
856.Nm
857doesn't recognize an existing Apple partition map on the disk
858and always writes a faked map to make disks bootable.
859.Pp
860The
861.Nx Ns Tn /macppc
862bootstrap program can't load kernels from
863.Sy FFSv2
864partitions.
865.Ss Nx Ns Tn /next68k
866The size of bootstrap programs is restricted to the free space before
867the file system at the beginning of the disk minus 8KB.
868.
869.Ss Nx Ns Tn /pmax
870The
871.Nx Ns Tn /pmax
872secondary bootstrap program can only load kernels from file
873systems starting at the beginning of disks.
874.Pp
875The size of primary bootstrap programs is restricted to 7.5KB, even
876though some file systems (e.g., ISO 9660) are able to accommodate larger
877ones.
878.
879.Ss Nx Ns Tn /sun2 and Nx Ns Tn /sun3
880The
881.Nx Ns Tn /sun2
882and
883.Nx Ns Tn /sun3
884secondary bootstrap program can only load kernels from file
885systems starting at the beginning of disks.
886.
887.Ss Nx Ns Tn /vax
888The
889.Nx Ns Tn /vax
890secondary bootstrap program can only load kernels from file systems
891starting at the beginning of disks.
892.Pp
893The size of primary bootstrap programs is restricted to 7.5KB, even
894though some file systems (e.g., ISO 9660) are able to accommodate larger
895ones.
896