I like having the DNARDs each have a unique IP address, so I can tell which of them is down if one bombs out. To accomplish this, I've set up the DHCP mappings on a per-hardware-address basis. Typing in all of the hardware addresses can be a pain; this perl script will open the serial port, and read the DNARD boot prompt off of it. Just plug your dnard in, and it'll snarf it out. Be sure to change the $ddir settings, and if you use a different serial port, change the open line too. It puts entries like:
015 08:00:2b:81:61:ea February 25, 1998 17:19:25in the "hardware" file. It assigns the numbers in a monotonically increasing fashion. Handy when you've got a labeling machine, too.
Once the hardware file is created, I use another script to parse it out and create the remainder of the dhcpd.conf file. I concatenate the output of this with our dhcpd.conf.head file to create the full dhcpd.conf file. Note: Don't use our dhcpd.conf file, it won't work for you! :) I've provided it here as an (abbreviated) example of how to set things up.
/z/dnard/ dhcp/ - Holds the dhcpd, and conf files. root/ - Holds the entire NetBSD filesystem swap/ - Holds the per-machine swapfiles I create a swap file for each of the DNARDs in /z/dnard/swap. I call them 'swap.dnard#', but that's up to you. The changes to /etc/rc mentioned below assume this convention.
Dnard filesystem setupBecause we can't tell the DNARDs their swap device until after they boot, and they don't have independent /etc directories, I modified /etc/rc to mount their particular swapfile, and then create the MFS which holds their /tmp and /var/run. The modified /etc/rc can be found here. The changes are the section that says:echo "doing the funky DNARD swap thing" mount moab.cs.utah.edu:/z/dnard/swap/swap.`hostname` /swap chmod 700 /swap /sbin/swapon /swap echo -n " mfs-tmp" mount_mfs -s 65535 -b 8192 -f 1024 -m 1 swap /tmp mount_mfs -s 2048 -b 8192 -f 1024 -m 1 swap /var/run echo "188.8.131.52" > /var/yp/binding/cs.utah.edu.ypserversChange the paths and such to your own servers, of course. The change to ypservers was simply a quick hack so I could have independent binding dirs. Take it or leave it. :-)
DNARD /etcWe modified /etc/syslog.conf on the DNARDs to log to a central host with a real backing store, so we can have saved output and not need to make /var/log a symlink. In our case, we simply log to one of the DNARDs, so all logfiles are accessible in /var/log.
We run ssh on the DNARDs. I've simply set them up with a single, shared set of ssh* files in /etc, and they haven't seemed to complain. Your mileage may vary - I haven't explored the effects of allowing all of the hosts to share a single ssh_random_seed file. If it becomes a problem for you, let me know.
We don't set the machine identity in their /etc, instead allowing the machines to gather this information via DHCP. It'a automatic, so just leave them unset. Things like /etc/mygate should be common for all of the machines in your cluster anyway, so set them as you normally would. Note that we do NOT set the machines up as DHCP clients (dhclient=YES). If you'd like, you can see how we set up the rc.conf file.
DNARD directory setupIf you use YP, Remove /var/yp/binding and replace it with a symlink to ../run/ (the mfs).
Create a /swap directory to hold the mounted swap partition.
Problems?If there are inaccuracies or goofs in this, please mail me. If you have generic NetBSD-arm32/dnard questions, check out the resources I mentioned above; they'll likely give you better assistance.
David G Andersen Last modified: Fri May 21 15:40:57 MDT 1999