There was a problem loading the comments.

How to check DNS records (A, CNAME, MX, TXT) with dig and nslookup

Support Portal  »  Knowledgebase  »  Viewing Article

  Print

When you change DNS, it can take time for caches to update. The fastest way to confirm the current state is to query DNS directly.

This guide shows simple commands to check A, CNAME, MX, and TXT records.

1) Check which nameservers are authoritative (NS)

macOS / Linux (dig)

dig NS example.com +short

Windows (nslookup)

nslookup -type=ns example.com

If the NS are not ns1.garmtech.com/ns2.garmtech.com/ns3.garmtech.com, you must edit DNS at the provider that is listed.

2) Check A and CNAME records

dig

dig A example.com +short
dig CNAME www.example.com +short

nslookup

nslookup example.com
nslookup -type=cname www.example.com

3) Check MX (mail routing)

dig

dig MX example.com +short

nslookup

nslookup -type=mx example.com

4) Check TXT (verification, SPF, DKIM, DMARC)

dig

dig TXT example.com +short
dig TXT _dmarc.example.com +short

nslookup

nslookup -type=txt example.com
nslookup -type=txt _dmarc.example.com

5) Query a specific nameserver (authoritative check)

If you want to bypass random resolvers and query a specific nameserver directly:

dig @ns1.garmtech.com A example.com
dig @ns1.garmtech.com TXT example.com

If you use external DNS, replace the nameserver with the one returned by the NS query.

6) Understand different results (cache vs authoritative)

  • Authoritative nameserver shows the “source of truth”.
  • Public resolvers (your ISP, Google DNS, Cloudflare DNS) can cache older values until TTL expires.
  • If results differ, wait for TTL or flush local DNS cache on your device.

Share via
Did you find this article useful?  

Related Articles


Comments

Add Comment

Replying to  

Tags

© GARMTECH