Difference between revisions of "BIND: Reverse DNS"
		
		
		
		
		
		Jump to navigation
		Jump to search
		
				
		
		
	
Onnowpurbo (talk | contribs)  (Created page with " ==Client==   dig ptr 10.34.239.216.in-addr.arpa   ==Pranala Menarik==  * BIND")  | 
				Onnowpurbo (talk | contribs)   | 
				||
| Line 1: | Line 1: | ||
| + | For this example we are using the IP block 216.74.109/24  | ||
| + | |||
| + | In /etc/named.conf add:  | ||
| + | |||
| + |  zone “109.74.216.in-addr.arpa” {  | ||
| + |    type master;  | ||
| + |    file “/var/named/109.74.216.in-addr.arpa”  | ||
| + |  };  | ||
| + | |||
| + | Create the following file:  | ||
| + | |||
| + |  /var/named/109.74.216.in-addr.arpa  | ||
| + | |||
| + | Inside this file use the following example configuration:  | ||
| + | |||
| + |  $TTL 86400  | ||
| + |  @ IN SOA localhost. root.localhost. (  | ||
| + |    991079290 ; serial  | ||
| + |    28800 ; refresh  | ||
| + |    14400 ; retry  | ||
| + |    3600000 ; expire  | ||
| + |    86400 ; default_ttl  | ||
| + |    )  | ||
| + |  IN NS dns.trouble-free.net.  | ||
| + |  IN NS dns2.trouble-free.net.  | ||
| + |  81 IN PTR my.reverse.dns.domain.com.  | ||
| + | |||
| + | Save your changes, then restart named using /etc/rc.d/init.d/named restart  | ||
| + | |||
| + | A lookup of 216.74.109.81 would show my.reverse.dns.domain.com  | ||
| + | |||
| + | |||
| + | |||
==Client==  | ==Client==  | ||
Revision as of 19:17, 30 November 2018
For this example we are using the IP block 216.74.109/24
In /etc/named.conf add:
zone “109.74.216.in-addr.arpa” {
  type master;
  file “/var/named/109.74.216.in-addr.arpa”
};
Create the following file:
/var/named/109.74.216.in-addr.arpa
Inside this file use the following example configuration:
$TTL 86400 @ IN SOA localhost. root.localhost. ( 991079290 ; serial 28800 ; refresh 14400 ; retry 3600000 ; expire 86400 ; default_ttl ) IN NS dns.trouble-free.net. IN NS dns2.trouble-free.net. 81 IN PTR my.reverse.dns.domain.com.
Save your changes, then restart named using /etc/rc.d/init.d/named restart
A lookup of 216.74.109.81 would show my.reverse.dns.domain.com
Client
dig ptr 10.34.239.216.in-addr.arpa