misc/127444: nagios-statd port RC script fails to log a valid PID, cannot detect running instance

Tyler Aviss a-freebsd at phormix.com
Wed Sep 17 15:50:03 UTC 2008


>Number:         127444
>Category:       misc
>Synopsis:       nagios-statd port RC script fails to log a valid PID, cannot detect running instance
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 17 15:50:02 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Tyler Aviss
>Release:        6.2-RELEASE
>Organization:
>Environment:
FreeBSD sweb1 6.2-RELEASE FreeBSD 6.2-RELEASE #0: Wed Jul  4 12:12:47 EDT 2007     root at sweb1:/usr/obj/usr/src/sys/SMP-DL360  i386
>Description:
nagios-statd does not appear to by default create a pidfile (or not in the location the rc script expects).

Starting nagios-statd via /usr/local/etc/rc.d/nagiosstatd will therefore launch the daemon, but not create a PIDfile. This in turn means that attempting to start or restart the daemon via the RC script will fail, as it does not detect a running instance.
>How-To-Repeat:
$ /var/run$ /usr/local/etc/rc.d/nagiosstatd start
Starting nagiosstatd.
$ ps auxwww | grep statd
root    68885  0.0  0.2  5140  3696  ??  Ss   11:30AM   0:00.04 python /usr/local/sbin/nagios-statd
$ ls /var/run/nagiosstatd.pid
ls: /var/run/nagiosstatd.pid: No such file or directory
$ /var/run$ /usr/local/etc/rc.d/nagiosstatd restart
nagiosstatd not running?
Starting nagiosstatd.
Port 1040 is already in use.  Unable to bind - exiting.

Manually adding a "-P /var/run/nagiosstatd.d" will create the pidfile, but a stop/restart will still complain that the daemon is not running (even when it is, and the pidfile contains a valid process-id for statd)
>Fix:


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


More information about the freebsd-bugs mailing list