setup.txt 6.53 KB
Newer Older
##### Setting up the Utah Network Testbed software on a boss node
##### Tested on FreeBSD 4.3, FreeBSD 4.5, FreeBSD 4.6, and FreeBSD 4.7

Jay Lepreau's avatar
Jay Lepreau committed
6 7 8
##### Step -1 - Set up "ops"

Follow the instructions in the setup-ops.txt file before the ones in this file!

##### Step 0 - OS installation and setup

Install FreeBSD on the machine you'll be using for your boss node, using the
13 14 15 16 17 18 19 20 21
standard FreeBSD installation process.  When asked by the installer, it's best
to choose the 'Developer' distribution set - this gets you full sources. The
'X-Developer' distribution set would be fine too, if you want to be able to run
X clients from the boss node.  When it asks if you want to install the ports
collection, answer yes.  You don't need to worry about which packages to
install (of course, grab your favorite editors, etc.) - the ones our software
needs will be installed automatically later.  You, will, however, have to make
sure that you create a partition large enough to hold /usr/testbed - in
addition to the testbed software, this is where many disk images will get
22 23 24 25
stored. The /var partition will need to be large enough to hold the database -
100MB extra for the database should be sufficient. Also, since we'll be building
and installing a lot of software from the ports tree, you'll want to make sure
that /usr is at least 2 GB.

27 28
Make sure that you have the network correctly configured, and make sure that it
has a hostname that resolves. The silly mysql-server port requires this.

30 31 32 33
If you want, you can go ahead and create an account for yourself on boss. For
now, just stick the home directory somewhere local, and move it to /users/ once
you've got it mounted from ops (the boss-install script will set this up). In
general, it's probably simpler to just use 'root' for now.

##### Step 1 - Create a defs file

37 38 39
The defs file will describe some of your setup, such as the hostnames of your
boss and ops nodes, and email addresses that certain types of mail will be sent

41 42
Use the 'defs-example' file in the root of our source distribution as a
template. It contains comments explaining the important variables to set.

##### Step 2 -  Unpacking and running configure

This works the same as it did on ops:
cd ~/tbobj
~/testbed/configure --with-TBDEFS=/users/ricci/testbed/defs-ricci

##### Step 3 - Running the boss installation script

Jay Lepreau's avatar
Jay Lepreau committed
Again, this works the same as it did on ops, except that you run
install/boss-install in the object tree, instead of ops-install.

55 56 57
Part way through, this script will bail out and prompt you to install some
ports. Some of the ports we need on boss have interactive installations, and
this generally takes a long time, and you want to see what's going on, right?

59 60 61 62 63
So, just cd to /usr/ports/misc/emulab-boss/ and run (as root) a 'make install'.
There are a few things you'll need to know about the ports:
* Installation of the mysql323-server port will fail if the name returned by
  'hostname' doesn't resolve.
* The php4 port will bring up a funky menu system to let you choose some
64 65
  features to enable and disable. Enable 'mhash' and 'xmlrpc', and
  leave the rest alone.
66 67
* The snmp port asks all kinds of silly questions that don't matter, since
  we're not going to be running snmpd on boss. Just take the defaults.

When you're done, re-run the boss-install script.

71 72
Like the ops-install script, boss-install sets up paswordless sudo for anyone
in the wheel group.

74 75 76 77 78 79
There is one bootstrapping problem we have that needs to be worked around - we
put fully-qualified names for the ops/users node into /etc/fstab on boss. But,
if you're running the nameserver for this domain on boss, those names won't be
resolvable yet. Since we don't yet have a way to auto-generate DNS
configuration files, the suggested work-around is to add addresses for the
FSNODE and USERNODE that you specified in your defs file (which may be the same
thing), to /etc/hosts on boss. Remember to remove them once you really have
81 82
DNS set up.

##### Step 4 - Installing from source.

85 86
In your object directory, do a 'gmake && gmake boss-install'. Then, as root, do
a 'gmake post-install'. The post-install target needs to run as root, so that
it can make certain scripts setuid, etc.

##### Step 5 - Setting up root ssh from boss to ops

91 92 93 94
The boss node needs to be able to ssh in, as root, to the ops node. To set this
up, copy root's public identity from boss (created by the boss-install script)
to ops's authorized_keys file:
scp /root/.ssh/ ops:/root/.ssh/authorized_keys

##### Step 6 - Filling the database

98 99
See the file setup-db.txt in this directory for instructions on getting the
proper information about your site and nodes into the database.
Leigh B. Stoller's avatar
Leigh B. Stoller committed

##### Step 7 - Other miscellaneous things to set up

103 104
There are a few things we haven't been able to completely automate just yet,
though we hope to soon. 

106 107 108
DNS configuration - boss-install enables bind on your boss node, but does not
set it up as a server for your domain. We don't have documentation for creating
the zone files, etc yet. Best bet right now is to ask Utah for a copy of
109 110 111 112 113 114 115
theirs. You need to include boss and ops in your domain, but NOT the nodes -
these will be added for you automatically.  Once done, add as the
first nameserver in /etc/resolv.conf . Also, add boss as the first nameserver
on ops, too. If you're running under the domain, too, make sure to
get Utah to delegate the subdomain to you. If you have any hardware (eg.
switches or power controllers) on a private subnet, add them to /etc/hosts,
with the same name they've been give in the database.

117 118 119 120
hosts file - It's a good idea to put ops' name/IP address in /etc/hosts - this
helps out NFS mounts, which are typically done before the nameserver is started,
and is generally helpful if things go wrong with the nameserver.

121 122
SSL certificates - Our apache config file expects to find SSL certificates in:
/usr/local/etc/apache/ssl.crt/www.<sitename>.crt and
124 125 126 127
(where <sitename> is OURDOMAIN from the configure defs file.) 
Generate a passwordless certificate (up to you if you want to get a 'real' one
from Verisign, etc., or sign your own), and place the files from it in the
above locations.

129 130 131 132 133
tftpboot - There are a few bootloaders, mini-kernels, and MFSes that are used
to boot, reload, etc. testbed machines, which live in /tftpboot . For the time
being, these are not distributed with our source, and require some site
customizations, so ask Utah for the boot loaders, etc.

disk images - You'll also, of course, need disk images to go on your nodes.
135 136
Right now, we have no automatic way of generating these, so you'll have to ask
Utah for some.