Bug 735300
Summary: | Enabling psacct causes daily cron spam | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Pekka Pietikäinen <pp> | ||||
Component: | psacct | Assignee: | Jaromír Cápík <jcapik> | ||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | rawhide | CC: | bill-bugzilla.redhat.com, iand, jcapik, ovasik | ||||
Target Milestone: | --- | Keywords: | Reopened | ||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2013-01-30 00:50:02 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: | |||||||
Attachments: |
|
Description
Pekka Pietikäinen
2011-09-02 08:42:48 UTC
This looks to have appeared in FC15 as /etc/cron.daily/logrotate no longer redirects output from logrotate to /dev/null like it did in FC14 I use this as a workaround (in kickstart.cfg) sed -e '/\/usr\/sbin\/accton \/var\/account\/pacct$/s=$= | grep -v "Turning on"=' < /etc/logrotate.d/psacct > /tmp/psacct$$ cp /tmp/psacct$$ /etc/logrotate.d/psacct rm -f /tmp/psacct$$ Actually that causes a different message due to the grep exit code, so add a cat to hide that exit code. Can't see an option too grep to zero it. sed -e '/\/usr\/sbin\/accton \/var\/account\/pacct$/s=$= | grep -v "Turning on" | cat=' < /etc/logrotate.d/psacct > /tmp/psacct$$ cp /tmp/psacct$$ /etc/logrotate.d/psacct rm -f /tmp/psacct$$ Created attachment 531012 [details]
proposed patch
I'd argue that accton is broken in two ways:
1) it violates the Unix principle of 'least surprise' - it should just shut up if everything works.
2) this status message is necessary despite 1) because accton's default behavior is to toggle the status of process accounting. The behavior is undefined independent of the current state of process accounting. This is bound to cause all kinds of programming errors. Imagine if 'swapon' turned off all swap space if swaps were currently enabled. We have a 'swapoff' symlink and swapon reads its $0 to know what to do. There's not even a --disable flag to swapon, so people don't make these kinds of mistakes (and swapon isn't primarily about security... sigh).
That said, convincing GNU that they're wrong probably won't yield a fix in the f15 timeframe, so proposed patch attached. I'm grepping specifically for this status message, so that all other outcomes propagate to mail, as expected. Thanks for the 'cat' trick, Ian.
OK, 2) above is wrong. Turning on requires a parameter, turning off does not. So, it should be able to be quiet if everything works. I'll ask upstream. Upstream request: https://savannah.gnu.org/bugs/index.php?34748 I don't have edit permission on 'external trackers'. Hello Bill. The change you've done seems to be reasonable. I'm going to apply the patch and test that. Thanks. Regards, Jaromir. This message is a notice that Fedora 15 is now at end of life. Fedora has stopped maintaining and issuing updates for Fedora 15. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At this time, all open bugs with a Fedora 'version' of '15' have been closed as WONTFIX. (Please note: Our normal process is to give advanced warning of this occurring, but we forgot to do that. A thousand apologies.) Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, feel free to reopen this bug and simply change the 'version' to a later Fedora version. Bug Reporter: Thank you for reporting this issue and we are sorry that we were unable to fix it before Fedora 15 reached end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged to click on "Clone This Bug" (top right of this page) and open it against that version of Fedora. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping Hello guys. Sorry for the delay. Bill, I've merged your changes together with changes made by Ian Donaldson (#759321) to the logrotate .in file and modified the spec file accordingly. Thank you all for the report and help. Regards, Jaromir. psacct-6.5.5-6.fc17 has been submitted as an update for Fedora 17. https://admin.fedoraproject.org/updates/psacct-6.5.5-6.fc17 psacct-6.5.5-8.fc18 has been submitted as an update for Fedora 18. https://admin.fedoraproject.org/updates/psacct-6.5.5-8.fc18 This message is a reminder that Fedora 16 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 16. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '16'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 16's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 16 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged to click on "Clone This Bug" and open it against that version of Fedora. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping Package psacct-6.5.5-8.fc18: * should fix your issue, * was pushed to the Fedora 18 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing psacct-6.5.5-8.fc18' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-0944/psacct-6.5.5-8.fc18 then log in and leave karma (feedback). psacct-6.5.5-6.fc17 has been pushed to the Fedora 17 stable repository. If problems still persist, please make note of it in this bug report. psacct-6.5.5-8.fc18 has been pushed to the Fedora 18 stable repository. If problems still persist, please make note of it in this bug report. |