Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have set up my bind server but am unable to perform reverse look up the nslookup.

The config file looks like this.

acl "internal" {192.168.5.0/24;};

view "internal" {

    match-clients   {"internal";};
    recursion       yes;

    zone "home" {
            type    master;
            file    "master/home.db";
    };

    zone "sludge.home" {
            type    master;
            file    "master/sludge.home.db";
    };

    zone "192.168.5.in-addr.arpa" {
            type    master;
            file    "master/192.168.5.db";
    };

    zone "255.in-addr.arpa" {
            type    master;
            file    "master/255.db";
    };

    zone "0.in-addr.arpa" {
            type    master;
            file    "master/0.db";
    };

    zone "." {
            type    hint;
            file    "master/root.hint";
    };

    zone "localhost" {
            type    master;
            file    "master/localhost.db";
    };

    zone "0.0.127.in-addr.arpa" {
            type master;
            file "master/127.0.0.db";
    };
};

The 192.168.5.db looks like this.

$TTL    4w

@ IN SOA dns.home. home. (
        2011030403 ; serial
        3h         ; refresh after 1 week
        1h         ; retry after 1 week
        1w         ; expire after 1 week
        1h )       ; negative caching TTL of 1 hour

                        IN NS   dns.home.

12                      IN PTR  dns.home.
13                      IN PTR  firewall.home.
15                      IN PTR  sludge.home.

Thanks for the help.

share|improve this question

1 Answer 1

up vote 4 down vote accepted

in-addr.arpa addresses have the octets in reverse order, so the zone should be

zone "5.168.192.in-addr.arpa" {
        type    master;
        file    "master/192.168.5.db";
};

(the filename doesn't matter, but you might want to switch it around there too to match)

Requests should be of the form 12.5.168.192.in-addr.arpa. dig -x 192.168.5.12 will automatically perform this transformation.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.