DNS Server setup Service name is named make sure to turn it on to start at boot Run linuxconf go to Service Control Activity select named check Automatic check levels 2 through 5 (These levels will run the program) To start it by hand. /etc/rc.d/init.d/named stop /etc/rc.d/init.d/named start /etc/rc.d/init.d/named restart The log file /var/log/messages will inform you of how well things went. edit the /etc/resolv.conf file and change the nameserver to your local address. nameserver 123.123.123.123 assuming 123.123.123.123 is you ip address, or you could use 127.0.0.1 since this is your loopback ip. You need a named.conf file in the /etc/ directory and zone files in the /var/named/zone/ directory Create directory: /var/named/zone if it doesn't already exist The named.conf file should look something like this: // generated by named-bootconf.pl options { directory "/var/named"; forwarders {209.87.79.232;209.87.64.70;}; version "Microsoft NT 3.5 v1.02"; /* * If there is a firewall between you and nameservers you want * to talk to, you might need to uncomment the query-source * directive below. Previous versions of BIND always asked * questions using port 53, but BIND 8.1 uses an unprivileged * port by default. */ // query-source address * port 53; }; controls { inet 127.0.0.1 allow { localhost; } keys { rndckey; }; }; zone "." IN { type hint; file "root.hints"; }; zone "localhost" IN { type master; file "localhost.zone"; allow-update { none; }; }; zone "0.0.127.in-addr.arpa" IN { type master; file "named.local"; allow-update { none; }; }; zone "coolwebsite.org" IN { type master; file "zone/coolwebsite.org"; allow-update {none; }; }; zone "bettersites.org" IN { type master; file "zone/bettersites.org"; allow-update {none; }; }; include "/etc/rndc.key"; Note: the rndc.key file is used for remote updating. If you have your allow-updates turned off, you don't need it. The /var/named/ directory should have localhost.zone named.ca named.local root.hints and the zone directory Example file in the zone directory follows: Note: Whenever you change anything in the zone files always change the serial number. When named restarts it looks at the serial number and if changed, updates its records otherwise it won't read your changes. Most people use the date and an incremental number such as 200207125 for 7/12/2002 the 6th change today. File coolwebsite.org $TTL 86400 ; 1 day @ IN SOA coolwebsite.org. root.coolwebsite.org. ( ; Note: The site names and comp name above must ; end with a period. The period means that the name ; is fully resolved. 200207120 ;serial, todays date + increment 8H ; refresh, seconds 2H ; retry, seconds 4W ; expire, seconds 1D ) ; minimum, seconds NS ns.coolwebsite.org. ; Note: name ends in period MX 10 mail.coolwebsite.com. ; Note: name ends in period A 123.123.123.123 ns A 123.123.123.123 ; Note: Since these don't end in a www A 123.123.123.123 ; period the program correctly assumes mail A 123.123.123.123 ; coolwebsite.org is appended to them. File bettersites.org would look similar. if you are using iptables remember to open up access to port 53 domain The iptables.rule.src has the 2 domain lines remmed out with # signs. Remove the # signs.