ports/155779: [PATCH] mail/policyd2: fix RC script
Frank Wall
fw at moov.de
Tue Mar 22 12:30:02 UTC 2011
>Number: 155779
>Category: ports
>Synopsis: [PATCH] mail/policyd2: fix RC script
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Tue Mar 22 12:30:01 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Frank Wall
>Release: 7.3-RELEASE-p2
>Organization:
>Environment:
FreeBSD 7.3-RELEASE-p2 FreeBSD 7.3-RELEASE-p2 #0: Mon Jul 12 19:23:19 UTC 2010 root at amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
>Description:
The RC script for mail/policyd2 is broken, because it interferes with other perl daemons. The problem is that procname="/usr/bin/perl" is specified. This will match most other perl daemons as well.
So instead of stopping/restarting mail/policyd2, ALL your other perl daemons are going to be killed. Not exactly what I want if I try to stop mail/policyd2. IMHO this is a serious issue.
The attached patch fixes this problem by replacing "procname" with "command_interpreter".
>How-To-Repeat:
1. choose any perl daemon, for example net-mgmt/snmptt, and install it
2. start this perl daemon:
# /usr/local/etc/rc.d/snmptt onestart
Starting snmptt.
# /usr/local/etc/rc.d/snmptt onestatus
snmptt is running as pid 54922.
3. now check policyd2 daemon status
# /usr/local/etc/rc.d/policyd2 onestatus
policyd2 is running as pid 54921 54922.
4. You will recognize that the PID 54922 for policyd2 actually is the PID for your other pearl daemon, snmptt. This is wrong.
>Fix:
apply the patch
Patch attached with submission follows:
--- mail/policyd2/files/policyd2.sh.in.orig 2011-03-22 13:02:27.000000000 +0100
+++ mail/policyd2/files/policyd2.sh.in 2011-03-22 13:13:14.000000000 +0100
@@ -19,7 +19,7 @@
rcvar=`set_rcvar`
command="%%LOCALBASE%%/bin/cbpolicyd"
-procname="/usr/bin/perl"
+command_interpreter="/usr/bin/perl"
load_rc_config $name
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list