Grow your Business Online​
Wesbytes Blue Logo

Wesbytes Knowledge Base

Search our articles or browse by category below

What is Reverse DNS or PTR Record ?

Last modified: July 2, 2022
You are here:
Estimated reading time: 2 min

What is reverse DNS?

As a DNS query, reverse DNS lookup is frequently used to find the domain name connected to a specific IP address. By querying the DNS system to return an IP address, this achieves the opposite—forward DNS lookup.

Every domain should, according to Internet Engineering Task Force (IETF) standards, be able to do a reverse DNS lookup. Reverse lookups are not a hard requirement, though, because they are not necessary for the Internet to operate normally. Reverse DNS lookups aren’t used by everyone, as a result.

How does it work?

DNS servers are contacted by reverse DNS lookups to find a PTR (pointer) record. If the server does not have a PTR record, it cannot resolve a reverse lookup. Segment-reversed IP addresses are kept in PTR records, and ‘.in-addr.arpa’ is added to them. For instance, if a domain’s IP address is 193.1.1.1, its information will be stored in the PTR record under 1.1.1.193.in-addr.arpa.

PTR entries are maintained in the ‘.ip6.arpa’ domain rather than the ‘.in-addr.arpa’ domain in IPv6 (the most recent version of the Internet Protocol).

What are reverse DNS lookups used for?

Email servers frequently perform reverse lookups to verify that an email message originated from a legitimate source before putting it onto their network. Messages from any server that doesn’t enable reverse lookups or from an illegitimate server will typically be rejected by many email servers. IP addresses from hacked computers are frequently used by spammers. As a result, there won’t be a PTR record. Additionally, they might make use of dynamically assigned IP addresses that point to server domains with incredibly generic names.

Software used for logging also uses reverse lookups. In their log data, they give users human-readable domains rather than a list of IP addresses.

How can you utilize it?

You should use internet reverse lookup tools like MxToolBox, which we advise. You can use the tool to determine the hostname associated with an IP address. Simply input the IP address in the field and click Reverse Lookup to start the search.

record

What is PTR Record?

For the Reverse DNS (Domain Name System) lookup, we employ PTR records. When utilising the IP address, it is possible to obtain the corresponding domain or hostname. There is an A record for each PTR record. Setting up reverse DNS for a mail server is a wise decision.

The hostname is directed to an IP address in the domain DNS zone.
It is possible to point an IP address to a hostname in the reverse zone.
In the reverse DNS zone, a PTR record is required. The IP address can be linked to a domain or hostname using the PTR record.

Why do you need it?

PTR records offer assurance that a hostname or domain is linked to an IP address. The majority of mail providers refuse or label as spam communications received by mail servers without appropriate reverse DNS setup, hence the PTR records are essential for outgoing mail servers (missing PTR or mismatch A record for the hostname).

How to create a PTR record?

We would need to first build a Reverse DNS zone before we could construct a PTR record. The size of the IP network affects the reverse DNS zone. We employ an IPv4 /24 network, for instance. 255 distinct IP addresses will be present in the /24 network. The accessible IP addresses in this network, for instance, range from 192.168.0.1 through 192.168.0.255 if the network is 192.168.0.0/24. The reverse zone is formatted as follows: 0.168.192.in-addr.arpa

Navigate to the Control Panel to create a reverse DNS zone. After that, select the Master Reverse DNS zone by clicking the Add new zone option. Next, enter the name of your IP network’s reverse zone.

We may now add PTR entries for each network IP to the reverse zone. Additionally, by selecting the “Create new record” button, we may add a new PTR record. Examples of the first two IP addresses include the following:

For 192.168.0.1
Type: PTR
Host: 1
Points to: hostname1.example.com

For 192.168.0.2:
Type: PTR
Host: 2
Points to: hostname2.example.com

Was this article helpful?
Dislike 0
Views: 10