Bug 157448
Summary: | logwatch anacrontab + crontab entries can let logwatch run too frequently | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Jason Vas Dias <jvdias> |
Component: | anacron | Assignee: | Marcela Mašláňová <mmaslano> |
Status: | CLOSED RAWHIDE | QA Contact: | Brock Organ <borgan> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | rawhide | CC: | sergio |
Target Milestone: | --- | Keywords: | Reopened |
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2007-08-14 10:30:14 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
Jason Vas Dias
2005-05-11 18:23:41 UTC
I've raised this bug for this problem originally reported as an addendum to bug #138001, which wasn't a related bug . I'll investigate whether there is anything wrong with cron or anacron's behaviour that causes this problem, and am working on a vixie-cron enhancement that would fix it, but for now it should be up to logwatch to prevent itself being run too frequently. I think this change could be problem becouse of logwatch is not destructive programme it only creates log mail. So if logwatch run twice a day there is no harm. And a user can run logwatch more often than daily. I think if logwatch run twice a day there is not almost any problem (one more mail). But if there will be any time stamp and time check user could not use logwatch more often then daily and it is constraint. So I think this problem would not be fixed. If you don't make a protest I will close this bug. well this is my problem this running always when my laptop starts , like other crons ok, maybe we could close this bug and report other bug in anacron , Finally I understand my problem and I think that is a bug when I start or restart my computer (laptop or desktop) after 0.00 AM (midnight) for example Oct 25 00:24:38 localhost crond[2464]: (CRON) STARTUP (V5.0) Oct 25 00:24:39 localhost anacron[2500]: Anacron 2.3 started on 2006-10-25 Oct 25 00:24:39 localhost anacron[2500]: Will run job `cron.daily' in 65 min. Oct 25 00:24:39 localhost anacron[2500]: Will run job `cron.weekly' in 70 min. Oct 25 00:24:39 localhost anacron[2500]: Jobs will be executed sequentially This is wrong cron.daily should start at 4.02 AM the hour that is write on /etc/crontab Thanks for report. I thought that some jobs run twice. Now I try change time and investigate what's the problem. well checking my logs on my laptop , I can see that logwatch still running twice the best example : ################### Logwatch 7.2.1 (01/18/06) #################### Processing Initiated: Mon Oct 16 03:58:59 2006 Date Range Processed: yesterday ( 2006-Oct-15 ) Period is day. Detail Level of Output: 0 Type of Output: unformatted Logfiles for Host: segulix ################################################################## and ################### Logwatch 7.2.1 (01/18/06) #################### Processing Initiated: Mon Oct 16 04:02:20 2006 Date Range Processed: yesterday ( 2006-Oct-15 ) Period is day. Detail Level of Output: 0 Type of Output: unformatted Logfiles for Host: segulix ################################################################## but if you fix Comment #4, maybe will fix also this. Well yes, because logwatch is parsing file from comment#4 :) I can't reproduce this bug and have no idea how could be possible. Could you send me all your crontab and anacrontab? I don't have change crontab neither anacrontab, just open laptop or reboot laptop after midnight, after this, just cat /var/log/cron and you will see something like: Oct 25 00:24:39 localhost anacron[2500]: Will run job `cron.daily' in 65 min. Oct 25 00:24:39 localhost anacron[2500]: Will run job `cron.weekly' in 70 min. which IMHO it is a bug cause should start at default crontab time which is 4:02 Ha! Now I see. If you switch on computer cron search in cron.d/cron.daily and run jobs in 65minutes as you wrote. If you don't switch off your computer and it's running more than one day, then it's cron.daily run at 4:02 a.m. as you can see here: Nov 14 03:01:01 local crond[2709]: (root) CMD (run-parts /etc/cron.hourly) Nov 14 04:01:01 local crond[2832]: (root) CMD (run-parts /etc/cron.hourly) Nov 14 04:02:01 local crond[2835]: (root) CMD (run-parts /etc/cron.daily) Nov 14 04:02:01 local anacron[2838]: Updated timestamp for job `cron.daily' to 2006-11-14 Nov 14 05:01:01 local crond[4519]: (root) CMD (run-parts /etc/cron.hourly) Nov 14 06:01:01 local crond[4619]: (root) CMD (run-parts /etc/cron.hourly) yap , but it is a bug on laptops, I have the luck that I can't reopen the bug. That's laptop or computer independent. It's not a bug, for more information use man cron, anacron, anacrontab. so why logwatch run twice ? and if I put a cron.daily to run to 18:00 why when I switch on my laptop on work after 65 minutes begin to run cron.daily , and run cron.daily twice a day ? I have to uninstall beagle, because I have to work after 65 minutes of switch on my laptop. And it is a bug when we want that works out of the box, on ordinary laptops. Anacron have to check (when wake up) if the crons for this day have already past if not, don't have to cron anything. if a laptop have been shutdown for some days, is correct running cron.weekly if it is missed , but is not correct, laptop have all crons updated . I don't how it's possible, please try to upgrade. I'm planning some changes in crons, maybe it helps. (In reply to comment #14) > I don't how it's possible, please try to upgrade. I'm planning some changes in > crons, maybe it helps. I update fedora almost every day. The solution is simple like that, when computer wake up see if have been missed some schedule cron. if not, don't cron anything and waits for the crontab do his job. Sorry for my bad English! root 1953 1 0 02:55 ? 00:00:00 crond root 2013 1 0 02:55 ? 00:00:00 anacron -s root 3381 2013 0 04:00 ? 00:00:00 /bin/bash /usr/bin/run-parts /etc/cron.daily root 3395 1953 0 04:02 ? 00:00:00 crond root 3396 3395 0 04:02 ? 00:00:00 /bin/bash /usr/bin/run-parts /etc/cron.daily cat /var/log/cron Aug 4 02:50:51 localhost anacron[2013]: Anacron 2.3 started on 2007-08-04 Aug 4 02:50:51 localhost anacron[2013]: Will run job `cron.daily' in 65 min. Aug 4 02:50:51 localhost anacron[2013]: Jobs will be executed sequentially Aug 4 03:03:19 localhost crond[2885]: (root) CMD (run-parts /etc/cron.hourly) Aug 4 04:00:09 localhost anacron[2013]: Job `cron.daily' started Aug 4 04:01:02 localhost crond[3394]: (root) CMD (run-parts /etc/cron.hourly) Aug 4 04:02:01 localhost crond[3396]: (root) CMD (run-parts /etc/cron.daily) I tried tu change scripts a bit and now I'm testing the behaviour of anacron/cron jobs. I'd like to push it to F-8. You can try anacron-2.3-49.fc8. I suppose that there should be still some problems. Please let me know. Hi, after four years, I found the mystery , I am writing to send my apologizes :) I got a /etc/crontab.rpmnew and /etc/crontab still with old version: cat /etc/crontab SHELL=/bin/bash PATH=/sbin:/bin:/usr/sbin:/usr/bin MAILTO=root HOME=/ # run-parts 01 * * * * root run-parts /etc/cron.hourly 02 8 * * * root run-parts /etc/cron.daily 42 8 * * 0 root run-parts /etc/cron.weekly 42 9 1 * * root run-parts /etc/cron.monthly so run-parts run always twice for cron.daily. I keep upgrading the computer (*), don't use it to often. And on Fedora 14 by other problem I found this issue. (*) well is not the computer is the data of the computer . Thanks, Sorry for my misunderstanding. Thank you :) |