Repaso
EspaƱol
Cloud & DevOpsIntermediateOPS-64

What is the difference between DNS record types A, CNAME and MX?

Options

  1. A maps a name to an IPv4 address; CNAME is an alias; MX is for email (Correct option)
  2. A is used for email delivery and MX is used for IPv4 addresses
  3. CNAME maps a name to an IP, while A maps a name to another name
  4. They are all identical and any of them can replace the others

Answer

A maps a name to an IPv4 address; CNAME maps a name to another name (alias); MX tells where to deliver email

Why

DNS translates names into data:

  • A (and AAAA for IPv6): api.example.com to 203.0.113.10.
  • CNAME: www.example.com is an alias of example.com (or of a load balancer's DNS name).
  • MX: mail servers for the domain.
  • TXT: free text such as domain verification and SPF.

A CNAME cannot sit at the zone apex (example.com itself); clouds provide alias records for that. Services: Route 53 (AWS), Azure DNS.

Remember

A = name to IP. CNAME = name to name. MX = mail.

Key terms

Practice this question in Repaso