Summary: | 'logwatch' fails to write daily log | ||
---|---|---|---|
Product: | IPFire | Reporter: | Matthias Fischer <matthias.fischer> |
Component: | --- | Assignee: | Matthias Fischer <matthias.fischer> |
Status: | CLOSED FIXED | QA Contact: | |
Severity: | Minor Usability | ||
Priority: | - Unknown - | CC: | michael.tremer, peter.mueller |
Version: | 2 | ||
Hardware: | all | ||
OS: | Linux |
Description
Matthias Fischer
2019-04-01 17:47:38 UTC
Can you enable cron logging when it calls this command? Is there a way to enable cron logging ONLY for this specific 'logwatch' command? I only know how to enable cron logging completely and this leads to a whole lot of entries in the log... (In reply to Matthias Fischer from comment #2) > Is there a way to enable cron logging ONLY for this specific 'logwatch' > command? > > I only know how to enable cron logging completely and this leads to a whole > lot of entries in the log... No, it is either on or off. And yeah, we have jobs that launch every minute :) FYI: I changed the conjob for logwatch from "01 0 * * *" to "04 0 * * *". The system is now running: "Up: 42 days, 16:36" Problem didn't show up again. Best, Matthias So why does 4am work, but 3am does not? On 20.08.2019 20:15, IPFire Bugzilla wrote:
> https://bugzilla.ipfire.org/show_bug.cgi?id=12036
>
> --- Comment #5 from Michael Tremer <michael.tremer@ipfire.org> ---
> So why does 4am work, but 3am does not?
>
I have no (solid) reason, sorry.
The only reason I can think of is - as you wrote earlier
(development-list, 01.04.2019, Re: Logwatch (randomly) skipping days =>
Feature!?):
"Is it possible that this conflicts with the logrotate job that is
launched at the same time and logwatch tries to read files that are
being rotated away?"
After the last ~45 days I would say: yes...
Sorry, I have no more than that right now.
Only thing I can think of could be to change starting time back to "01 0
* * *" and turn on cron logging. Hadn't the nerve to do this yet and
look for the logs each day...
Best,
Matthias
Hmm, okay. But shouldn't it be enough then to run logwatch a couple of minutes after midnight? Logrotate should not take longer than 5 minutes - and that only when it has to compress a really really really large file. Yep. Thats exactly what I was trying to achieve: I changed the start of 'logwatch' from "one minute after midnight" to "4 minutes after midnight". We can alter this to five minutes but I wouldn't go any further. Or did I miss something? Okay, can you send a patch? Done. To be sure, I set the start time to 00:05am. => https://patchwork.ipfire.org/patch/2377/ => https://git.ipfire.org/?p=people/mfischer/ipfire-2.x.git;a=commit;h=87dce260dbcb5d22b500f3c8dbe21934b52aa09b |