DNS Server Configuration

  


Simple DNS Server Configuration 1: Install the DNS-related package bind-chroot-9.3.4-10.P1.el5bind-libs-9.3.4-10. P1.el5ypbind-1.19-11.el5bind-utils-9.3.4-10.P1.el5bind-9.3.4-10.P1.el5rpm –ivh for example: rpm –ivh ind-chroot-9.3.4-10. Others of P1.el5 are also installed like this. 2: You also need to install a DNS reference package to facilitate the installation of DNS ie caching-nameserver-9.3.4-10.P1.el5.i386.rpmrpm –ivh caching-nameserver-9.3.4-10.P1.el5.i386 .rpm3: Configure DNS's main configuration file cd /var/named/chroot/etc and then cp –p named.caching-nameserver.conf named.conf4: Edit named.confVim named.conf to line 15, 27, 36, 37 Change the localhost to any and save the exit wq5:vim named.rfc1912.zones copy the 15-19 lines, then paste the changes to the zone "localdomain" IN { type master; file "localdomain.zone"; allow-update { none; }; }; changed to zone "abc.com" IN { type master; file "abc.com.db"; allow-update { none; }; };6:cd /var/named/chroot /var/namedCp –p localhost.zone abc.com.db Then edit the contents of Vim abc.com.db to: $TTL 86400@ IN SOA ns.abc.com. root.sina.com. ( 42 ; Serial (d. adams) 3H ; refresh 15M ; retry 1W ; expiry 1D ) ; minimum IN NS ns.abc.com.ns IN A 192.168.100.60www IN A 1.1.1.1ftp IN A 2.2.2.2mail IN A 3.3.3.3@ IN MX 10 mailpop3 IN CNAME mailsmtp IN CNAME mail 6: Save and exit after editing, then start DNS server Service named restart; 7: Test DNS server configuration successfully test 1: Nslookup www.abc.com correct result Server: 127.0.0.1Address: 127.0. 0.1#53 Name: www.abc.comAddress: 1.1.1.1


Test 2: Nslookup mail.abc.comServer: 127.0.0.1Address: 127.0.0.1#53 N Ame: mail.abc.comAddress: 3.3.3.3 Test 3: Nslookup ftp.abc.comServer: 127.0.0.1Address: 127.0.0.1#53 Name: ftp.abc.comAddress: 2.2.2.2 Test 4: Nslookup ns.abc. comServer: 127.0.0.1Address: 127.0.0.1#53 Name: ns.abc.comAddress: 192.168.100.60 Configure the secondary DNS server Description: Continue with the above experiment 1: Take the above as the primary DNS server 2: Now another Open a host configuration auxiliary DNS server 3: First install the DNS required package for this newly opened machine, configure the DNS server, as explained above, if you do not refer to the above 4: After installing the DNS server Service named start5 : Configure the DNS configuration server's main configuration file cd /var/named/chroot/etc and then cp –p named.caching-nameserver.conf named.confVim named.conf to change the localhost of lines 15, 27, 36, 37 to any You can save and exit wq6: vim named.rfc1912.zones copy the 15-19 lines, then paste the changes to zone "localdomain" IN { type master; file "localdomain.zone&quo t;; allow-update { none; }; }; changed to zone "abc.com" IN { type slave; master { 192.168.100.60; }; note that there is at least one space before the address, the semicolon after the address and There is also a space in the back file "slaves/abc.com.db"; };7: Then perform rndc reload for data reloading author "Follyman's note"


< Br>

Copyright © Windows knowledge All Rights Reserved