What is a DNS service? In short, the DNS service can implement domain name resolution in the Internet (converting a domain name into an IP address that the network can recognize).
Noun explanation ①: Forward parsing: Domain name resolution IP address, reverse resolution: IP Address resolution domain name.
Positive/Reverse Zone parsing documents for DNS services most of them are hand-punched, but we don't have to be afraid, after all, we can still find some tricks here.
Note: Firewalls and SELinux will have DNS The server has a certain impact, in order to avoid unnecessary trouble, in doing the experiment proposed to build DNS server, you should put the firewall and SELinux closed.
"Scenario Instance"
Configuring a regular DNS server
① set up a DNS server for the local area network computer to provide positive and negative interpretation services. DNS server manages domain name resolution for lilywhile.com domains.
The domain name of the ②DNS server is Dns.lilywhile.com,ip address is 192.168.5.25
③ must also provide clients with domain name resolution for hosts on the Internet. Required to be able to separate the following domain names:
Lily While introduction home: Www.lilywhile.com (192.168.5.1)
Pastoral Sea: umi.lilywhile.com (192.168.5.3)
Star Rin: rin.lilywhile.com (192.168.5.5)
Tojo h: nozomi.lilywhile.com (192.168.5.9)
Mail server: mail.lilywhile.com (192.168.5.25)
④ build a secondary DNS server with the IP address of the secondary DNS 192.168.5.2
"Feature Implementation"
Tips: The name of the reverse parsing area is different, see the operation flow for details
Noun explanation ②:a record: host record;
NS resource record: Name server, which represents the authorization server in the zone;
MX record: Mail exchange record.
Noun explanation ③:ptr: Reverse parsing records
The primary DNS server has been set up, and next we are going to build a secondary DNS server.
"Troubleshooting tips for DNS Services"
① Zone parsing File no matter the domain name, the following must be dot (. );
② Zone parsing file in the process of hand-beating, we should pay attention to the corresponding (positive/inverse analysis);
After the ③ zone parsing file is established, a grammar check is performed. (Only syntax errors can be checked using directives, and logic errors cannot be checked)
Related directive: named-checkconf/etc/named.conf
Named-checkzone (related domain name) (related zone resolution file)
"Extra configuration for named.conf"
Set forward: ①named.conf file header
Add the following statement: forward only
forwards {x.x.x.x; };
② related area (zone) settings
Modified to these two lines of content: type forward
forwards {x.x.x.x; };
Set cache: named.conf Add statement: DataSize XXXM (can be filled in KB, GB, MB and other capacity)
Implementation of the CentOS 6.5 network server function ①: Using bind to build a basic DNS server