Please note: There is a new program version for DNS called BIND 8. The
old version used slightly different setup files such as "named.boot" rather
than "named.conf" as in the new version. This is why you may see confusing
documentation in books and on the web. I have tried to document BIND 8 here.
domain=mycompany.com. nameserver=mymachine=10.1.0.100 mail server=mailmachine=10.1.0.4 Windows box=10.1.3.16.
|
The line "nospoof on" checks for IP address spoofing and "alert on" will send
a warning if an attempt to spoof is detected. The order command specifies that
when the client is resolving names to first look in the /etc/host file, then use
BIND8 (DNS) to resolve the name. Another valid option for the command order is
nis which stands for Network Information Service, created by Sun. The line
"multi on" specifies that all valid addresses for a host found in the hosts file
should be returned. This means that the same host name will be returned for a
machine that has more than one network address such as a machine that interfaces
to two or more networks. For example I have a machine interfacing to network
192.168.199.0 at IP address 192.168.199.1 and the other interface is on network
10.1.0.0 at IP address 10.1.1.100. It allows both networks to refer to the
machine with the same name.
domain mycompany.com search mycompany.com mynet.net nameserver 127.0.0.1 nameserver 10.1.0.100
Commands:
// generated by named-bootconf.pl options { directory "/var/named"; /* * 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; }; zone "." { type hint; file "named.ca"; }; zone "0.0.127.in-addr.arpa" { type master; file "named.local"; }; zone "1.10.in-addr.arpa" { type master; file "db.10.1.hosts"; allow transfer { 127.0.0.1; }; }; zone "mycompany.com" { type master; file "db.mycompany.com.hosts"; notify yes; allow transfer { 127.0.0.1; }; };
Commands:
There are many more options associated with this file. For more information,
read the BIND configuration file guide for BIND version 8 or higher. The option
"allow transfer", above, limits DNS zone transfers to the loopback address. If
there were a slave nameserver, its IP address should be here. With the allow
transfer option set, other machines cannot get DNS information. This limits the
effectiveness of IP spoofers and spammers.
A.ROOT-SERVERS.NET. 3600000 A 10.1.0.100
but this is not correct. Some versions of the name server will generate error
messages to var/log/messages if this is done.
I use:
; This file holds the information on root name servers needed to ; initialize cache of Internet domain name servers ; (e.g. reference this file in the "cache . <file>" ; configuration file of BIND domain name servers). ; ; This file is made available by InterNIC registration services ; under anonymous FTP as ; file /domain/named.root ; on server FTP.RS.INTERNIC.NET ; -OR- under Gopher at RS.INTERNIC.NET ; under menu InterNIC Registration Services (NSI) ; submenu InterNIC Registration Archives ; file named.root ; ; last update: Aug 22, 1997 ; related version of root zone: 1997082200 ; ; ; formerly NS.INTERNIC.NET ; . 3600000 IN NS A.ROOT-SERVERS.NET. A.ROOT-SERVERS.NET. 3600000 A 201.12.27.33 ; ; formerly NS1.ISI.EDU ; . 3600000 NS B.ROOT-SERVERS.NET. B.ROOT-SERVERS.NET. 3600000 A 128.9.0.107 ; ; formerly C.PSI.NET ; . 3600000 NS C.ROOT-SERVERS.NET. C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12 ; ; formerly TERP.UMD.EDU ; . 3600000 NS D.ROOT-SERVERS.NET. D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90 ; ; formerly NS.NASA.GOV ; . 3600000 NS E.ROOT-SERVERS.NET. E.ROOT-SERVERS.NET. 3600000 A 192.203.230.10 ; ; formerly NS.ISC.ORG ; . 3600000 NS F.ROOT-SERVERS.NET. F.ROOT-SERVERS.NET. 3600000 A 192.5.5.241 ; ; formerly NS.NIC.DDN.MIL ; . 3600000 NS G.ROOT-SERVERS.NET. G.ROOT-SERVERS.NET. 3600000 A 192.112.36.4 ; ; formerly AOS.ARL.ARMY.MIL ; . 3600000 NS H.ROOT-SERVERS.NET. H.ROOT-SERVERS.NET. 3600000 A 128.63.2.53 ; ; formerly NIC.NORDU.NET ; . 3600000 NS I.ROOT-SERVERS.NET. I.ROOT-SERVERS.NET. 3600000 A 192.36.148.17 ; ; temporarily housed at NSI (InterNIC) ; . 3600000 NS J.ROOT-SERVERS.NET. J.ROOT-SERVERS.NET. 3600000 A 198.41.0.10 ; ; housed in LINX, operated by RIPE NCC ; . 3600000 NS K.ROOT-SERVERS.NET. K.ROOT-SERVERS.NET. 3600000 A 193.0.14.129 ; ; temporarily housed at ISI (IANA) ; . 3600000 NS L.ROOT-SERVERS.NET. L.ROOT-SERVERS.NET. 3600000 A 198.32.64.12 ; ; housed in Japan, operated by WIDE ; ;. 3600000 NS M.ROOT-SERVERS.NET. ;M.ROOT-SERVERS.NET. 3600000 A 202.12.27.33 ; End of File
The official root nameserver file is at ftp:.rs.internic.net and is called
/domain/named.root.
@ IN SOA localhost. root.localhost. ( 1999112701 ; Serial number as date and two digit number YYMMDDXX 28800 ; Refresh in seconds 28800=8H 7200 ; Retry in seconds 7200=2H 3600000 ; Expire 3600000=1 week 86400) ; Minimum TTL 86400=24Hours @ IN NS localhost. 1 IN PTR localhost.
1.10.in-addr.arpa. IN SOA mymachine.mycompany.com.\ root.mymachine.mycompany.com. ( 1999112701 10800 3600 604800 86400 ) ;Default TTL 1.10.in-addr.arpa. IN NS mymachine.mycompany.com. 100.0.1.10.in-addr.arpa. IN PTR mymachine.mycompany.com. 4.0.1.10.in-addr.arpa. IN PTR mailmachine.mycompany.com. 16.3.1.10.in-addr.arpa. IN PTR george.mycompany.com.
In the SOA section are five parameters as follows:
mycompany.com. IN SOA mymachine.mycompany.com. root.mymachine.mycompany.com. ( 1999112701 10800 3600 604800 86400 ) mycompany.com. IN NS mymachine.mycompany.com. mycompany.com. IN MX 10 mailmachine.mycompany.com. mymachine.mycompany.com. IN A 10.1.0.100 mailmachine.mycompany.com. IN A 10.1.0.4 george.mycompany.com. IN A 10.1.3.16
Database Record Description:
Other notes:
To get it running:
Type "ps ax |more to see all processes running and look to see
if it is one of them.
If it is look and see if it is listed in /etc/services. If not add the following
lines to the file.
nameserver 42/tcp name domain 53/tcp nameserver domain 53/udp nameserver
Type "ndc start" or "ndc restart".
Other pertinent files:
/etc/nsswitch.conf - Several system administration database source files are defined here This is in support of the Network Information System (NIS) which can be used to control many administrative functions on many systems from one location.
|About Linux || Linux Command || User Creation Command || file Permission || File System || Ttips and Tricks ||
|| Lan Setup || NFS Server || DNS Server|| Samba Server || TelNet || FTP Server
Copyright © 2000 - 2005 sourabhvikas. All rights reserved Worldwide. |
Feedback || Disclaimer || Privacy Policy |