1*433d6423SLionel Sambuc.\" $NetBSD: boot.8,v 1.58 2011/05/31 03:43:47 uebayasi Exp $ 2*433d6423SLionel Sambuc.\" 3*433d6423SLionel Sambuc.\" Copyright (c) 1991, 1993 4*433d6423SLionel Sambuc.\" The Regents of the University of California. All rights reserved. 5*433d6423SLionel Sambuc.\" 6*433d6423SLionel Sambuc.\" This code is derived from software written and contributed 7*433d6423SLionel Sambuc.\" to Berkeley by William Jolitz. 8*433d6423SLionel Sambuc.\" 9*433d6423SLionel Sambuc.\" Redistribution and use in source and binary forms, with or without 10*433d6423SLionel Sambuc.\" modification, are permitted provided that the following conditions 11*433d6423SLionel Sambuc.\" are met: 12*433d6423SLionel Sambuc.\" 1. Redistributions of source code must retain the above copyright 13*433d6423SLionel Sambuc.\" notice, this list of conditions and the following disclaimer. 14*433d6423SLionel Sambuc.\" 2. Redistributions in binary form must reproduce the above copyright 15*433d6423SLionel Sambuc.\" notice, this list of conditions and the following disclaimer in the 16*433d6423SLionel Sambuc.\" documentation and/or other materials provided with the distribution. 17*433d6423SLionel Sambuc.\" 3. Neither the name of the University nor the names of its contributors 18*433d6423SLionel Sambuc.\" may be used to endorse or promote products derived from this software 19*433d6423SLionel Sambuc.\" without specific prior written permission. 20*433d6423SLionel Sambuc.\" 21*433d6423SLionel Sambuc.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 22*433d6423SLionel Sambuc.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23*433d6423SLionel Sambuc.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24*433d6423SLionel Sambuc.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 25*433d6423SLionel Sambuc.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 26*433d6423SLionel Sambuc.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27*433d6423SLionel Sambuc.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28*433d6423SLionel Sambuc.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29*433d6423SLionel Sambuc.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30*433d6423SLionel Sambuc.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31*433d6423SLionel Sambuc.\" SUCH DAMAGE. 32*433d6423SLionel Sambuc.\" 33*433d6423SLionel Sambuc.\" @(#)boot_i386.8 8.2 (Berkeley) 4/19/94 34*433d6423SLionel Sambuc.\" 35*433d6423SLionel Sambuc.Dd May 26, 2011 36*433d6423SLionel Sambuc.Dt BOOT 8 i386 37*433d6423SLionel Sambuc.Os 38*433d6423SLionel Sambuc.Sh NAME 39*433d6423SLionel Sambuc.Nm boot 40*433d6423SLionel Sambuc.Nd 41*433d6423SLionel Sambucsystem bootstrapping procedures 42*433d6423SLionel Sambuc.Sh DESCRIPTION 43*433d6423SLionel Sambuc.Tn IA-32 44*433d6423SLionel Sambuccomputers 45*433d6423SLionel Sambuc.Po 46*433d6423SLionel Sambucthe 47*433d6423SLionel Sambuc.Tn IBM PC 48*433d6423SLionel Sambucand its clones 49*433d6423SLionel Sambuc.Pc 50*433d6423SLionel Sambucthat can run 51*433d6423SLionel Sambuc.Nx Ns /i386 52*433d6423SLionel Sambuccan use any of the following boot procedures, depending on what the hardware and 53*433d6423SLionel Sambuc.Tn BIOS 54*433d6423SLionel Sambucsupport: 55*433d6423SLionel Sambuc.Pp 56*433d6423SLionel Sambuc.Bl -tag -width "pxeboot(8)" 57*433d6423SLionel Sambuc.It boot 58*433d6423SLionel Sambucbootstrap 59*433d6423SLionel Sambuc.Nx 60*433d6423SLionel Sambucfrom the system 61*433d6423SLionel Sambuc.Tn BIOS 62*433d6423SLionel Sambuc.It Xr dosboot 8 63*433d6423SLionel Sambucbootstrap 64*433d6423SLionel Sambuc.Nx 65*433d6423SLionel Sambucfrom 66*433d6423SLionel Sambuc.Tn MS-DOS 67*433d6423SLionel Sambuc.It Xr w95boot 8 68*433d6423SLionel Sambucbootstrap 69*433d6423SLionel Sambuc.Nx 70*433d6423SLionel Sambucfrom 71*433d6423SLionel Sambuc.Tn Windows 95 72*433d6423SLionel Sambuc.It Xr pxeboot 8 73*433d6423SLionel Sambucnetwork bootstrap 74*433d6423SLionel Sambuc.Nx 75*433d6423SLionel Sambucfrom a 76*433d6423SLionel Sambuc.Tn TCP/IP 77*433d6423SLionel Sambuc.Tn LAN 78*433d6423SLionel Sambucwith 79*433d6423SLionel Sambuc.Tn DHCP , 80*433d6423SLionel Sambuc.Tn TFTP , 81*433d6423SLionel Sambucand 82*433d6423SLionel Sambuc.Tn NFS . 83*433d6423SLionel Sambuc.El 84*433d6423SLionel Sambuc.Ss Power fail and crash recovery 85*433d6423SLionel SambucNormally, the system will reboot itself at power-up or after crashes. 86*433d6423SLionel SambucAn automatic consistency check of the file systems will be performed, 87*433d6423SLionel Sambucand unless this fails, the system will resume multi-user operations. 88*433d6423SLionel Sambuc.Ss Cold starts 89*433d6423SLionel SambucThe 386 90*433d6423SLionel Sambuc.Tn "PC AT" 91*433d6423SLionel Sambucclones attempt to boot the floppy disk drive A (otherwise known as drive 92*433d6423SLionel Sambuc0) first, and failing that, attempt to boot the hard disk C (otherwise 93*433d6423SLionel Sambucknown as hard disk controller 1, drive 0). 94*433d6423SLionel SambucThe 95*433d6423SLionel Sambuc.Nx 96*433d6423SLionel Sambucbootblocks are loaded and started either by the 97*433d6423SLionel Sambuc.Tn BIOS , 98*433d6423SLionel Sambucor by a boot selector program (such as OS-BS, BOOTEASY, the OS/2 Boot Menu or 99*433d6423SLionel Sambuc.Nx Ns 's 100*433d6423SLionel Sambuc.No boot-selecting 101*433d6423SLionel Sambucmaster boot record - see 102*433d6423SLionel Sambuc.Xr mbr 8 ) . 103*433d6423SLionel Sambuc.Ss Normal Operation 104*433d6423SLionel SambucOnce running, a banner similar to the following will appear: 105*433d6423SLionel Sambuc.Bd -unfilled -offset indent 106*433d6423SLionel Sambuc\*[Gt]\*[Gt] NetBSD BIOS Boot, revision 3.0 107*433d6423SLionel Sambuc\*[Gt]\*[Gt] (user@buildhost, builddate) 108*433d6423SLionel Sambuc\*[Gt]\*[Gt] Memory: 637/15360 k 109*433d6423SLionel SambucPress return to boot now, any other key for boot menu 110*433d6423SLionel Sambucbooting hd0a:netbsd - starting in 5 111*433d6423SLionel Sambuc.Ed 112*433d6423SLionel Sambuc.Pp 113*433d6423SLionel SambucAfter a countdown, the system image listed will be loaded. 114*433d6423SLionel SambucIn the example above, it will be 115*433d6423SLionel Sambuc.Dq Li hd0a:netbsd 116*433d6423SLionel Sambucwhich is the file 117*433d6423SLionel Sambuc.Nm netbsd 118*433d6423SLionel Sambucon partition 119*433d6423SLionel Sambuc.Dq a 120*433d6423SLionel Sambucof the 121*433d6423SLionel Sambuc.Nx 122*433d6423SLionel Sambuc.Tn MBR 123*433d6423SLionel Sambucpartition of the first hard disk known to the 124*433d6423SLionel Sambuc.Tn BIOS 125*433d6423SLionel Sambuc.Po 126*433d6423SLionel Sambucwhich is an 127*433d6423SLionel Sambuc.Tn IDE 128*433d6423SLionel Sambucor similar device - see the 129*433d6423SLionel Sambuc.Sx BUGS 130*433d6423SLionel Sambucsection 131*433d6423SLionel Sambuc.Pc . 132*433d6423SLionel Sambuc.Pp 133*433d6423SLionel SambucPressing a key within the time limit, or before the boot program starts, will 134*433d6423SLionel Sambucenter interactive mode. 135*433d6423SLionel SambucWhen using a short or 0 timeout, it is often useful to interrupt the boot 136*433d6423SLionel Sambucby holding down a shift key, as some BIOSes and BIOS extensions will drain the 137*433d6423SLionel Sambuckeystroke buffer at various points during POST. 138*433d6423SLionel Sambuc.Pp 139*433d6423SLionel SambucIf present, the file 140*433d6423SLionel Sambuc.Pa /boot.cfg 141*433d6423SLionel Sambucwill be used to configure the behaviour of the boot loader including 142*433d6423SLionel Sambucsetting the timeout, choosing a console device, altering the banner 143*433d6423SLionel Sambuctext and displaying a menu allowing boot commands to be easily chosen. 144*433d6423SLionel SambucSee 145*433d6423SLionel Sambuc.Xr boot.cfg 5 . 146*433d6423SLionel Sambuc.Pp 147*433d6423SLionel SambucThe 148*433d6423SLionel Sambuc.Nx Ns /i386 149*433d6423SLionel Sambucboot loader can boot a kernel using either the native 150*433d6423SLionel Sambuc.Nx 151*433d6423SLionel Sambucboot protocol, or the 152*433d6423SLionel Sambuc.Dq multiboot 153*433d6423SLionel Sambucprotocol (which is compatible with some other operating systems). 154*433d6423SLionel SambucIn the native 155*433d6423SLionel Sambuc.Nx 156*433d6423SLionel Sambucboot protocol, options are passed from the boot loader 157*433d6423SLionel Sambucto the kernel via flag bits in the 158*433d6423SLionel Sambuc.Va boothowto 159*433d6423SLionel Sambucvariable (see 160*433d6423SLionel Sambuc.Xr boothowto 9 ) . 161*433d6423SLionel SambucIn the multiboot protocol, options are passed from the boot loader 162*433d6423SLionel Sambucto the kernel as strings. 163*433d6423SLionel Sambuc.Ss Diagnostic Output 164*433d6423SLionel SambucIf the first stage boot fails to load the boot, it will print a terse 165*433d6423SLionel Sambucmessage indicating the reason for the failure. 166*433d6423SLionel SambucThe possible error messages and their cause are listed in 167*433d6423SLionel Sambuc.Xr mbr 8 . 168*433d6423SLionel Sambuc.Pp 169*433d6423SLionel SambucIf the first stage boot succeeds, the banner will be shown and the 170*433d6423SLionel Sambucerror messages should be self-explanatory. 171*433d6423SLionel Sambuc.Ss Interactive mode 172*433d6423SLionel SambucIn interactive mode, the boot loader will present a prompt, allowing 173*433d6423SLionel Sambucinput of these commands: 174*433d6423SLionel Sambuc.\" NOTE: much of this text is duplicated in the MI boot.8. 175*433d6423SLionel Sambuc.\" Some of it is 176*433d6423SLionel Sambuc.\" also duplicated in the i386-specific dosboot.8 and pxeboot.8; 177*433d6423SLionel Sambuc.\" please try to keep all relevant files synchronized. 178*433d6423SLionel Sambuc.Bl -tag -width 04n -offset 04n 179*433d6423SLionel Sambuc.It Ic boot Oo Va device : Ns Oc Oo Va filename Oc Oo Fl 1234abcdmqsvxz Oc 180*433d6423SLionel SambucThe default 181*433d6423SLionel Sambuc.Va device 182*433d6423SLionel Sambucwill be set to the disk that the boot loader was 183*433d6423SLionel Sambucloaded from. 184*433d6423SLionel SambucTo boot from an alternate disk, the full name of the device should 185*433d6423SLionel Sambucbe given at the prompt. 186*433d6423SLionel Sambuc.Va device 187*433d6423SLionel Sambucis of the form 188*433d6423SLionel Sambuc.Xo Va xd 189*433d6423SLionel Sambuc.Op Va N Ns Op Va x 190*433d6423SLionel Sambuc.Xc 191*433d6423SLionel Sambucwhere 192*433d6423SLionel Sambuc.Va xd 193*433d6423SLionel Sambucis the device from which to boot, 194*433d6423SLionel Sambuc.Va N 195*433d6423SLionel Sambucis the unit number, and 196*433d6423SLionel Sambuc.Va x 197*433d6423SLionel Sambucis the partition letter. 198*433d6423SLionel Sambuc.Pp 199*433d6423SLionel SambucThe following list of supported devices may vary from installation to 200*433d6423SLionel Sambucinstallation: 201*433d6423SLionel Sambuc.Pp 202*433d6423SLionel Sambuc.Bl -hang -compact 203*433d6423SLionel Sambuc.It hd 204*433d6423SLionel SambucHard disks as numbered by the BIOS. 205*433d6423SLionel SambucThis includes ST506, IDE, ESDI, RLL disks on a WD100[2367] or 206*433d6423SLionel Sambuclookalike controller(s), and SCSI disks 207*433d6423SLionel Sambucon SCSI controllers recognized by the BIOS. 208*433d6423SLionel Sambuc.It fd 209*433d6423SLionel SambucFloppy drives as numbered by the BIOS. 210*433d6423SLionel Sambuc.El 211*433d6423SLionel Sambuc.Pp 212*433d6423SLionel SambucThe default 213*433d6423SLionel Sambuc.Va filename 214*433d6423SLionel Sambucis 215*433d6423SLionel Sambuc.Pa netbsd ; 216*433d6423SLionel Sambucif the boot loader fails to successfully 217*433d6423SLionel Sambucopen that image, it then tries 218*433d6423SLionel Sambuc.Pa netbsd.gz 219*433d6423SLionel Sambuc(expected to be a kernel image compressed by gzip), followed by 220*433d6423SLionel Sambuc.Pa netbsd.old , 221*433d6423SLionel Sambuc.Pa netbsd.old.gz , 222*433d6423SLionel Sambuc.Pa onetbsd , 223*433d6423SLionel Sambucand finally 224*433d6423SLionel Sambuc.Pa onetbsd.gz . 225*433d6423SLionel SambucAlternate system images can be loaded by just specifying the name of the image. 226*433d6423SLionel Sambuc.Pp 227*433d6423SLionel SambucOptions are: 228*433d6423SLionel Sambuc.Bl -tag -width xxx 229*433d6423SLionel Sambuc.It Fl 1 230*433d6423SLionel SambucSets the machine-dependent flag 231*433d6423SLionel Sambuc.Sy RB_MD1 232*433d6423SLionel Sambucin 233*433d6423SLionel Sambuc.Va boothowto . 234*433d6423SLionel SambucIn 235*433d6423SLionel Sambuc.Nx Ns /i386 , 236*433d6423SLionel Sambucthis disables multiprocessor boot; 237*433d6423SLionel Sambucthe kernel will boot in uniprocessor mode. 238*433d6423SLionel Sambuc.It Fl 2 239*433d6423SLionel SambucSets the machine-dependent flag 240*433d6423SLionel Sambuc.Sy RB_MD2 241*433d6423SLionel Sambucin 242*433d6423SLionel Sambuc.Va boothowto . 243*433d6423SLionel SambucIn 244*433d6423SLionel Sambuc.Nx Ns /i386 , 245*433d6423SLionel Sambucthis disables ACPI. 246*433d6423SLionel Sambuc.It Fl 3 247*433d6423SLionel SambucSets the machine-dependent flag 248*433d6423SLionel Sambuc.Sy RB_MD3 249*433d6423SLionel Sambucin 250*433d6423SLionel Sambuc.Va boothowto . 251*433d6423SLionel SambucIn 252*433d6423SLionel Sambuc.Nx Ns /i386 , 253*433d6423SLionel Sambucthis has no effect. 254*433d6423SLionel Sambuc.It Fl 4 255*433d6423SLionel SambucSets the machine-dependent flag 256*433d6423SLionel Sambuc.Sy RB_MD4 257*433d6423SLionel Sambucin 258*433d6423SLionel Sambuc.Va boothowto . 259*433d6423SLionel SambucIn 260*433d6423SLionel Sambuc.Nx Ns /i386 , 261*433d6423SLionel Sambucthis has no effect. 262*433d6423SLionel Sambuc.It Fl a 263*433d6423SLionel SambucSets the 264*433d6423SLionel Sambuc.Sy RB_ASKNAME 265*433d6423SLionel Sambucflag in 266*433d6423SLionel Sambuc.Va boothowto . 267*433d6423SLionel SambucThis causes the kernel to prompt for the root file system device, 268*433d6423SLionel Sambucthe system crash dump device, and the path to 269*433d6423SLionel Sambuc.Xr init 8 . 270*433d6423SLionel Sambuc.It Fl b 271*433d6423SLionel SambucSets the 272*433d6423SLionel Sambuc.Sy RB_HALT 273*433d6423SLionel Sambucflag in 274*433d6423SLionel Sambuc.Va boothowto . 275*433d6423SLionel SambucThis causes subsequent reboot attempts to halt instead of rebooting. 276*433d6423SLionel Sambuc.It Fl c 277*433d6423SLionel SambucSets the 278*433d6423SLionel Sambuc.Sy RB_USERCONF 279*433d6423SLionel Sambucflag in 280*433d6423SLionel Sambuc.Va boothowto . 281*433d6423SLionel SambucThis causes the kernel to enter the 282*433d6423SLionel Sambuc.Xr userconf 4 283*433d6423SLionel Sambucdevice configuration manager as soon as possible during the boot. 284*433d6423SLionel Sambuc.Xr userconf 4 285*433d6423SLionel Sambucallows devices to be enabled or disabled, and allows device locators 286*433d6423SLionel Sambuc(such as hardware addresses or bus numbers) 287*433d6423SLionel Sambucto be modified before the kernel attempts to attach the devices. 288*433d6423SLionel Sambuc.It Fl d 289*433d6423SLionel SambucSets the 290*433d6423SLionel Sambuc.Sy RB_KDB 291*433d6423SLionel Sambucflag in 292*433d6423SLionel Sambuc.Va boothowto . 293*433d6423SLionel SambucRequests the kernel to enter debug mode, in which it 294*433d6423SLionel Sambucwaits for a connection from a kernel debugger; see 295*433d6423SLionel Sambuc.Xr ddb 4 . 296*433d6423SLionel Sambuc.It Fl m 297*433d6423SLionel SambucSets the 298*433d6423SLionel Sambuc.Sy RB_MINIROOT 299*433d6423SLionel Sambucflag in 300*433d6423SLionel Sambuc.Va boothowto . 301*433d6423SLionel SambucInforms the kernel that a mini-root file system is present in memory. 302*433d6423SLionel Sambuc.It Fl q 303*433d6423SLionel SambucSets the 304*433d6423SLionel Sambuc.Sy AB_QUIET 305*433d6423SLionel Sambucflag in 306*433d6423SLionel Sambuc.Va boothowto . 307*433d6423SLionel SambucBoot the system in quiet mode. 308*433d6423SLionel Sambuc.It Fl s 309*433d6423SLionel SambucSets the 310*433d6423SLionel Sambuc.Sy RB_SINGLE 311*433d6423SLionel Sambucflag in 312*433d6423SLionel Sambuc.Va boothowto . 313*433d6423SLionel SambucBoot the system in single-user mode. 314*433d6423SLionel Sambuc.It Fl v 315*433d6423SLionel SambucSets the 316*433d6423SLionel Sambuc.Sy AB_VERBOSE 317*433d6423SLionel Sambucflag in 318*433d6423SLionel Sambuc.Va boothowto . 319*433d6423SLionel SambucBoot the system in verbose mode. 320*433d6423SLionel Sambuc.It Fl x 321*433d6423SLionel SambucSets the 322*433d6423SLionel Sambuc.Sy AB_DEBUG 323*433d6423SLionel Sambucflag in 324*433d6423SLionel Sambuc.Va boothowto . 325*433d6423SLionel SambucBoot the system with debug messages enabled. 326*433d6423SLionel Sambuc.It Fl z 327*433d6423SLionel SambucSets the 328*433d6423SLionel Sambuc.Sy AB_SILENT 329*433d6423SLionel Sambucflag in 330*433d6423SLionel Sambuc.Va boothowto . 331*433d6423SLionel SambucBoot the system in silent mode. 332*433d6423SLionel Sambuc.El 333*433d6423SLionel Sambuc.It Ic consdev Va dev 334*433d6423SLionel SambucImmediately switch the console to the specified device 335*433d6423SLionel Sambuc.Va dev 336*433d6423SLionel Sambucand reprint the banner. 337*433d6423SLionel Sambuc.Va dev 338*433d6423SLionel Sambucmust be one of 339*433d6423SLionel Sambuc.\" .Bl -item -width com[0123]kbd -offset indent -compact 340*433d6423SLionel Sambuc.Ar pc , com0 , com1 , com2 , 341*433d6423SLionel Sambuc.Ar com3 , com0kbd , com1kbd , com2kbd , 342*433d6423SLionel Sambuc.Ar com3kbd , 343*433d6423SLionel Sambucor 344*433d6423SLionel Sambuc.Ar auto . 345*433d6423SLionel SambucSee 346*433d6423SLionel Sambuc.Sx Console Selection Policy 347*433d6423SLionel Sambucin 348*433d6423SLionel Sambuc.Xr boot_console 8 . 349*433d6423SLionel Sambuc.It Ic dev Op Va device 350*433d6423SLionel SambucSet the default drive and partition for subsequent filesystem 351*433d6423SLionel Sambucoperations. 352*433d6423SLionel SambucWithout an argument, print the current setting. 353*433d6423SLionel Sambuc.Va device 354*433d6423SLionel Sambucis of the form specified in 355*433d6423SLionel Sambuc.Cm boot . 356*433d6423SLionel Sambuc.It Ic help 357*433d6423SLionel SambucPrint an overview about commands and arguments. 358*433d6423SLionel Sambuc.It Ic load Va module Op Ar arguments 359*433d6423SLionel SambucLoad the specified kernel 360*433d6423SLionel Sambuc.Va module , 361*433d6423SLionel Sambucand pass it the specified 362*433d6423SLionel Sambuc.Ar arguments . 363*433d6423SLionel SambucIf the module name is not an absolute path, 364*433d6423SLionel Sambuc.Pa /stand/ Xo Ns 365*433d6423SLionel Sambuc.Aq Sy arch Ns 366*433d6423SLionel Sambuc.Pa / Ns 367*433d6423SLionel Sambuc.Aq Sy osversion Ns 368*433d6423SLionel Sambuc.Pa /modules/ Ns 369*433d6423SLionel Sambuc.Aq Sy module Ns 370*433d6423SLionel Sambuc.Pa / Ns 371*433d6423SLionel Sambuc.Aq Sy module Ns 372*433d6423SLionel Sambuc.Pa .kmod 373*433d6423SLionel Sambuc.Xc 374*433d6423SLionel Sambucis used. 375*433d6423SLionel SambucPossible used of the 376*433d6423SLionel Sambuc.Ic load 377*433d6423SLionel Sambuccommand include loading a memory disk image before booting a kernel, 378*433d6423SLionel Sambucor loading a 379*433d6423SLionel Sambuc.Tn Xen 380*433d6423SLionel SambucDOM0 kernel before booting the 381*433d6423SLionel Sambuc.Tn Xen 382*433d6423SLionel Sambuchypervisor. 383*433d6423SLionel SambucSee 384*433d6423SLionel Sambuc.Xr boot.cfg 5 385*433d6423SLionel Sambucfor examples. 386*433d6423SLionel Sambuc.Pp 387*433d6423SLionel SambucIn addition to the 388*433d6423SLionel Sambuc.Cm boot 389*433d6423SLionel Sambucoptions specified above, the DOM0 kernel accepts 390*433d6423SLionel Sambuc.Po Ar arguments 391*433d6423SLionel Sambucbeing separated with spaces 392*433d6423SLionel Sambuc.Pc : 393*433d6423SLionel Sambuc.Bl -tag -width xxx 394*433d6423SLionel Sambuc.It Ic bootdev Ns = Ns Ar dev Po or Ic root Ns = Ns Ar dev Pc 395*433d6423SLionel SambucOverride the default boot device. 396*433d6423SLionel Sambuc.Ar dev 397*433d6423SLionel Sambuccan be a unit name 398*433d6423SLionel Sambuc.Po Dq wd0 399*433d6423SLionel Sambuc.Pc , 400*433d6423SLionel Sambucor an interface name 401*433d6423SLionel Sambuc.Po Dq bge0 , 402*433d6423SLionel Sambuc.Dq wm0 , 403*433d6423SLionel Sambuc.Ns ... 404*433d6423SLionel Sambuc.Pc , 405*433d6423SLionel Sambucfor cases where the root file system has to be loaded 406*433d6423SLionel Sambucfrom network (see the 407*433d6423SLionel Sambuc.Sx BUGS 408*433d6423SLionel Sambucsection in 409*433d6423SLionel Sambuc.Xr pxeboot 8 ) . 410*433d6423SLionel Sambuc.It Ic console Ns = Ns Ar dev 411*433d6423SLionel SambucConsole used by DOM0 kernel during boot. 412*433d6423SLionel Sambuc.Ar dev 413*433d6423SLionel Sambucaccepts the same values as the ones given for the 414*433d6423SLionel Sambuc.Cm consdev 415*433d6423SLionel Sambuccommand. 416*433d6423SLionel SambucSee 417*433d6423SLionel Sambuc.Sx Console Selection Policy 418*433d6423SLionel Sambucin 419*433d6423SLionel Sambuc.Xr boot_console 8 . 420*433d6423SLionel Sambuc.It Xo Ic ip Ns = Ns 421*433d6423SLionel Sambuc.Ar my_ip Ns : Ns Ar serv_ip Ns : Ns Ar gw_ip Ns : Ns 422*433d6423SLionel Sambuc.Ar mask Ns : Ns Ar host Ns : Ns Ar iface 423*433d6423SLionel Sambuc.Xc 424*433d6423SLionel SambucSpecify various parameters for a network boot (IPs are in 425*433d6423SLionel Sambucdot notation), 426*433d6423SLionel Sambuceach one separated by a colon: 427*433d6423SLionel Sambuc.Bl -tag -width xxxxxxx 428*433d6423SLionel Sambuc.It Va my_ip 429*433d6423SLionel Sambucaddress of the host 430*433d6423SLionel Sambuc.It Va serv_ip 431*433d6423SLionel Sambucaddress of the NFS server 432*433d6423SLionel Sambuc.It Va gw_ip 433*433d6423SLionel Sambucaddress of the gateway 434*433d6423SLionel Sambuc.It Va mask 435*433d6423SLionel Sambucnetwork mask 436*433d6423SLionel Sambuc.It Va host 437*433d6423SLionel Sambucaddress of the host 438*433d6423SLionel Sambuc.It Va iface 439*433d6423SLionel Sambucinterface 440*433d6423SLionel Sambuc.Po e.g. Dq xennet0 441*433d6423SLionel Sambucor 442*433d6423SLionel Sambuc.Dq eth0 443*433d6423SLionel Sambuc.Pc 444*433d6423SLionel Sambuc.El 445*433d6423SLionel Sambuc.It Ic nfsroot Ns = Ns Ar address Ns : Ns Ar rootpath 446*433d6423SLionel SambucBoot the system with root on NFS. 447*433d6423SLionel Sambuc.Ar address 448*433d6423SLionel Sambucis the address of the NFS server, and 449*433d6423SLionel Sambuc.Ar rootpath 450*433d6423SLionel Sambucis the remote mount point for the root file system. 451*433d6423SLionel Sambuc.It Ic pciback.hide Ns = Ns Ar pcidevs 452*433d6423SLionel SambucPass a list of PCI IDs for use with the PCI backend driver, 453*433d6423SLionel Sambuc.Xr pciback 4 . 454*433d6423SLionel Sambuc.Ar pcidevs 455*433d6423SLionel Sambucis formed of multiple IDs (in bus:device.function notation), 456*433d6423SLionel Sambuceach ID being surrounded with brackets. 457*433d6423SLionel SambucPCI domain IDs are currently ignored. 458*433d6423SLionel SambucSee 459*433d6423SLionel Sambuc.Xr pciback 4 . 460*433d6423SLionel Sambuc.El 461*433d6423SLionel Sambuc.It Ic load_mods Va mods_path_pattern 462*433d6423SLionel SambucLoad modules specified by pattern like /some_path/mod*. 463*433d6423SLionel Sambuc.It Ic ls Op Pa path 464*433d6423SLionel SambucPrint a directory listing of 465*433d6423SLionel Sambuc.Pa path , 466*433d6423SLionel Sambuccontaining inode number, filename, and file type. 467*433d6423SLionel Sambuc.Pa path 468*433d6423SLionel Sambuccan contain a device specification. 469*433d6423SLionel Sambuc.It Ic modules Bro Ar on | off | enabled | disabled Brc 470*433d6423SLionel SambucThe values 471*433d6423SLionel Sambuc.Ar enabled , on 472*433d6423SLionel Sambucwill enable module loading for 473*433d6423SLionel Sambuc.Cm boot 474*433d6423SLionel Sambucand 475*433d6423SLionel Sambuc.Cm multiboot , 476*433d6423SLionel Sambucwhereas 477*433d6423SLionel Sambuc.Ar disabled , off 478*433d6423SLionel Sambucwill turn off the feature. 479*433d6423SLionel Sambuc.It Ic multiboot Va kernel Op Ar arguments 480*433d6423SLionel SambucBoot the specified 481*433d6423SLionel Sambuc.Va kernel , 482*433d6423SLionel Sambucusing the 483*433d6423SLionel Sambuc.Dq multiboot 484*433d6423SLionel Sambucprotocol instead of the native 485*433d6423SLionel Sambuc.Nx 486*433d6423SLionel Sambucboot protocol. 487*433d6423SLionel SambucThe 488*433d6423SLionel Sambuc.Va kernel 489*433d6423SLionel Sambucis specified in the same way as with the 490*433d6423SLionel Sambuc.Ic boot 491*433d6423SLionel Sambuccommand. 492*433d6423SLionel Sambuc.Pp 493*433d6423SLionel SambucThe multiboot protocol may be used in the following cases: 494*433d6423SLionel Sambuc.Bl -tag -width indent 495*433d6423SLionel Sambuc.It Nx Ns / Ns Xen No kernels 496*433d6423SLionel SambucThe 497*433d6423SLionel Sambuc.Tn Xen 498*433d6423SLionel SambucDOM0 kernel must be loaded as a module using the 499*433d6423SLionel Sambuc.Ic load 500*433d6423SLionel Sambuccommand, and the 501*433d6423SLionel Sambuc.Tn Xen 502*433d6423SLionel Sambuchypervisor must be booted using the 503*433d6423SLionel Sambuc.Ic multiboot 504*433d6423SLionel Sambuccommand. 505*433d6423SLionel SambucOptions for the DOM0 kernel (such as 506*433d6423SLionel Sambuc.Dq -s 507*433d6423SLionel Sambucfor single user mode) must be passed as options to the 508*433d6423SLionel Sambuc.Ic load 509*433d6423SLionel Sambuccommand. 510*433d6423SLionel SambucOptions for the hypervisor (such as 511*433d6423SLionel Sambuc.Dq dom0_mem=256M 512*433d6423SLionel Sambucto reserve 256 MB of memory for DOM0) 513*433d6423SLionel Sambucmust be passed as options to the 514*433d6423SLionel Sambuc.Ic multiboot 515*433d6423SLionel Sambuccommand. 516*433d6423SLionel SambucSee 517*433d6423SLionel Sambuc.Xr boot.cfg 5 518*433d6423SLionel Sambucfor examples on how to boot 519*433d6423SLionel Sambuc.Nx Ns / Ns Xen. 520*433d6423SLionel Sambuc.It Nx No multiboot kernels 521*433d6423SLionel SambucA 522*433d6423SLionel Sambuc.Nx 523*433d6423SLionel Sambuckernel that was built with 524*433d6423SLionel Sambuc.Cd options MULTIBOOT 525*433d6423SLionel Sambuc(see 526*433d6423SLionel Sambuc.Xr multiboot 8 ) 527*433d6423SLionel Sambucmay be booted with either the 528*433d6423SLionel Sambuc.Ic boot 529*433d6423SLionel Sambucor 530*433d6423SLionel Sambuc.Ic multiboot 531*433d6423SLionel Sambuccommand, passing the same 532*433d6423SLionel Sambuc.Ar arguments 533*433d6423SLionel Sambucin either case. 534*433d6423SLionel Sambuc.It Non- Ns Nx No kernels 535*433d6423SLionel SambucA kernel for a 536*433d6423SLionel Sambuc.No non- Ns Nx 537*433d6423SLionel Sambucoperating system that expects to be booted using the 538*433d6423SLionel Sambucmultiboot protocol (such as by the GNU 539*433d6423SLionel Sambuc.Dq GRUB 540*433d6423SLionel Sambucboot loader) 541*433d6423SLionel Sambucmay be booted using the 542*433d6423SLionel Sambuc.Ic multiboot 543*433d6423SLionel Sambuccommand. 544*433d6423SLionel SambucSee the foreign operating system's documentation for the available 545*433d6423SLionel Sambuc.Ar arguments . 546*433d6423SLionel Sambuc.El 547*433d6423SLionel Sambuc.It Ic quit 548*433d6423SLionel SambucReboot the system. 549*433d6423SLionel Sambuc.It Ic userconf Va command 550*433d6423SLionel SambucPass the 551*433d6423SLionel Sambuc.Va command 552*433d6423SLionel Sambucto 553*433d6423SLionel Sambuc.Xr userconf 4 554*433d6423SLionel Sambucat boot time . 555*433d6423SLionel SambucThese commands are processed before the interactive 556*433d6423SLionel Sambuc.Xr userconf 4 557*433d6423SLionel Sambucshell is executed, if requested . 558*433d6423SLionel Sambuc.It Ic vesa Bro Va modenum | Ar on | off | enabled | disabled | list Brc 559*433d6423SLionel SambucInitialise the video card to the specified resolution and bit depth. 560*433d6423SLionel SambucThe 561*433d6423SLionel Sambuc.Va modenum 562*433d6423SLionel Sambucshould be in the form of 563*433d6423SLionel Sambuc.Ar 0x100 , 800x600 , 800x600x32 . 564*433d6423SLionel SambucThe values 565*433d6423SLionel Sambuc.Ar enabled , on 566*433d6423SLionel Sambucput the display into the default mode, and 567*433d6423SLionel Sambuc.Ar disabled , off 568*433d6423SLionel Sambucreturns the display into standard vga mode. 569*433d6423SLionel SambucThe value 570*433d6423SLionel Sambuc.Ar list 571*433d6423SLionel Sambuclists all supported modes. 572*433d6423SLionel Sambuc.El 573*433d6423SLionel Sambuc.Pp 574*433d6423SLionel SambucIn an emergency, the bootstrap methods described in the 575*433d6423SLionel Sambuc.Nx 576*433d6423SLionel Sambucinstallation notes for the i386 architecture 577*433d6423SLionel Sambuccan be used to boot from floppy or other media, 578*433d6423SLionel Sambucor over the network. 579*433d6423SLionel Sambuc.Sh FILES 580*433d6423SLionel Sambuc.Bl -tag -width /usr/mdec/bootxx_fstype -compact 581*433d6423SLionel Sambuc.It Pa /boot 582*433d6423SLionel Sambucboot program code loaded by the primary bootstrap 583*433d6423SLionel Sambuc.It Pa /boot.cfg 584*433d6423SLionel Sambucoptional configuration file 585*433d6423SLionel Sambuc.It Pa /netbsd 586*433d6423SLionel Sambucsystem code 587*433d6423SLionel Sambuc.It Pa /netbsd.gz 588*433d6423SLionel Sambucgzip-compressed system code 589*433d6423SLionel Sambuc.It Pa /usr/mdec/boot 590*433d6423SLionel Sambucmaster copy of the boot program (copy to /boot) 591*433d6423SLionel Sambuc.It Pa /usr/mdec/bootxx_fstype 592*433d6423SLionel Sambucprimary bootstrap for filesystem type fstype, copied to the start of 593*433d6423SLionel Sambucthe 594*433d6423SLionel Sambuc.Nx 595*433d6423SLionel Sambucpartition by 596*433d6423SLionel Sambuc.Xr installboot 8 . 597*433d6423SLionel Sambuc.El 598*433d6423SLionel Sambuc.Sh SEE ALSO 599*433d6423SLionel Sambuc.Xr ddb 4 , 600*433d6423SLionel Sambuc.Xr pciback 4 , 601*433d6423SLionel Sambuc.Xr userconf 4 , 602*433d6423SLionel Sambuc.Xr boot.cfg 5 , 603*433d6423SLionel Sambuc.Xr boot_console 8 , 604*433d6423SLionel Sambuc.Xr dosboot 8 , 605*433d6423SLionel Sambuc.Xr halt 8 , 606*433d6423SLionel Sambuc.Xr installboot 8 , 607*433d6423SLionel Sambuc.Xr mbr 8 , 608*433d6423SLionel Sambuc.Xr multiboot 8 , 609*433d6423SLionel Sambuc.Xr pxeboot 8 , 610*433d6423SLionel Sambuc.Xr reboot 8 , 611*433d6423SLionel Sambuc.Xr shutdown 8 , 612*433d6423SLionel Sambuc.Xr w95boot 8 , 613*433d6423SLionel Sambuc.Xr boothowto 9 614*433d6423SLionel Sambuc.Sh BUGS 615*433d6423SLionel SambucThe kernel file name must be specified before, not after, the boot options. 616*433d6423SLionel SambucAny 617*433d6423SLionel Sambuc.Ar filename 618*433d6423SLionel Sambucspecified after the boot options, e.g.: 619*433d6423SLionel Sambuc.Pp 620*433d6423SLionel Sambuc.Bd -unfilled -offset indent -compact 621*433d6423SLionel Sambuc.Cm boot -d netbsd.test 622*433d6423SLionel Sambuc.Ed 623*433d6423SLionel Sambuc.Pp 624*433d6423SLionel Sambucis ignored, and the default kernel is booted. 625*433d6423SLionel Sambuc.Pp 626*433d6423SLionel SambucHard disks are always accessed by 627*433d6423SLionel Sambuc.Tn BIOS 628*433d6423SLionel Sambucfunctions. 629*433d6423SLionel SambucUnit numbers are 630*433d6423SLionel Sambuc.Tn BIOS 631*433d6423SLionel Sambucdevice numbers which might differ from numbering in the 632*433d6423SLionel Sambuc.Nx 633*433d6423SLionel Sambuckernel or physical parameters 634*433d6423SLionel Sambuc.Po 635*433d6423SLionel Sambuce.g., 636*433d6423SLionel Sambuc.Tn SCSI 637*433d6423SLionel Sambucslave numbers 638*433d6423SLionel Sambuc.Pc . 639*433d6423SLionel SambucThere isn't any distinction between 640*433d6423SLionel Sambuc.Dq sd 641*433d6423SLionel Sambucand 642*433d6423SLionel Sambuc.Dq wd 643*433d6423SLionel Sambucdevices at the bootloader level. 644*433d6423SLionel SambucThis is less a bug of the bootloader code than 645*433d6423SLionel Sambuca shortcoming of the PC architecture. 646*433d6423SLionel SambucThe default disk device's name printed in the starting message 647*433d6423SLionel Sambucis derived from the 648*433d6423SLionel Sambuc.Dq type 649*433d6423SLionel Sambucfield of the 650*433d6423SLionel Sambuc.Nx 651*433d6423SLionel Sambucdisklabel (if it is a hard disk). 652