Bug 191451

Summary: Nagios will not autostart after upgrade
Product: [Fedora] Fedora Reporter: Jan ONDREJ <ondrejj>
Component: nagiosAssignee: Mike McGrath <imlinux>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 5CC: drees76, 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-05-16 01:48:16 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 Jan ONDREJ 2006-05-12 04:08:35 UTC
Description of problem:
Nagios will not start after update/upgrade and reboot.
It is a bug in its post-install script.

Version-Release number of selected component (if applicable):
2.3-3.fc5 but also some older packages.

How reproducible:
always

Steps to Reproduce:
1. Configure nagios to start automatically after reboot:
     chkconfig --add nagios
     chkconfig nagios on
2. Upgrade to latest version from fedora extras using yum.
2. Try to look setting:
     chkconfig --list nagios

  
Actual results:
service nagios supports chkconfig, but is not referenced in any runlevel (run
'chkconfig --add nagios')

Expected results:
nagios          0:off   1:off   2:on    3:on    4:on    5:on    6:off


Additional info:
This bug is present in spec file and its preun section. You can't delete
chkconfig entry on update, only on package removation. There are these lines now:
%preun
/sbin/service nagios stop > /dev/null 2>&1 || :
/sbin/chkconfig --del %{name} || :

You must check, if it is removation or upgrade. You can use this code:
%preun
/sbin/service nagios stop > /dev/null 2>&1 || :
if [ "$1" = 0 ]; then
  /sbin/chkconfig --del %{name} || :
fi

and do not delete chkconfig entry on upgrade!

Can somebody check all fedora extras packages for this bug?

Comment 1 Mike McGrath 2006-05-16 01:48:16 UTC
This update is coming out with release 2.3.1.  Its built and should be in the
wild soon.