dns

dns inspects DNS records by type, checks whether selected records exist and performs reverse PTR lookups for IP addresses.

NetworkVersion 1.2.4Stable
lil-terminal

Overview

Use dns for DNS records and reverse lookups. Common operations stay short; specialized forms add detail only when needed, so repeated work remains easy to understand, repeat and place in lil-terminal scripts.

Read DNS by record type

A and AAAA map names to addresses, MX describes mail routing, TXT often carries verification or policy data, NS shows delegation, CAA limits certificate authorities and PTR maps an address back to a name. An empty answer for one type does not mean the domain itself is missing.

Syntax

lil-terminal
dns <host|ip|me> [types] [-c]

Reference

dns me

use the current host

dns example.com

show common records

dns example.com -mx

show only MX records

dns example.com -txt

show only TXT records

dns example.com <types>

show selected record types

dns 1.2.3.4

show a reverse PTR lookup

dns example.com -c

check which selected record types exist

-a | -aaaa

select A or AAAA address records

-cname

select CNAME alias records

-mx

select MX mail-exchanger records

-ns

select NS name-server records

-txt

select TXT text records

-soa

select the SOA authority record

-srv

select SRV service records

-caa

select CAA certificate-authority records

-ptr

select PTR reverse records

-all

select all supported types; the default common set omits SRV and PTR

Notes

The default set is A, AAAA, CNAME, MX, NS, TXT, SOA and CAA. -all is intentionally not redundant: it additionally requests SRV and PTR, which are often absent and can make a broad query noisier. Multi-part record values use a visible “ · ” separator so priority, target and TTL remain easy to scan.

Interactive sandbox preview

Run the prepared examples directly on the page. Their results are prebuilt and shown in the browser; no terminal command is executed on the server.

Compare common DNS records with MX

Install and manage

Install the current compatible version. Choose Base for the complete feature set or Minimum for the reduced package; use upgrade to update a module that is already installed.

Base and Minimum are two packages of the same current module release, not separate command versions.

Base package

Install the complete package with local command reference and every published mode.

install dns
Minimum package

Install the reduced package. Local reference is omitted; help <cmd> -i opens the current server reference.

install dns -m
Exact public version

Install exactly this published version.

install dns -v 1.2.4
Check or update

Ask upgrade to check compatibility and replace the installed block only when needed.

upgrade dns
Remove module

Remove the extension block while leaving the core and unrelated modules intact.

install dns -u

Examples

Examples are copyable command lines, not actions executed by this website. Review paths, permissions and destructive flags before running them on a real project.

Compare common DNS records with MX
dns example.com | dns example.com -mx
example.com
A     93.184.216.34  TTL 3600
AAAA  2606:2800:220:1:248:1893:25c8:1946  TTL 3600

MX  10 mail.example.com  TTL 3600
Show only MX records
dns example.com -mx
MX  10 mail.example.com  TTL 3600
Show only TXT records
dns example.com -txt
TXT  v=spf1 -all  TTL 3600
Show selected record types
dns example.com -a -aaaa
A     93.184.216.34
AAAA  2606:2800:220:1:248:1893:25c8:1946
Select SRV service records
dns _sip._tcp.example.com -srv
SRV  10 5 5060 sip.example.com  TTL 3600
Select all supported types; the default common set omits SRV and PTR
dns example.com -all
A      93.184.216.34
AAAA   2606:2800:220:1:248:1893:25c8:1946
MX     10 mail.example.com
TXT    v=spf1 -all
CAA    0 issue letsencrypt.org
Check which selected record types exist
dns example.com -srv -c
Status  no
Types   SRV
Show a reverse PTR lookup
dns 8.8.8.8
PTR  dns.google
Handle a name that does not resolve
dns does-not-exist.invalid
DNS records not found

Related documentation

Current public release

v1.2.42026-08-10

Language synchronization

Finalizes Local and Server Help synchronization and localization safety for dns.