ports/76370: Mailgraph.sh: Error on status/stop; can't find pid

Xanthor xanthor at middleearthnet.com
Mon Jan 17 19:50:32 UTC 2005


>Number:         76370
>Category:       ports
>Synopsis:       Mailgraph.sh: Error on status/stop; can't find pid
>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:   Mon Jan 17 19:50:26 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Xanthor
>Release:        FreeBSD 5.3-STABLE
>Organization:
MiddleEarthnet
>Environment:
FreeBSD isengard.middleearthnet.com 5.3-STABLE FreeBSD 5.3-STABLE #0: Fri Dec 31 11:21:23 CET 2004     root at isengard.middleearthnet.com:/usr/obj/usr/src/sys/ISENGARD  i386
>Description:
After mailgraph has been started through the command /usr/local/etc/rc.d/mailgraph.sh start, issuing the command /usr/local/etc/rc.d/mailgraph.sh status it returns: "mailgraph is not running."; while using the stop parameter, it returns; "mailgraph not running? (check /var/db/mailgraph/mailgraph.pid)".
This is due to the fact the saved pid, resolves to "[perl]" instead of the program name.
 
>How-To-Repeat:
Just run the start/status/stop script.
>Fix:
Edit /usr/local/sbin/mailgraph.pl and add the following line:
$0="mailgraph.pl". 
Infact "perldoc perlvar" states:
"On some (read: not all) operating systems assigning to $0 modifies the argument area that the "ps" program sees.  On some platforms you may have to use special "ps" options or a different "ps" to see the changes.  Modifying the $0 is more useful as a way of indicating the current program state than it is for hiding the program you're running."
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list