Debian/Ubuntu Tips and Tricks


Debian/Ubuntu Tips and Tricks

How-To: Setting up a DNS zone with Bind9 — page 2

Posted by chantra on August 5th, 2006

This entry is part 2 of 2 in the series How-To: Setting up a DNS zone with Bind9

Setting up Reverse Name Resolution:

In order to be able to get the name of the machine located at IP 192.168.1.X, we need to set up a reverse name zone which is going to be call, in this example,

edit /etc/bind/named.conf.local and add:

 zone "" {
        type master;
        notify no;
        file "reverse/192.168.1";

This time, wa are going to write the information for reverse dns in a specific directory ("reverse"). Create that directory and edit the zone file:

mkdir /var/cache/bind/reverse
vi  /var/cache/bind/reverse/192.168.1

and copy the following lines: 

 $TTL 3D
@       IN      SOA (
                        200608051 ; Serial, todays date + todays serial
                        8H      ; Refresh
                        2H      ; Retry
                        4W      ; Expire
                        1D)     ; Minimum TTL

1               PTR
2               PTR
3               PTR
5               PTR

now, doing a nslookup on will return

Series Navigation<< How-To: Setting up a DNS zone with Bind9

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>