- 1 network with 30 Win95/Linux PC (I will now take only 3 PC for the demonstration)
- 1 NT 3.51 server (I don't use it, it's a file server on my network)
- 1 Linux RH5.0 (486 DX2/66, 12 Mb ram)
- The PC's address are :192.168.10.1 - dnsserver.mydomain : Linux RH5.0
192.168.10.2 - m1.mydomain : win95
192.168.10.3 - m2.mydomain : win95
192.168.10.4 - m3.mydomain : linux
Also, be careful with Red Hat versions : with 5.1 and previous, you modify /etc/named.boot, but with RH 5.2 and later it's /etc/named.conf (see below).
File : /etc/resolv.conf
search mydomain nameserver 192.168.10.1
directory /var/named cache . named.ca primary 0.0.127.in-addr.arpa named.local primary 10.168.192.in-addr.arpa db.192.168.10.hosts primary mydomain db.mydomain.hostsPlease note the "." (dot) between cache and named.ca on the second line.
File : /etc/named.conf (for RH >= 5.2)
zone "10.168.192.in-addr.arpa" {
type master;
file "db.10.168.192.hosts";
};
zone "mydomain" {
type master;
file "db.mydomain.hosts";
};
File : /var/named/named.ca
Modify the line "A.ROOT-SERVERS.NET. to put your Linux box address :
A.ROOT-SERVERS.NET. 3600000 A 192.168.10.1
File : /var/named/named.local
unchanged
Create a file /var/named/db.192.168.10.hosts
10.168.192.in-addr.arpa. IN SOA dnsserver.mydomain. admin.dnsserver.mydomain. ( 23 10800 3600 604800 86400 ) 10.168.192.in-addr.arpa. IN NS dnsserver.mydomain. 1.10.168.192.in-addr.arpa. IN PTR dnsserver.mydomain. 2.10.168.192.in-addr.arpa. IN PTR m1.mydomain. 3.10.168.192.in-addr.arpa. IN PTR m2.mydomain. 4.10.168.192.in-addr.arpa. IN PTR m3.mydomain.
mydomain. IN SOA dnsserver.mydomain. admin.dnsserver.mydomain. ( 23 10800 3600 604800 86400 ) mydomain. IN NS dnsserver.mydomain. dnsserver.mydomain. IN A 192.168.10.1 m1.mydomain. IN A 192.168.10.2 m2.mydomain. IN A 192.168.10.3 m3.mydomain. IN A 192.168.10.4
search mydomain nameserver 192.168.10.1 nameserver www.xxx.yyy.zzz (your ISP)In /etc/named.boot, add : forwarders xxx.yyy.zzz.ttt (your ISP's address) options forward-only This will allow you to resolve names from the internet, whene your linux box is a gateway between local and internet network.
The Linux Webring: [ Previous | Next | Home | Random | List ]