<div dir="ltr"><div>Hi There,</div><div>I have been exploring a migration from BIND 9 to PowerDNS with plans to use the pgsql backend. I have been reading over the docs and thinking specifically about how I would be able to migrate our extensive use of $GENERATE in our network.</div><div><br></div><div>It seems that based on the way createForward() and createReverse() function it would make the most sense to group dynamically generated DNS records under subdomains rather then keeping them in one very large zone and the replacement of <br></div><div><br></div><div>$GENERATE 0-255 $ PTR 1-2-3-$.<a href="http://domain.com" target="_blank">domain.com</a>.</div><div><br></div><div>with</div><div><br></div><div>*.3.2.1 IN LUA PTR "createReverse('%5.domain.com.')"<br></div><div><br></div><div>is pretty straightforward. But what about these:</div><div><br></div><div>$GENERATE 10-20 $ PTR 1-2-3-$.<a href="http://domain.com" target="_blank">domain.com</a>.</div><div>21 IN PTR <a href="http://something.domain.com" target="_blank">something.domain.com</a></div><div>22 IN PTR <a href="http://somethingelse.domain.com" target="_blank">somethingelse.domain.com</a></div><div>$GENERATE 23-255 $ PTR 1-2-3-$.<a href="http://domain.com">domain.com</a>.</div><div><br></div><div>How does one do a range of addresses with createReverse() rather then *.3.2.1.in-addr.arpa? or *.2.1.in-addr.arpa? Is there such a thing as:</div><div><br></div><div>10-20  IN LUA PTR "createReverse('%5.domain.com.')"</div><div>23-255  IN LUA PTR "createReverse('%5.domain.com.')"</div><div><br></div><div>I did read up on the exceptions list and in this example utilizing something like that might be suitable, but there are many examples where there would be "hundreds" of exceptions within a /24 and I don't think the exceptions list would scale well in that regard. So I am hoping for alternate options but I don't see a way with the variables LUA has access to that would allow me to write a snippet of LUA code to check if a given PTR record already exists in the zone and just return a generated one if not, or even to check if the last octet for example was within a certain range and if so generate the response with createReverse?</div><div><br></div><div>Thanks<br></div></div>