ports/117957: swatch can't stop (doesn't match pid with procname)

Michael Scheidell scheidell at secnap.net
Sat Nov 10 11:00:02 UTC 2007


>Number:         117957
>Category:       ports
>Synopsis:       swatch can't stop (doesn't match pid with procname)
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Nov 10 11:00:01 UTC 2007
>Closed-Date:
>Last-Modified:
>Originator:     Michael Scheidell
>Release:        5.5 and 6.2
>Organization:
SECNAP Network Security
>Environment:
na.
>Description:
/usr/local/etc/rc.d/swatch.sh status does not find running swatch since rc.subr is trying to match procname with name


>How-To-Repeat:
procname needs to be set to /usr/local/bin/perl in order for rc.subr to find it:

example:

/usr/local/etc/rc.d/swatch.sh status
swatch is not running.

cat /pid:
72676

ps -auxwwp 72676
USER   PID %CPU %MEM   VSZ   RSS  TT  STAT STARTED      TIME COMMAND
root 72676  0.0  1.1  6596  5876  ??  Is    5:44AM   0:00.03 /usr/local/bin/perl /tmp/.swatch_script.72674

>Fix:
fix:

add procname=/usr/local/bin/perl to swatch.sh:

./swatch.sh status
swatch is running as pid 72676

patch for swatch.sh:
 diff -bBru swatch.sh.orig swatch.sh
--- swatch.sh.orig      Sat Nov 10 05:56:52 2007
+++ swatch.sh   Sat Nov 10 05:57:38 2007
@@ -22,6 +22,7 @@
 name=swatch
 rcvar=`set_rcvar`
 command=/usr/local/bin/swatch
+procname=/usr/local/bin/perl

 load_rc_config ${name}



ps, swatch 3.2.2 is out now.




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



More information about the freebsd-ports-bugs mailing list