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