Deleted Added
sdiff udiff text old ( 69059 ) new ( 70466 )
full compact
1.\" $NetBSD: diskless.8,v 1.11 1997/06/16 07:50:35 mrg Exp $
2.\"
3.\" Copyright (c) 1994 Gordon W. Ross, Theo de Raadt
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:

--- 11 unchanged lines hidden (view full) ---

20.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27.\"
28.\" $FreeBSD: head/share/man/man8/diskless.8 69059 2000-11-22 18:00:50Z phantom $
29.\"
30.Dd October 2, 1994
31.Dt DISKLESS 8
32.Os
33.Sh NAME
34.Nm diskless
35.Nd booting a system over the network
36.Sh DESCRIPTION

--- 6 unchanged lines hidden (view full) ---

43This file provides a general description of the interactions between
44a client and its server when a client is booting over the network.
45The general description is followed by specific instructions for
46configuring a server for diskless Sun clients.
47.Sh OPERATION
48When booting a system over the network, there are three
49phases of interaction between client and server:
50.Pp
51.Bl -tag -width 1.2 -compact
52.It 1.
53The PROM (or stage-1 bootstrap) loads a boot program.
54.It 2.
55The boot program loads a kernel.
56.It 3.
57The kernel does NFS mounts for root.
58.El
59.Pp
60Each of these phases are described in further detail below.
61.Pp
62In phase 1, the PROM loads a boot program. PROM designs
63vary widely, so this phase is inherently machine-specific.
64Sun machines use

--- 11 unchanged lines hidden (view full) ---

76network boot program either from diskette or
77using a special PROM on the network card.
78.Pp
79In phase 2, the boot program loads a kernel. Operation in
80this phase depends on the design of the boot program.
81(The design described here is the one used by Sun and NetBSD/hp300.)
82The boot program:
83.Pp
84.Bl -tag -width 2.2 -compact
85.It 2.1
86gets the client IP address using
87.Tn RARP .
88.It 2.2
89gets the client name and server
90.Tn IP
91address by broadcasting an
92.Tn RPC / BOOTPARAMS / WHOAMI

--- 20 unchanged lines hidden (view full) ---

113.El
114.Pp
115In phase 3, the kernel does NFS mounts for root.
116The kernel repeats much of the work done by the boot program
117because there is no standard way for the boot program to pass
118the information it gathered on to the kernel.
119The procedure used by the kernel is as follows:
120.Pp
121.Bl -tag -width 2.2 -compact
122.It 3.1
123The kernel finds a boot server using the same procedure
124as described in steps 2.1 and 2.2 above.
125.It 3.2
126The kernel gets the
127.Tn NFS
128file handle for root using the same procedure
129as described in steps 2.3 through 2.5 above.

--- 7 unchanged lines hidden (view full) ---

137Before a client can boot over the network,
138its server must be configured correctly.
139This example will demonstrate how a Sun client
140might be configured -- other clients should be similar.
141.Pp
142Assuming the client's hostname is to be
143"myclient",
144.Pp
145.Bl -tag -width 2.1 -compact
146.It 1.
147Add an entry to
148.Pa /etc/ethers
149corresponding to the client's ethernet address:
150.Bd -literal -offset indent -compact
1518:0:20:7:c5:c7 myclient
152.Ed
153This will be used by
154.Xr rarpd 8 .
155.Pp
156.It 2.
157Assign an IP address for myclient in your
158.Pa /etc/hosts
159or DNS database:
160.Bd -literal -offset indent -compact
161192.197.96.12 myclient
162.Ed
163.Pp
164.It 3.
165If booting a Sun machine, ensure that
166.Pa /etc/inetd.conf
167is configured to run
168.Xr tftpd 8
169in the directory
170.Pa /tftpboot .
171.Pp
172If booting an HP 300-series machine, ensure that
173.Pa /etc/rbootd.conf
174is configured properly to transfer the boot program to the client.
175An entry might look like this:
176.Bd -literal -offset indent -compact
17708:00:09:01:23:E6 SYS_UBOOT # myclient
178.Ed
179.Pp
180See the
181.Xr rbootd 8
182manual page for more information.
183.Pp
184.It 4.
185If booting a SPARC machine, install a copy of the appropriate diskless boot
186loader (such as
187.Pa /usr/mdec/boot )
188in the
189.Pa /tftpboot
190directory.
191Make a link such that the boot program is
192accessible by a file name composed of the client's IP address

--- 14 unchanged lines hidden (view full) ---

207.Pp
208If booting an HP 300-series machine, ensure that the network boot program
209.Pa SYS_UBOOT
210(which may be called
211.Pa uboot.lif
212before installation)
213is installed in the directory
214.Pa /usr/mdec/rbootd .
215
216.It 5.
217Add myclient to the bootparams database
218.Pa /etc/bootparams :
219.Bd -literal -offset indent -compact
220myclient root=server:/export/myclient/root
221.Ed
222.Pp
223Note: For the swap file to be mountable, you have to make sure that mountd is
224started with the
225.Fl r
226flag.
227
228.It 6.
229Build the swap file for myclient:
230.Bd -literal -offset indent -compact
231# mkdir /export/myclient
232# cd /export/myclient
233# dd if=/dev/zero of=swap bs=16k count=1024
234.Ed
235This creates a 16 Megabyte swap file.
236.Pp
237.It 7.
238Populate myclient's
239.Pa /
240filesystem on the server. How this is done depends on the
241client architecture and the version of the NetBSD distribution.
242It can be as simple as copying and modifying the server's root
243filesystem, or perhaps you need to get those files out of the
244standard binary distribution.
245.Pp
246Note that, unlike SunOS, you need to create a mount point for the
247client's swap:
248.Bd -literal -offset indent -compact
249# mkdir /export/myclient/root/swap
250.Ed
251.Pp
252.It 8.
253Export the required filesystems in
254.Pa /etc/exports :
255.Bd -literal -offset indent -compact
256/usr -ro myclient
257# for SunOS:
258# /export/myclient -rw=myclient,root=myclient
259# for NetBSD:
260/export/myclient -maproot=root -alldirs myclient

--- 12 unchanged lines hidden (view full) ---

273.Pa /export/usr.sun3
274and then use the following
275.Pa /etc/exports
276lines:
277.Bd -literal -offset indent -compact
278/export/usr.sun3 -ro myclient
279/export/myclient -rw=myclient,root=myclient
280.Ed
281.Pp
282.It 9.
283Copy and customize at least the following files in
284.Pa /export/myclient/root :
285.Bd -literal -offset indent -compact
286# cd /export/myclient/root/etc
287# cp fstab.nfs fstab
288# cp /etc/hosts hosts
289# echo myclient > myname
290# echo 192.197.96.12 > hostname.le0
291.Ed
292.Pp
293Note that "le0" above should be replaced with the name of
294the network interface that the client will use for booting.
295.Pp
296.It 10.
297Correct the critical mount points and the swap file in the client's
298.Pa /etc/fstab
299(which will be
300.Pa /export/myclient/root/etc/fstab )
301ie.
302.Bd -literal -offset indent -compact
303myserver:/export/myclient/root / nfs rw 0 0
304myserver:/usr /usr nfs rw 0 0

--- 33 unchanged lines hidden ---