Date: Fri, 22 Nov 2013 03:14:38 GMT From: Pawel Biernacki <pawel.biernacki@gmail.com> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/184159: dns/bind* rc.d script variable override Message-ID: <201311220314.rAM3EcCD082191@oldred.freebsd.org> Resent-Message-ID: <201311220320.rAM3K1FS061683@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>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@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:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201311220314.rAM3EcCD082191>