In this exercise, you will register a new domain, something.presanog.org.bt. You will create master nameservice on your own machine, and someone else will be your slave.
Firstly, note that each machine in the classroom has been given a working DNS name: pcX.presanog.org.bt. Configure your server with its real name: e.g. for pc23
# hostname pc23.presanog.org.bt # vi /etc/rc.conf ... hostname="pc23.presanog.org.bt" # vi /etc/hosts ... 192.188.58.87 pc23.presanog.org.bt
(You should see the new name at the login screen on the console)
# mkdir /etc/namedb/master # mkdir /etc/namedb/slave # chown bind /etc/namedb/slave
$TTL 10m @ IN SOA pcXX.presanog.org.bt. your.email.address. ( 2004030500 ; Serial 10m ; Refresh 10m ; Retry 4w ; Expire 10m ) ; Negative IN NS pcXX.presanog.org.bt. ; master IN NS pcYY.presanog.org.bt. ; slave www IN A 192.188.58.xx ; your own IP
(Note that we have chosen purposely low values for TTL, refresh, retry. For a production domain you would use higher values, e.g. $TTL 1d)
# named-checkzone xxxxxx.presanog.org.bt /etc/namedb/master/xxxxxx.presanog.org.bt If there are any errors, correct them # rndc reload # tail /var/log/messages If there are any errors, correct them
# dig +norec @192.188.58.xx xxxxxx.presanog.org.bt. soa # dig +norec @192.188.58.yy xxxxxx.presanog.org.bt. soa Check that you get an AA (authoritative answer) from both, and that the serial numbers match
Domain name: ___________________.presanog.org.bt Master nameserver: pc____.presanog.org.bt Slave nameserver: pc____.presanog.org.bt Slave nameserver: pc____.presanog.org.bt (optional) Slave nameserver: pc____.presanog.org.bt (optional)