Bug 181613

Summary: init script removed on every upgrade
Product: [Fedora] Fedora Reporter: Martin Ebourne <fedora>
Component: nagiosAssignee: Mike McGrath <imlinux>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 4CC: extras-qa
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-02-15 20:13:45 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Martin Ebourne 2006-02-15 14:11:04 UTC
Description of problem:
On every upgrade of this nagios package the init script is deregistered from
chkconfig.

Version-Release number of selected component (if applicable):
nagios-2.0-0.4.rc2.fc4

How reproducible:
Every time

Steps to Reproduce:
1. Install previous version of nagios
2. Upgrade to the current one
  
Actual results:
nagios has been unregistered from chkconfig and therefore will no longer
automatically start on boot.

Expected results:
nagios should still be registered in the same runlevels as before

Additional info:
The problem is the preun script:
  /sbin/service nagios stop > /dev/null 2>&1 || :
  /sbin/chkconfig --del nagios || :

This needs a check for upgrading, as in:
  if [ $1 = 0 ]; then
    /sbin/service nagios stop > /dev/null 2>&1 || :
    /sbin/chkconfig --del nagios || :
  fi

This is a standard idiom in spec files. This would be forgivable in most
packages but nothing emails me to tell me nagios is not running and I only find
out when something else fails quietly. This package really has to get this right
- doesn't anyone review these packages?

As to fixing this: because the preun script is run from the old package this
will break again (for the last time) on the next upgrade. Suggest you warn
people in the email.

Comment 1 Mike McGrath 2006-02-15 20:13:45 UTC
Damn, I noticed this on the last upgrade and completely forgot to fix it.  Its
fixed in the next release.  (Which is already built but not yet in the Extra's Repo)