Created attachment 155489 [details] patch file for dns/bind99 or dns/bind910 The purpose of this patch is to fix two very minor annoyances. 1. If named.conf is moved in /etc/rc.conf with a line such as named_conf=/etc/namedb/named.conf, then rndc-confgen creates a key in the /etc/namedb but /usr/local/etc/rc.d/named restart or reload won't use that key file. The reload will fail, but the restart falls back to using kill. 2. The second problem is that if a rndc.conf file is used and put in /etc/namedb, rndc won't find it. It is necessary to use an rndc.conf file if running named in a jail, where there is no 127.0.0.1 address or if running IPv6 only and in other circumstances, such as if it is desirable to reload remotely (although an ssh command also solves this). The change is simply to load up a rndc_flags variable and use it in the two places where rndc is used. btw- there seems to be a non-ascii character in the comment on line 188 after the string "but ${named_program}". Patch is attached.
Note that if you have /usr/local/etc/rc.d/named, you're running 10.1+ and you do not have a /etc/namedb, your BIND config file should be in /usr/local/etc/namedb.
A commit references this bug: Author: mat Date: Thu Apr 30 14:43:06 UTC 2015 New revision: 385049 URL: https://svnweb.freebsd.org/changeset/ports/385049 Log: When named.conf was placed somewhere else than %%ETCDIR%%, rndc would stop working. PR: 199384 Submitted by: Curtis Villamizar Sponsored by: Absolight Changes: head/dns/bind910/Makefile head/dns/bind910/files/named.in head/dns/bind99/Makefile head/dns/bind99/files/named.in