How can I change the default time of cron of the system?
Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
So the default time of running crons (cron.daily, cron.weekly, etc) should be at 4 am. But, of course, my computer is shut down at that time. Then the crons usually run at about 9:20 am (I don't know why). I do not want that because I'm usually busy at that time. So I have changed all the '4' into '12' in the crontab file. Now I have the crons run at 12 am (12:02, 12:22, and 12:40 in fact) but the session at 9:20 am is not eliminated. So I have two sessions of crons every day...
Who can help me to eliminate the cron task at 9:20 am?
i think in most cases you're supposed to use the crontab -e command to change cron, not edit the crontab file directly. but maybe there are different implementations of cron where you can just edit /etc/crontab, not sure. in any case, it might be helpful if you could post the output of crontab -l. i'm not seeing where the 9:20 is in what you posted.
In fact, I have edited the crontab file directly. This approach works in at least FC3 but fails in my FC5 now. I do not know what's the reason for this result.
I input 'crontab -l' as root but got 'no crontab for root'. How can I get the output of crontab for the system?
I was just thinking that your job running at 0920 might be because of anacron. You may want to check the contents of your /etc/anacrontab. For example, if you power your pc up at 0900 and you have a line in the anacrontab file with a delay of 20 minutes, then the job on that line will run at 0920. You may also see something in the log file /var/log/cron that indicates this. If this is true, you can simply change the delay to suit you. If you need more info on anacrontab, check the man page. Let me know if this helps.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.