Bug 117957 - security/swatch can't stop (doesn't match pid with procname)
Summary: security/swatch can't stop (doesn't match pid with procname)
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-10 11:00 UTC by Michael Scheidell
Modified: 2008-03-12 01:30 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Scheidell 2007-11-10 11:00:01 UTC
/usr/local/etc/rc.d/swatch.sh status does not find running swatch since rc.subr is trying to match procname with name

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


load_rc_config ${name}



ps, swatch 3.2.2 is out now.--ZXsX0Ti8euOdYUU52gJtUnppfurQkX3ODlniNu9BAn8UtFEQ
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

--- 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
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
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2007-11-10 12:31:00 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 2 Joseph Scott 2007-11-12 16:56:14 UTC
On Nov 10, 2007, at 5:30 AM, Edwin Groothuis wrote:

> Maintainer of security/swatch,
>
> Please note that PR ports/117957 has just been submitted.

Looks fine, commit away.

--
Joseph Scott
http://joseph.randomnetworks.com/
Comment 3 Mark Linimon freebsd_committer freebsd_triage 2008-01-26 22:54:52 UTC
State Changed
From-To: feedback->open

Maintainer approved.
Comment 4 dfilter service freebsd_committer freebsd_triage 2008-03-12 01:28:33 UTC
gahr        2008-03-12 01:28:28 UTC

  FreeBSD ports repository

  Modified files:
    security/swatch      Makefile 
    security/swatch/files swatch.sh 
  Log:
  - Make RC script match pid with procname
  
  PR:             117957
  Submitted by:   Michael Scheidell <scheidell@secnap.net>
  Reviewed by:    Joseph Scott <joseph@randomnetworks.com> (maintainer)
  Approved by:    Joseph Scott <joseph@randomnetworks.com> (maintainer),
                  miwi (mentor)
  
  Revision  Changes    Path
  1.23      +1 -0      ports/security/swatch/Makefile
  1.3       +2 -1      ports/security/swatch/files/swatch.sh
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 5 Pietro Cerutti freebsd_committer freebsd_triage 2008-03-12 01:28:50 UTC
State Changed
From-To: open->closed

Committed. Thanks!