PTR (Pointer) records, also known as reverse DNS records, are used in reverse-mapping zones to map IP addresses back to hostnames. This is essential for various network services and troubleshooting. In this guide, we’ll walk through the steps to create PTR records in DNS Manager on Windows Server 2022.
Table of Contents
Step-by-Step Guide to Creating PTR Records
1. Open DNS Manager
- Search for DNS: Use Windows Search to find the DNS app and open it.
- Via Server Manager: Alternatively, open Server Manager, click on the Tools tab, and select DNS.
2. Configure the Reverse Lookup Zone
- In DNS Manager, navigate to Reverse Lookup Zones.
- Ensure you have a reverse lookup zone that matches the IP subnet for the PTR record you want to create. For example, if your IP subnet is 192.168.121.0/24, the reverse lookup zone should be 121.168.192.in-addr-arpa.
3. Create a New PTR Record
- Right-click on the appropriate reverse lookup zone and select New Pointer (PTR).
- Enter the IP address for which you want to create the PTR record. This is the IP address you want to resolve to a hostname.
- Enter the Host name manually or click the Browse button to select a hostname from the forward lookup zones.
- For example, if you’re creating a PTR record for the IP address 192.168.121.10, you might select DC2022 from the forward lookup zone Jamiltech.local.
- After selecting or entering the hostname, click OK to create the PTR record.
- You should see the new PTR record listed under the reverse lookup zone.
Once configuring the DNS Manager, choose the zone name under Reverse Lookup Zones. Please ensure the zone name suits the IP subnet of the record that you need to add. For instance, the IP subnet is 192.168.121.0/24 Therefore, the right zone name will be 241.168.192.in-addr-arpa.
Right-click on the reverse lookup zone, and then choose New Pointer (PTR).
Enter a host IP address (DNS server IP address) and then type the hostname manually or select the browse button to select forward look zones.
Open DC2022
Forward lookup zone
Jamiltech.local
Select DC2022, and then click OK.
You can see the hostname; click OK.
4. Update DNS Server Interface Settings
- Right-click on the DNS server in DNS Manager and select Properties.
- Go to the Interfaces tab.
- Select Only the following IP addresses and ensure that the appropriate IP addresses are listed. This setting can help avoid DNS query delays.
Click OK to apply the changes.
Before running the nslookup command, we need to change the IP address in the interface settings. Under the DNS manager, right-click on the DNS server and then click on properties.
Click on the Interfaces tab, and then choose the box “only the following IP address”. In this lab, I have only one DNS server; if you have an additional DNS server, then you can choose more servers. It will avoid DNS query delays. Choose ok
How to Verify the PTR Record
How to test Active Directory and DNS with the nslookup command Test your DNS server and determine whether its configuration is OK or not using the nslookup command.
Search for it in Windows Search, and then open it.
1. Using nslookup Command
- Open Command Prompt from Windows Search.
- Type nslookup and press Enter.
Use the following commands to test the PTR record:
Copy code
nslookup
Then, within the nslookup prompt, type:
Copy code
set type=PTR
Followed by:
Copy code
[Your IP Address]
For example:
Copy code
set type=PTR
192.168.121.10
- You should receive a response showing the hostname associated with the IP address.
2. Using DNS Manager
- In DNS Manager, right-click on the DNS server name and select Launch nslookup.
- Verify the PTR record by performing a lookup similar to the steps above.
In the Command Prompt, type nslookup and then hit enter.
The final method is to open the server DNS Manager, right-click the DNS server name, and then click on Launch nslookup.
After choosing the Launch nslookup menu,. That means the DNS server is healthy.
In the nslookup command utility, type your DNS server IP address or name, and you will receive a reply from “forward and reverse lookup address” like this.
Conclusion
By following these steps, you can create and verify PTR records in DNS Manager on Windows Server 2022. PTR records are crucial for reverse DNS lookups, which are often used for troubleshooting and network management. If you encounter issues or need further details, refer to official Microsoft documentation or resources related to DNS management.
Refer to this article for more details on creating a PTR record.