Data Link Layer && DNS
CoreDNS main purpose is to build a fast and flexible DNS server that allows users to access and use DNS data in different ways.
- DNS servers store a database of resource records of IP address–to–DNS name mappings, which they share with clients and other DNS servers --- DNS服务器存储IP地址到DNS名称映射的资源记录数据库,它们与客户端和其他DNS服务器共享该数据库。
- DNS lookup command: dig/nslookup
- DNS zone transfers : DNS区域转移 /Kubernetes DNS Service IP (Service Cluster IP)
- On Linux (and probably most Unix), there is no OS-level DNS caching unless
nscd
is installed and running. - Data link layer tools:
- ebtables - Ethernet bridge frame table administration
- ethtool is used to query and control network device driver and hardware settings, particularly for wired Ethernet devices.
- 域名区域(domain name zones)/stubDomain: 存根域
DNS Types: 10 Top DNS Record Types : DNS servers create a DNS record to provide important information about a domain or hostname, particularly its current IP address. The most common DNS record types are:
Address Mapping record (A Record)—also known as a DNS host record, stores a hostname and its corresponding IPv4 address.
IP Version 6 Address record (AAAA Record)—stores a hostname and its corresponding IPv6 address.
Canonical Name record (CNAME Record 规范名称记录)—can be used to alias a hostname to another hostname. When a DNS client requests a record that contains a CNAME, which points to another hostname, the DNS resolution process is repeated with the new hostname.
Mail exchanger record (MX Record)—specifies an SMTP email server for the domain, used to route outgoing emails to an email server.
Name Server records (NS Record)—specifies that a DNS Zone, such as “example.com” is delegated to a specific Authoritative Name Server, and provides the address of the name server.
Reverse-lookup Pointer records (PTR Record)—allows a DNS resolver to provide an IP address and receive a hostname (reverse DNS lookup).
Certificate record (CERT Record)—stores encryption certificates—PKIX, SPKI, PGP, and so on.
Service Location (SRV Record)—a service location record, like MX but for other communication protocols.
Text Record (TXT Record)—typically carries machine-readable data such as opportunistic encryption, sender policy framework, DKIM, DMARC, etc.
Start of Authority (SOA Record)—this record appears at the beginning of a DNS zone file, and indicates the Authoritative Name Server for the current DNS zone, contact details for the domain administrator, domain serial number, and information on how frequently DNS information for this zone should be refreshed.
Kubernetes 提供了 DNS 服务来作为查询,让 Pod 能夠以 Service 名称作为域名来查询 IP 位址,因此使用者就再不需要关心实际 Pod IP,而 DNS 也会根据 Pod 变化更新资源记录(Record resources)。
vv
Blogs
- DNS Forwarding and Conditional Forwarding
- Traffic Management with Istio (4): DNS Resolution with CoreDNS
- Kubernetes DNS for Services and Pods
- CoreDNS
Domain Name System (DNS) Parameters
- Kubernetes DNS-Based Service Discovery
**********************************************