[Pkg-nagios-devel] Bug#415752: /etc/init.d/nagios2 reload removes the pid file

Brecht Samyn Brecht.Samyn at kulak.ac.be
Wed Mar 21 18:37:42 CET 2007


Package: nagios2
Version: 2.6-2+etch1
Severity: normal

the reload() function in /etc/init.d/nagios2 executes
	killproc -p $THEPIDFILE $DAEMON 1
which calls
	start-stop-daemon
and this command removes the nagios.pid file

This file is needed to reload or stop nagios...

A quick solution is to recreate $THEPIDFILE after killproc is executed
...
    if check_started; then
      pid="$(cat $THEPIDFILE)"
      killproc -p $THEPIDFILE $DAEMON 1
      # recreate $THEPIDFILE
      echo $pid > $THEPIDFILE
    else
...


-- System Information:
Debian Release: 4.0
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-4-xen-amd64
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages nagios2 depends on:
ii  libc6                     2.3.6.ds1-13   GNU C Library: Shared libraries
ii  libgd2-noxpm              2.0.33-5.2     GD Graphics Library version 2 (wit
ii  libjpeg62                 6b-13          The Independent JPEG Group's JPEG 
ii  libperl5.8                5.8.8-7        Shared Perl library
ii  libpng12-0                1.2.15~beta5-1 PNG library - runtime
ii  nagios2-common            2.6-2+etch1    support files for nagios2
ii  perl                      5.8.8-7        Larry Wall's Practical Extraction 
ii  zlib1g                    1:1.2.3-13     compression library - runtime

nagios2 recommends no packages.

-- no debconf information

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm





More information about the Pkg-nagios-devel mailing list