/etc/init.d/nagios2 reload kills nagios

Bug #228460 reported by Austin Godber
Affects Status Importance Assigned to Milestone
lsb (Debian)
Fix Released
lsb (Ubuntu)
Fix Released

Bug Description

Binary package hint: nagios2

In hardy:
Description: Ubuntu 8.04
Release: 8.04

the /etc/init.d/nagios2 reload function kills the nagios2 process and does not restart it.

There appears to have been a similar bug earlier.

The package was nagios2:

admin@nagiosfdsfds:~$ apt-cache policy nagios2
  Installed: 2.11-1ubuntu1
  Candidate: 2.11-1ubuntu1
  Version table:
 *** 2.11-1ubuntu1 0
        100 /var/lib/dpkg/status

I expected nagios to reread its config files but continue running. It just stopped.

Tags: init nagios2
Revision history for this message
Albert Damen (albrt) wrote :

This is a slightly different bug then bug 161226, as nagios2 is now terminated when nagios2 reload is called.
It is again due to a bug in lsb-base. Below lines are the cause of the problem. Any signal passed to killproc (from /lib/lsb/init-functions) is treated as SIGTERM.

This bug in lsb-base has been fixed in Debian version lsb-base 3.2-12.

Reassigning from nagios2 to lsb.

Changed in nagios2:
status: New → Confirmed
Revision history for this message
Albert Damen (albrt) wrote :

The lines from killproc:

killproc () {
    sig=$(echo ${2:-} | sed -e 's/^-\(.*\)/\1/')
    sig=$(echo $sig | sed -e 's/^SIG\(.*\)/\1/')
    if [ -n "$sig" -o "$sig" = 15 -o "$sig" = TERM ]; then

Changed in lsb:
status: Unknown → Fix Released
Revision history for this message
Albert Damen (albrt) wrote :

This has been fixed in lsb 3.2-12ubuntu1 i intrepid.

killproc now has the lines:
if [ -z "$sig" -o "$sig" = 15 -o "$sig" = TERM ]; then

so only if killproc is called with signal not set or set as sigtem, a sigterm will be done.

Changed in lsb:
status: Confirmed → Fix Released
Revision history for this message
Steve Beattie (sbeattie) wrote :

Marking as a duplicate of LP# 252686, which is still open as a possible Hardy Stable Release Update.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.