Bug 643130 - run-parts needs the --list parameter (or logcheck needs a workaround)
Summary: run-parts needs the --list parameter (or logcheck needs a workaround)
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: logcheck
Version: 13
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Matthias Runge
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 705822
TreeView+ depends on / blocked
 
Reported: 2010-10-14 18:13 UTC by Matthias Runge
Modified: 2011-05-18 15:31 UTC (History)
3 users (show)

Fixed In Version: logcheck-1.3.13-4.fc13
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 705822 (view as bug list)
Environment:
Last Closed: 2010-11-19 22:32:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Matthias Runge 2010-10-14 18:13:03 UTC
chris@chris....uk reported the following problem:

Thanks very much for adding logcheck to the repository - great tool.  But it
doesn't seem to be working at all: it's not filtering any entries out on my
system.

I've tested using log messages from a few daemons with /usr/bin/logcheck-test,
and the ignore rules are matching correctly, but a run of logcheck then spews
out all those log messages without filtering any out.

Here's what I think is happening: logcheck uses /usr/bin/run-parts to pick up
the filter rule files from subdirectories of /etc/logcheck.  run-parts looks
for executables, and runs them.  But that's not what logcheck wants it to do -
logcheck wants it to spit out the names of matching files, not actually execute
them.

The Debian version of run-parts has a --list parameter, which does exactly
this.  When the logcheck package has been ported across to Fedora, the --list
parameter has been removed from the invocation of run-parts (because our
version of run-parts doesn't have that parameter), but that simply results in
run-parts producing no output.  Which means that logcheck thinks it has no
filter rule files.  Which means no log messages ever get filtered out.

I'm surprised that this is the case, because the package should never have been
pushed to stable with such a fundamental bug in it.  But I'm fairly sure that's
what's going on (on my system, at least - Fedora 13 with
logcheck-1.3.13-2.fc13.noarch and crontabs-1.10-32.fc13.noarch).
-------
In confirmation of the above: simply replacing the invocation of run-parts with
/bin/ls in the cleanrules() function of logcheck fixes the problem.

We don't want to do this, because it loses the benefits of run-parts (ignoring
.rpmsave files, etc.) - but it does demonstrate that that's where the problem
is.

Comment 1 Matthias Runge 2010-10-14 18:21:21 UTC
I see the problem. Interestingly, logcheck works for me just a while now without any problems.

Imho there are two possible solutions:
1. Contact run-parts-maintainer to implement the --list option (like in debian)
2. Implement a workaround (and patch run-parts out)

I'd prefer the first option and will contact crontabs-maintainer to discuss a solution.

Comment 2 Matthias Runge 2010-11-02 08:49:49 UTC
Additional info: 

Marcela Maslanova as maintainer for run-parts will implement the --list parameter for me. (Had contact on 10/15/2010 via email)

Comment 3 Fedora Update System 2010-11-02 20:47:26 UTC
logcheck-1.3.13-4.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/logcheck-1.3.13-4.fc14

Comment 4 Fedora Update System 2010-11-02 20:49:09 UTC
logcheck-1.3.13-4.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/logcheck-1.3.13-4.fc13

Comment 5 Matthias Runge 2010-11-02 20:52:11 UTC
logcheck-1.3.13-4 is submitted for testing. crontabs-1.11 is required.
Thanks to Marcela Maslanova, who implemented the --list-option for run-parts

Comment 6 Fedora Update System 2010-11-03 21:10:28 UTC
logcheck-1.3.13-4.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update logcheck'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/logcheck-1.3.13-4.fc13

Comment 7 Fedora Update System 2010-11-19 22:32:38 UTC
logcheck-1.3.13-4.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2010-11-19 22:34:06 UTC
logcheck-1.3.13-4.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 Kevin J. Cummings 2010-12-03 21:45:42 UTC
Will crontabs-1.11 going to be made available for F13?  As of today, it is not in updates or updates-testing....

Comment 10 Matthias Runge 2010-12-04 16:09:53 UTC
I'll ask Marcela to submit her version of crontabs to F13. If this is not possible, because crontabs got a new feauture, I'll find another solution.

Comment 11 Matthias Runge 2010-12-10 10:45:35 UTC
crontabs went into updates-testing for f13 yesterday.


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