1 .\" $NetBSD: install,v 1.36 2009/04/25 10:34:42 snj Exp $
3 .\" Copyright (c) 1999-2002 The NetBSD Foundation, Inc.
4 .\" All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
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.
15 .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
16 .\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
17 .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
18 .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
19 .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
20 .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
21 .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22 .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23 .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
24 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25 .\" POSSIBILITY OF SUCH DAMAGE.
30 you need to first boot an installation
31 program and then interact with the menu-based program
33 The installation program actually consists of the
35 kernel plus an in-memory file system of utility programs.
37 The traditional procedure is to write the installation system to a floppy
38 disk set and then boot from the floppies.
39 However, there are six ways to boot the
42 Each approach loads the exact same installation bits.
46 .(bullet -offset indent
61 In all cases, you need to transfer a
62 bootable image of the installation system
65 CD or from an ftp site to the chosen media type.
66 Although booting from floppy is the usual path, the
67 hard drive boot is useful if you have another operating system (and a spare
68 drive) already installed, or if you don't mind swapping hard drives from
70 CD and tape boots are nice and fast if you have a CD writer
71 or a tape format in common with another previously installed
74 Finally, most versions of SRM can locate the
78 via bootp and download it via tftp.
80 then mounts the root file system
82 via NFS and loads the kernel.
84 Note that if you are installing or upgrading from a writable media,
85 the media can be write-protected if you wish.
86 These systems mount a root image from inside the kernel, and will not
87 need to write to the media.
88 If you booted from a floppy, the floppy disk may be removed from
89 the drive after the system has booted.
95 The 3.5", 1.44 MB boot floppy set is found under the
97 \*V distribution directory in
98 .Pa \*M/installation/floppy/
104 You need to put these disk images on three floppy disks.
108 system handy, you can do this with commands
111 .Dl # Ic "dd if=disk1of3 of=/dev/rfd0a bs=18k"
112 .Dl # Ic "dd if=disk2of3 of=/dev/rfd0a bs=18k"
113 .Dl # Ic "dd if=disk3of3 of=/dev/rfd0a bs=18k"
117 system you are using is not a
119 system, you will probably need to replace
121 with the name of the floppy device on your particular system.
127 system available, you can use
130 utility to transfer the image to a floppy
132 This utility is provided with the
135 .Pa i386/installation/misc ;
136 a documentation file,
138 is available there as well.
140 Once the floppy has been made, you simply need to put it in the
143 .Dl \*[Gt]\*[Gt]\*[Gt] Ic "B DVA0"
152 All three of these media types use the same initial image:
153 .Pa \&.../installation/diskimage/cdhdtape
154 The image can be written to a hard drive partition with a command
157 .Dl # Ic "dd if=cdhdtape of=/dev/rsd0c bs=16k"
159 To boot from a magnetic tape device such as
164 to create the tape image with 512-byte records.
167 .Dl # Ic "dd if=cdhdtape of=/dev/rst0 bs=512 conv=osync"
169 If the host system is not
171 the names of the destination devices are likely to be different.
174 device that doesn't skip over labels!
176 The use of CD-R devices varies greatly depending on the host OS
177 and host software; it isn't possible to give typical instructions here.
180 Existing Root FS Boot
182 The installation subdirectory
186 this is the same install kernel but without a bootable file system
187 image wrapped around it.
188 You can perform an complete reinstall by beginning it as an upgrade,
189 and booting this kernel in the normal way off the root file system
191 of a previous installation.
193 The gzipped image can be booted directly; it is not necessary to
201 \*V over a network requires a BOOTP or
202 DHCP server, a TFTP server and an NFS server.
203 (These are usually all run on the same machine.)
204 There are three basic stages to the boot:
209 \*M console software sends a BOOTP request to get its
210 own address, the address of the TFTP server and the file to
212 It downloads this file, which is the second stage bootstrap,
213 via TFTP and then executes it.
215 The secondary boot program resends the BOOTP request, this
216 time also locating the NFS server and root path.
217 It mounts the root path via NFS and reads in and transfers to the kernel:
220 The kernel probes and configures the devices, and then sends
221 out another BOOTP request so it can find out its address, the NFS
223 It then mounts its root
225 via NFS and continues.
229 You will need to set up servers for BOOTP, TFTP and NFS.
231 If you want to run a full system
232 from the network, untar the
234 distribution into a directory on your server and NFS export that directory
236 Make sure you put a kernel there as well, and create the device nodes in
239 .Ic sh ./MAKEDEV all .
240 Detailed instructions on netbooting can be found by visiting
241 .Lk http://www.NetBSD.org/docs/network/netboot/
243 You'll want to map root to
245 (rather than the default
247 when you export your root file system
255 .Dl /usr/export/\*M -maproot=0 myclient.mydom.com
257 One option is to load just the install kernel over the network but then
258 proceed to a normal disk-based install and disk-based operation.
259 (Perhaps the \*M doesn't have a floppy drive, or you just don't
262 system to make the floppy; we understand.)
264 For this case, you still need to export an NFS root, but
265 the only thing it needs to have in it is the
267 image from the distribution.
269 The gzipped image can be booted directly; it is not necessary to
272 The console will be using TFTP to load the
275 so for the TFTP setup, you need to copy the second stage bootstrap,
277 into an appropriately named file such as
279 in the directory used by your TFTP server.
280 If you extracted a full snapshot, you can get the netboot program from
281 .Pa /usr/mdec/netboot ;
282 if not, you can get this from the
283 .Pa installation/netboot
284 directory where you found the \*M distribution.
286 For the BOOTP server you need to specify the:
288 .(bullet -compact -offset indent
289 hardware type (Ethernet)
291 hardware address (Ethernet MAC address)
293 IP address of the client
295 subnet mask of the client
297 address of of the TFTP/NFS server
299 name of the second stage bootstrap loaded via TFTP
301 path to the root for the client (mounted via NFS)
305 Here's an example for a
311 :ht=ethernet:ha=0000c0391ae4:\e
312 :ip=192.168.1.2:sm=255.255.255.0:\e
313 :sa=192.168.1.1:bf=boot.netbsd.\*M:rp=/usr/export/\*M:
316 And here's an example for a
318 system running the ISC
322 hardware ethernet 0:0:c0:39:1a:e4;
323 fixed-address 192.168.1.2;
324 option host-name "myhost.mydom.com";
325 filename "boot.netbsd.\*M";
326 option root-path "/usr/export/\*M";
327 option domain-name-servers 192.168.1.1;
328 option broadcast-address 255.255.255.0;
329 option domain-name "my.domain";
333 The only Ethernet device the console on most \*M systems
334 knows how to boot from is the onboard Ethernet interface or a
336 Tulip (21040, 21041, 21140) PCI Ethernet card.
337 Some older SMC 100 Mbps cards that use this chip have been known to
339 Many older systems will not be able to use the newer 2.0 stepping
340 of the 21140, however.
341 If your system appears not to be receiving packets, this may be the problem.
342 (You may or may not be able to update your firmware to fix this; see
343 .Lk http://www.NetBSD.org/ports/alpha/
344 for more information on this.)
345 In general, 10 Mb cards from manufacturers other than
347 will work, and 100 Mb cards not from
351 Once you're set up, you should be able to boot with:
353 .Dl \*[Gt]\*[Gt]\*[Gt] Ic "boot -proto bootp ewa0"
355 You should permanently set your protocol to
359 .Dl \*[Gt]\*[Gt]\*[Gt] Ic "set ewa0_protocols bootp"
361 The 3000 series of Turbochannel systems and certain other models use
365 option and use different device names.
366 They also tend to not netboot very well so you probably don't
367 need to worry about this section.
368 However, if you want to give it a try, note the following differences:
369 .(bullet -offset indent
375 Old SRM uses bootp if the device name is given as
380 program will probably also be necessary, as it is unlikely that an SRM
381 from that era will properly communicate the ethernet HW address to the
386 .Dl \*[Gt]\*[Gt]\*[Gt] Ic "boot ez0"
392 .so ../common/sysinst