Answer: This answer assumes that your boot scripts are already running svscan in a /service directory. tinydns relies on svscan to start it and to restart it at boot time.
You will have to make three decisions:
/usr/local/dnscache/bin/tinydns-conf tinydns dnslog /etc/tinydns 1.2.3.5
Tell svscan about the new service:
ln -s /etc/tinydns /service
svscan will start the service within one minute.
Now tell tinydns to answer questions about the heaven.af.mil and 3.2.1.in-addr.arpa domains, and to advertise 1.2.3.5 as the DNS server address for each domain:
cd /service/tinydns/root
./add-ns heaven.af.mil 1.2.3.5
./add-ns 3.2.1.in-addr.arpa 1.2.3.5
make
You can also add host addresses and mail-server addresses, as described below.
Finally, tell the administrator of af.mil to delegate heaven.af.mil to the server a.ns.heaven.af.mil running on IP address 1.2.3.5. Similarly, tell the administrator of 2.1.in-addr.arpa to delegate 3.2.1.in-addr.arpa to the server a.ns.3.2.1.in-addr.arpa running on IP address 1.2.3.5.
Answer:
cd /service/tinydns/root
./add-host lion.heaven.af.mil 1.2.3.4
./add-host tiger.heaven.af.mil 1.2.3.5
./add-host bear.heaven.af.mil 1.2.3.6
make
The ./add-host scripts edit the file
/service/tinydns/root/data,
which is in
tinydns-data format.
make runs the
tinydns-data program
to tell tinydns about the new information.
If anything goes wrong,
tinydns-data prints an error message,
and tinydns continues providing the old information.
As an alternative to ./add-host, you can edit data manually, adding the following lines:
=lion.heaven.af.mil:1.2.3.4
=tiger.heaven.af.mil:1.2.3.5
=bear.heaven.af.mil:1.2.3.6
But the ./add-host scripts
will prevent you from accidentally reusing a previous host name,
or reusing a previous IP address.
They're also very careful in how they write the new file to disk,
so nothing can go wrong if there's a sudden power outage.
Answer:
cd /service/tinydns/root
./add-mx heaven.af.mil 1.2.3.4
make
(mx stands for ``mail exchanger.'')
As an alternative to add-mx,
you can edit data manually,
adding the following line:
@heaven.af.mil:1.2.3.4:a
If you add several mail servers for heaven.af.mil,
use a for the first, b for the second, etc.
add-mx handles this automatically.
Answer: First, use tinydns-conf to configure tinydns on 1.2.3.6:
/usr/local/dnscache/bin/tinydns-conf tinydns dnslog /etc/tinydns 1.2.3.6
ln -s /etc/tinydns /service
Next, add your favorite file-management tools to /service/tinydns/root/Makefile on 1.2.3.5 so that changes in /service/tinydns/root/data are automatically copied to 1.2.3.6.
Now tell tinydns about the new server:
cd /service/tinydns/root
./add-ns heaven.af.mil 1.2.3.6
./add-ns 3.2.1.in-addr.arpa 1.2.3.6
make
Finally, tell the administrator of af.mil to add a delegation of heaven.af.mil to the server b.ns.heaven.af.mil running on IP address 1.2.3.6. Similarly, tell the administrator of 2.1.in-addr.arpa to add a delegation of 3.2.1.in-addr.arpa to the server b.ns.3.2.1.in-addr.arpa running on IP address 1.2.3.6.
Answer:
cd /service/tinydns/root
./add-childns elysium.heaven.af.mil 1.2.3.144
make
As an alternative to add-childns,
you can edit data manually,
adding the following line:
&elysium.heaven.af.mil:1.2.3.144:a
If you delegate heaven.af.mil to several IP addresses,
use a for the first, b for the second, etc.
add-childns handles this automatically.