2

I have a zone (1.168.192.IN-ADDR.ARPA) $GENERATEing PTR records from 1-254.

However, I also have some custom PTR records, within that range, that are declared aside from the generate directive.

Problem is, when I query the server, I get two (different) answers, one for the record from the generate and one for the record that I provide.

What is the standard approach to solving this problem, so that the generated record is only returned if another record does not exist?

Don't fancy having to split the generate up into sections.

az_
  • 133
  • 1
  • 8

1 Answers1

3

$GENERATE is designed to cover the entire range in records - it's not supposed to 'leave alone' RRs that already have an entry on them, since it's perfectly valid to have multiple PTR records for a single IP address. So, the behavior you're looking for would indeed require splitting up the $GENERATEs.

Honestly, it's a lot clearer to read and easy to make changes in the future if you just define each record individually.

Shane Madden
  • 112,982
  • 12
  • 174
  • 248