drill(1)
drill is a DNS lookup tool that performs DNS queries and displays results in a human-readable format, similar to dig but with a simpler output.
Synopsis
drill [OPTIONS] name [type] [class] [@server]Description
drill is a DNS client utility used to query DNS servers and retrieve DNS records. It provides detailed information about DNS lookups including query results, response times, and DNSSEC validation status. drill is part of the ldns library and is useful for troubleshooting DNS issues and understanding how domain name resolution works.
The command can query various DNS record types (A, AAAA, MX, NS, SOA, TXT, etc.) against specific nameservers or the system's default resolver. It can also validate DNSSEC signatures and show the full DNS query/response chain.
Common options
| Flag | What it does |
|---|---|
-x | Perform reverse DNS lookup (IP to hostname) |
-T | Use TCP instead of UDP for the query |
-D | Enable DNSSEC validation and show DNSSEC status |
-t | Specify DNS record type (A, AAAA, MX, NS, SOA, TXT, etc.) |
-c | Specify DNS class (IN for Internet, CH for Chaos, etc.) |
-s | Chase DNSSEC signature chain and display full validation path |
-p PORT | Use non-standard port number for DNS query |
-4 | Use IPv4 only for queries |
-6 | Use IPv6 only for queries |
-V | Show version information |
Examples
Query A record for example.com using default nameserver
drill example.comQuery MX (mail exchange) records for example.com
drill example.com MXPerform reverse DNS lookup on IP address 8.8.8.8
drill -x 8.8.8.8Query example.com using Google's public DNS server 8.8.8.8
drill example.com @8.8.8.8Query example.com and validate DNSSEC signatures
drill -D example.comQuery IPv6 (AAAA) record and show DNSSEC chain of trust
drill -s example.com AAAAQuery nameserver (NS) records using TCP instead of UDP
drill -T example.com NSQuery TXT records (often used for SPF, DKIM, verification)
drill example.com TXT