Merge branch 'vendor/TCPDUMP' (version 4.3.0 -> 4.9.3)
[dragonfly.git] / share / examples / diskless / ME
1 IMPORTANT NOTE:
2
3 For quite some time
4 the /etc/rc.d/{initdiskless,diskless} scripts support a slightly different
5 diskless boot process than the one documented in the rest of this file.
6
7 I am not deleting the information below because it contains some
8 useful background information on diskless operation, but for the
9 actual details you should look at diskless(8), /etc/rc.d/initdiskless,
10 /etc/rc.d/diskless,
11 and the /usr/share/examples/diskless/clone_root script which can
12 be useful to set up clients and server for diskless boot.
13
14 --- $FreeBSD: src/share/examples/diskless/ME,v 1.3.4.1 2002/03/15 06:52:38 luigi Exp $ ---
15 ------------------------------------------------------------------------
16
17 When templating, /conf/ME is typically a softlink to
18 /conf/<appropriate-machine>.  When doing a diskless boot, /conf/ME is
19 retargeted by /etc/rc.diskless1 from pointing to the server to pointing
20 to the client's directory, /conf/<ip-address-of-client>.  The retargeting
21 is accomplished through an MFS -o union mount.
22
23 When templating, this softlink should be different for each machine.
24 When doing a diskless boot, this softlink is typically part of the / NFS
25 mount from the server and points to the server's conf directory, but gets
26 retargeted during the /etc/rc.diskless1 phase.
27
28 System-wide configuration files must generally be targeted through /conf/ME.
29 For example, your /etc/rc.conf.local should become a softlink to
30 /conf/ME/rc.conf.local and your real rc.conf.local should go into the 
31 appropriate /conf/<appropriate-machine> directory.  This is also true of
32 /etc/rc.local, /etc/fstab, /etc/syslog.conf, /etc/ccd.conf, /etc/ipfw.conf,
33 /etc/motd, /etc/resolv.conf, and possibly even /etc/ttys ( if you want
34 to start an X session up on boot on certain of your machines ).
35
36 When templating, you duplicate your / and /usr partitions on each machine's
37 local disk from a single master ( assuming /var and /home reside elsewhere ),
38 EXCEPT for the /conf/ME softlink.  The /conf/ME softlink is the only thing
39 on / that should be different for each machine.
40
41 There are often categories of configuration files.  For example, all of your
42 shell machines may use one resolv.conf while all of your mail proxies may
43 use another.  Configuration files can be categorized fairly easily through
44 /conf/HT.<category> directories.  You put the actual configuration file in
45 /conf/HT.<category> and make a softlink from
46 /conf/ME/<appropriate-machines>/config-file to "../HT.<category/config-file".
47 This means that access to these files tends to run through more than one
48 softlink.  The advantage is that for all the complexity of your /conf
49 directory hierarchy, most of your common config files exist in only one place
50 in reality.
51
52