Query DNS records, troubleshoot resolution, and learn output interpretation. 06.03.2026 | reading time: 2 min When name resolution fails, use `dig` to ask DNS servers directly and read the raw response; it is the command-line magnifying glass for DNS troubleshooting and discovery. Quick demonstration Run a fast A-record check and see the answer: ```$ dig example.com A +short => 93.184.216.34```; omit `+short` to view the header, question, answer, authority and additional sections for full context. Targeting a specific server Query a particular resolver or request different record types by using the `@server` syntax and type name, for example `dig @8.8.8.8 example.com MX` to inspect mail exchange records from Google's DNS. Deep inspection tips Use `+short` for scripting, `+trace` to follow delegation from the root, `+noall +answer` to show only answers, `+tcp` to force TCP, and `+dnssec` to see DNSSEC RRsets; remember that dig defaults to UDP port 53 unless TCP is requested or the response is large. Real use cases Verify DNS propagation after zone changes, confirm mail server addresses, debug split-horizon and caching issues, validate DNSSEC signatures, and embed `dig +short` calls in scripts to make automated checks. Tools that complement dig Pair `dig` with packet inspection like `tcpdump` when queries behave unexpectedly, compare results with `host` and `nslookup` to cross-check resolver behavior, or use `drill` from ldns for alternative resolver libraries and extra options. Wrap-up and next steps Practice by querying different record types and resolvers, read the output sections until they become familiar, and then deepen Linux skills through formal study; consider preparing for CompTIA Linux+ or LPIC-1 with intensive exam training at bitsandbytes.academy. Join Bits & Bytes Academy First class LINUX exam preparation. network utilities troubleshooting