DNS - Record

1 - About

A DNS record is a row in a DNS database.

3 - Syntax

A record is a text line.

<name> <ttl> <class> <type> <rdata>

  • name is the name or IP address for a ptr record
  • ttl is the the time to live in the cache
  • class is the network class being used. No more used only for compatiblity
    • IN for Internet (The default and only)
    • HS for Hesiod (deprecated)
    • CH for Chaosnet (deprecated)
  • type is the type of record
  • rdata is output of the lookup

3.1 - Example

Example of a A record.

api                                 IN A


If the apex domain is example.com, this entry will point the qualified domain name api.example.com to the ip

4 - Type

4.1 - Pointer

Pointer record match a name to a destination

4.2 - Extended

  • CAA
  • SRV Record (Service AutoDiscovery)
  • LOC
  • TLAS

4.3 - Mail

There is also a TXT record for each of the following mail authentication mechanism.

4.4 - Others

  • ANY,
  • SOA,

5 - Query

5.1 - Nslookup

With nslookup if we want to see the TXT record

nslookup -type=TXT bytle.net

Server:  amplifi.lan

Non-authoritative answer:
bytle.net       text =

        "v=spf1 a include:vps748761.ovh.net -all"

5.2 - Dig

Network - dig (DNS tool)


6 - Time To Live (TTL)

The Time To Live (TTL) of a DNS record is generally of 5 minutes.

If clients cache the results of host name lookups in order to achieve a performance improvement, they MUST observe the TTL information reported by DNS. Ref - DNS Spoofing

7 - Documentation

Data Science
Data Analysis
Data Science
Linear Algebra Mathematics

Powered by ComboStrap