Wednesday, 5 March 2014

How to configure reverse DNS for IPv6 range?

It is known, that this topic is a problem for many users, but in fact, configuring reverse DNS zone for IPv6 range is very simple. It is very similar to IPv4 reverse DNS zone and it is nothing more difficult, than editing a zone for the regular domain. The first thing, you should do, is to delegate reverse DNS zone of your IPv6 range to your name servers. As you know, you should have at least two name servers. Delegation is usually made by your provider. Than, you should add one line in /etc/bind/named.conf and create a file with your zone defined inside. This is everything. So let's do it.


Location of this file depends on the specific system, sometimes it may be /etc/named.conf or another file in /etc/bind directory. Anyway, it is a place, when links to all of the zones are placed. Let's imagine, that you have following IPv6 range:


Now, you should convert this to the reverse DNS form:

As you can see, it is nothing more than your IP range written reversed with every digit separated by dot and added at the end.

Than, you should define your new zone:

zone "" {type master; file "";};


The last step is to configure this zone. Here you have an example:

$TTL 86400
@ IN SOA (1395848924 21605 7200 1209600 86400)
@ NS


I think, it is obvious now, that it is nothing difficult. At the end, restart your bind:

killall -HUP named

Remember to update serial after editing DNS zone in the future.