Dns:domian Name Service
Name resolution, name resolving (behind the query process, database)
Fqdn<-->ip
172.16.0.1 www.magedu.com
Nsswitch: Provides a platform for name resolution mechanisms and does not provide name resolution functionality by itself
/etc/nsswitch.conf
A libnss_files.so that is really responsible for name resolution
Libnss_dns.so
/etc/hosts
IPAddr FQDN Aliases (alias)
172.16.0.1 Www.magedu.con www
Each superior can only directly manage his subordinate, that is, my client's dependency, not my client.
Subordinates can leapfrog petitions
Everybody doesn't know that its superiors only know the root
The top-level domain is not the root domain
TLD: top-level domain
Organizational domain:. com. org. net. cc
Country domain:. CN. JP. ir. iq
Reverse Domain: IP-->FQDN
Forward and reverse are not the same database
Forward: Ip-->fqdn
Reverse: Fqdn-->ip
The name is bottom-up authorization is top-down
The root is not recursive to anyone but only in an iterative way
Recursive: A->b->c only one request is made
A<-b<-c
Iteration: A->b makes multiple requests
A<-b
A->c
A<-c
Authority refers to the answer returned by the direct superior of the target host
Non-authoritative refers to the answer returned by the non-direct ancestor of the target host
The cache time is carried when returned by the direct ancestor of the target host
One server can be resolved for multiple domains, through multiple databases on the server
Analytical:
Forward: Fqdn-->ip
Reverse: Ip-->fqdn
Two-stage: recursive, iterative
DNS: Distributed Database
The superior only knows its direct subordinate
Subordinates only know where the root is.
DNS Server:
Receiving query requests from local clients (recursive)
Requests from the extranet (Request authoritative answers)
Affirmative answer: Carry TTL value
Negative answer: Carry the TTL value directly to tell no target to query
The nameserver address in/etc/reslov.conf must be allowed to be recursive to this host nameserver
DNS Server type:
Primary DNS server: Data modification
Secondary DNS server: Request data synchronization
Regular vs. master request updates
If the primary server is hung, the secondary server will not replace it and discard it directly.
Serial number
Refresh
Retry
Expire Expiration Time
Negative Answer TTL
Cache DNS Server: Cache only, no authoritative answer
Forwarders: Not cached, forward only
A resource record RR (Resorce record) is placed inside the zone data
Format of RR:
TTL can be omitted when the complete definition is
Name TTL in RRT VALUE
Www.baidu.com. In A 1.1.1.1
1.1.1.1 in PTR www.baidu.com.
Resource record type: (RRT)
SOA (Start of authority) indicates when the master and slave servers in the zone are synchronized, enabling the authorization server
Zone_name TTL in SOA FQDN Admin_mailbox (
Serial number
Refresh
Retry
Expire
Negative TTL)
Time unit: m,h,d,w, default is S
Admin_mailbox:[email protected]>admin.magedu.com. To represent the domain name in DNS instead of @
NS (Name Server): Zone Name-->fqdn the person in charge of the specified zone name
Magedu.com. In NS ns.mageedu.com. Specify ZoneName (magedu.com.) The mayor is ns.mageedu.com. (host name)
Na.magedu.com. In A 1.1.1.2 These two will appear in pairs.
MX (Mail Exchanger): ZONE name-->fqdn (mail server name)
Priority: 0-99 the smaller the number the higher the level
Zone_name TTL in MX PRI VALUE
Magedu.com. In MX ten mail.magedu.com.
Mail.magedu.com. In A 1.1.1.3
A (address): Fqdn-->ipv4
Aaaa:fqdn-->ipv6
PTR (pointer): IP-->FQDN
CNAME (Canonical Name): Fqdn-->fqdn
Www2.magedu.com in CNAME www.magedu.com
(alias) (official name)
Txt
CHAOS
SRV
DNS basic concepts and resource record types for Linux