This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 50123 - removing sysklogd package failed
removing sysklogd package failed
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: sysklogd (Show other bugs)
7.1
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Bill Nottingham
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-07-26 20:59 EDT by Florin Andrei
Modified: 2014-03-16 22:22 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-07-27 20:36:26 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Florin Andrei 2001-07-26 20:59:02 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux 2.2.19 i686; en-US; rv:0.9.1)
Gecko/20010608

Description of problem:
When removing sysklogd package, if syklogd is stopped, the removal will fail.
If sysklogd is not stopped, the removal is succesful.
This is wrong. The removal should be ok no matter if sysklogd is started or
not.

How reproducible:
Always

Steps to Reproduce:
1.Install an alternative syslogger to not break dependencies when removing
sysklogd. A good logger is msyslog: 
http://www.geocities.com/elf_too/msyslog/
2.Stop sysklogd: service sysklogd stop
3.Now try to remove sysklogd: rpm -ev sysklogd
	

Actual Results:  It said something about "%preun failed"

Expected Results:  Instead, the package should be removed properly.

Additional info:
Comment 1 Michael Schwendt 2001-07-27 20:36:22 EDT
ACK. To reproduce it:

1. service syslog stop
2. rpm -e --nodeps sysklogd

Gives:

error: execution of %preun scriptlet from sysklogd-1.4-7 failed, exit status 1
# rpm -q --qf "%{PREUN}\n" sysklogd
if [ $1 = 0 ]; then
   /sbin/chkconfig --del syslog
   service syslog stop >/dev/null 2>&1
fi
Order is unlucky. Would be easy to patch. But what would happen if service
syslog were still running and failed to stop? These PREUN scripts don't seem to
handle such special cases. Anyway, this changed script (or without the file
check) would fix this bug:

if [ $1 = 0 ]; then
    [ -f /var/lock/subsys/syslog ] && service syslog stop >/dev/null 2>&1
    /sbin/chkconfig --del syslog
fi
Comment 2 Bill Nottingham 2001-08-03 11:03:39 EDT
Will be fixed in 1.4.1-2 - thanks!

Note You need to log in before you can comment on or make changes to this bug.