Reference · 4 min read

The DNS records every network engineer should know

DNS is the address book of the internet. Every time a client needs to reach a server, a DNS query translates a human-readable hostname into an IP address. But DNS does far more than simple name resolution. Network engineers need to understand the core record types that make modern networks function: A, AAAA, MX, CNAME, NS, SOA, TXT, and SRV records. Each serves a specific purpose, and misconfiguration of any one can break email delivery, service discovery, or security validation.

A and AAAA Records: The Foundation

The A record maps a hostname to an IPv4 address. It is the most basic and widely used DNS record type. When you query example.com, the A record tells your resolver which IPv4 address to connect to. The AAAA record does the same job for IPv6 addresses. Both are essential in modern deployments where dual-stack (IPv4 and IPv6) support is standard. A single hostname can have multiple A and AAAA records, enabling round-robin load balancing or failover scenarios.

example.com.  300  IN  A     192.0.2.1
example.com.  300  IN  AAAA  2001:db8::1

MX, CNAME, and TXT Records: Email and Aliases

The MX (Mail Exchange) record specifies which mail server handles email for a domain. It includes a priority value: lower numbers are tried first. Multiple MX records allow failover between mail servers. The CNAME (Canonical Name) record creates an alias pointing one hostname to another. Use CNAME records to simplify administration when multiple names should resolve to the same target, but remember that CNAME records cannot coexist with other record types at the same apex. The TXT record holds arbitrary text data, most commonly used for SPF (Sender Policy Framework), DKIM (DomainKeys Identified Mail), and DMARC (Domain-based Message Authentication, Reporting and Conformance) policies that protect against email spoofing.

example.com.      300  IN  MX   10  mail1.example.com.
example.com.      300  IN  MX   20  mail2.example.com.
www.example.com.  300  IN  CNAME example.com.
example.com.      300  IN  TXT  "v=spf1 mx -all"

NS and SOA Records: Authority and Control

The NS (Name Server) record identifies which authoritative DNS servers are responsible for a zone. These records are critical for zone delegation and must be configured at both the parent zone and the child zone. The SOA (Start of Authority) record contains metadata about the zone: the primary nameserver, responsible email address, serial number, and timing values (refresh, retry, expire, and minimum TTL). The serial number increments each time the zone is updated, signaling secondary nameservers to pull a fresh copy. SOA records also define how long negative responses (NXDOMAIN) are cached.

example.com.  300  IN  NS  ns1.example.com.
example.com.  300  IN  NS  ns2.example.com.
example.com.  3600 IN  SOA ns1.example.com. admin.example.com. 2024010101 3600 1800 604800 86400

SRV Records: Service Discovery

The SRV (Service) record enables service discovery by mapping a service name to a hostname and port. SRV records are used by Active Directory, SIP (Session Initiation Protocol), XMPP (Extensible Messaging and Presence Protocol), and other protocols that need to locate services dynamically. An SRV record includes priority, weight, port, and target hostname. Priority determines preference order; weight provides load balancing among equal-priority targets. Understanding SRV records is essential for troubleshooting enterprise directory and VoIP deployments.

_ldap._tcp.example.com.  300  IN  SRV  10  60  389  ldap1.example.com.
_ldap._tcp.example.com.  300  IN  SRV  10  40  389  ldap2.example.com.

Mastering these eight record types gives you the foundation to design, troubleshoot, and secure DNS infrastructure. Whether you are preparing for CCNA certification or managing production networks, knowing when and how to use each record type is non-negotiable. Use a DNS record reference tool to practice lookups and understand real-world configurations.

DNS Record Types reference
Free interactive reference for A, AAAA, MX, CNAME, NS, SOA, TXT, and SRV records
Open →
Practise this on today’s Daily Ops Drill — a free network task every day.
Open the app →
Free tools for this
More from the blog
Route summarization: shrinking your routing table the right wayRead →VLSM subnetting without the headache: a repeatable methodRead →