From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Jan 13 18:50:02 2010 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B9FE61065676 for ; Wed, 13 Jan 2010 18:50:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 7DB508FC19 for ; Wed, 13 Jan 2010 18:50:02 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id o0DIo2gb017369 for ; Wed, 13 Jan 2010 18:50:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id o0DIo2UD017368; Wed, 13 Jan 2010 18:50:02 GMT (envelope-from gnats) Resent-Date: Wed, 13 Jan 2010 18:50:02 GMT Resent-Message-Id: <201001131850.o0DIo2UD017368@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Keith Gaughan Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1BCC11065670 for ; Wed, 13 Jan 2010 18:46:34 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 0ADCF8FC1C for ; Wed, 13 Jan 2010 18:46:34 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o0DIkXZp087630 for ; Wed, 13 Jan 2010 18:46:33 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id o0DIkXmE087629; Wed, 13 Jan 2010 18:46:33 GMT (envelope-from nobody) Message-Id: <201001131846.o0DIkXmE087629@www.freebsd.org> Date: Wed, 13 Jan 2010 18:46:33 GMT From: Keith Gaughan To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/142793: dns/unbound: no default for unbound_enable and PID file in problematic location. X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jan 2010 18:50:02 -0000 >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@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: