ports/184159: dns/bind* rc.d script variable override
Pawel Biernacki
pawel.biernacki at gmail.com
Fri Nov 22 03:20:02 UTC 2013
>Number: 184159
>Category: ports
>Synopsis: dns/bind* rc.d script variable override
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Fri Nov 22 03:20:01 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator: Pawel Biernacki
>Release: 11-CURRENT
>Organization:
>Environment:
FreeBSD devil.local 11.0-CURRENT FreeBSD 11.0-CURRENT #5 r258395: Wed Nov 20 20:22:30 CET 2013 root at devil.local:/usr/obj/usr/src/sys/DEVIL amd64
>Description:
After removing bind from base the rc.d script was moved to ports. The problem is that it overrides variables from rc.conf.
>How-To-Repeat:
I installed bind from ports, add enable_named="YES" to /etc/rc.conf and did a reboot. During my tests with rc_debug="YES" I discovered:
/etc/rc: DEBUG: checkyesno: named_enable is set to NO.
and in effect named was not started.
Attached patch fixes the problem.
>Fix:
--- named.orig 2013-11-22 02:34:38.587664008 +0000
+++ named 2013-11-22 02:46:13.550134631 +0000
@@ -19,15 +19,16 @@
reload_cmd="named_reload"
stop_cmd="named_stop"
-named_enable="NO" # Run named, the DNS server (or NO).
-named_program="/usr/local/sbin/named" # Path to named, if you want a different one.
-named_conf="/usr/local/etc/namedb/named.conf" # Path to the configuration file
-#named_flags="" # Use this for flags OTHER than -u and -c
-named_uid="bind" # User to run named as
-named_wait="NO" # Wait for working name service before exiting
-named_wait_host="localhost" # Hostname to check if named_wait is enabled
-named_auto_forward="NO" # Set up forwarders from /etc/resolv.conf
-named_auto_forward_only="NO" # Do "forward only" instead of "forward first"
+# defaults
+named_enable=${named_enable:-"NO"} # Run named, the DNS server (or NO).
+named_program=${named_program:-"/usr/local/sbin/named"} # Path to named, if you want a different one.
+named_conf=${named_conf:-"/usr/local/etc/namedb/named.conf"} # Path to the configuration file
+named_flags=${named_flags:-""} # Use this for flags OTHER than -u and -c
+named_uid=${named_uid:-"bind"} # User to run named as
+named_wait=${named_wait:-"NO"} # Wait for working name service before exiting
+named_wait_host=${named_wait_host:-"localhost"} # Hostname to check if named_wait is enabled
+named_auto_forward=${named_auto_forward:-"NO"} # Set up forwarders from /etc/resolv.conf
+named_auto_forward_only=${named_auto_forward_only:-"NO"} # Do "forward only" instead of "forward first"
named_poststart() {
if checkyesno named_wait; then
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list