ports/142793: dns/unbound: no default for unbound_enable and PID file in problematic location.

Keith Gaughan k at stereochro.me
Wed Jan 13 18:50:02 UTC 2010


>Number:         142793
>Category:       ports
>Synopsis:       dns/unbound: no default for unbound_enable and PID file in problematic location.
>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:   Wed Jan 13 18:50:02 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Keith Gaughan
>Release:        8.0
>Organization:
>Environment:
FreeBSD talisra 8.0-RELEASE FreeBSD 8.0-RELEASE #0: Sat Nov 21 15:48:17 UTC 2009     root at almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
If unbound is installed, but unbound_enabled is not defined in /etc/rc.conf, the system will complain about this. Also, it's putting it's PID file in %%PREFIX%%/etc/unbound/unbound.pid, which is problematic if you want %%PREFIX%% to be read-only or if it's shared as an NFS mount amongst a number of machines.

This patch modifies unbound's rc file to provide a default for unbound_enabled and modifies the location of its PID file to /var/run/unbound.pid.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

--- unbound.in	2008-05-07 12:33:37.000000000 +0100
+++ unbound.in.patched	2010-01-10 18:13:31.000000000 +0000
@@ -2,7 +2,7 @@
 #
 # unbound freebsd startup rc.d script, modified from the named script.
 # uses the default unbound installation path and pidfile location.
-# copy this to /etc/rc.d/unbound
+# copy this to %%PREFIX%%/etc/rc.d/unbound
 # and put unbound_enable="YES" into rc.conf
 #
 
@@ -16,8 +16,10 @@
 rcvar=`set_rcvar`
 
 command="%%PREFIX%%/sbin/unbound"
-pidfile="%%PREFIX%%/etc/unbound/unbound.pid"
+pidfile="/var/run/${name}.pid"
 extra_commands="reload"
 
 load_rc_config $name
+: ${unbound_enable:-"NO"}
+
 run_rc_command "$1"


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list