LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Suse/Novell
User Name
Password
Suse/Novell This Forum is for the discussion of Suse Linux.

Notices

Reply
 
Search this Thread
Old 05-20-2006, 08:19 AM   #1
dannystaple
Member
 
Registered: Apr 2006
Location: London, Uk
Distribution: Ubuntu on Desktop
Posts: 121

Rep: Reputation: 15
Lightbulb Cron.daily timing info (problem and solution)


I had a problem in that my cron.daily jobs were running a 23:30 (local time) every night. Which was annoying - as I was likely to be browsing, listening to music or playing a game at the time, and one of those jobs is the updatedb tool. This meant my music/game would stutter as the hard disk was thoroughly thrashed.

First I tried to see if there was documentation on configuring the run-crons system, and was slightly frustrated - googling had a lot on cron, and cron.daily, but naught on how you would determine what time of day "daily" actually meant.

I had a look at the run crons to try and figure out how it determined what time its daily jobs will run, and noted that it is actually determining its run time from its last run. It touches a file with a time/date stamp then, and then runs itself at 1440 minutes (thats 24 hours to us humans) after that time.

So the way to actually configure this is to use the "touch -t" command, which will then set the timestamp of said file. This can be in the past or future, and will determine when the script runs.

I did take a look to see if something like this also had a panel in yast2 - but unless I have missed something, cron completely fails to make an appearance there. Do let me know if I am misinformed here.

Anyway - this is not so much a question, as a sharing of experiences in the hope that some other soul googling this will find it.

Danny
 
Old 05-20-2006, 03:30 PM   #2
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,123

Rep: Reputation: 162Reputation: 162
That's interesting, I hadn't seen the cron config on a Suse system before. Off topic and probably only interesting to people who like to use several distros, on Slackware the root's crontab holds the periodic cron jobs and running crontab -l for the root user gives the following (plus other stuff):
Code:
10 0 * * * /usr/bin/run-parts /etc/cron.daily 1> /dev/null
 
Old 05-25-2006, 05:36 PM   #3
ThisGuyIKnow
Member
 
Registered: Mar 2006
Posts: 43

Rep: Reputation: 15
Thanks dannystaple, this is good information. I've been wondering about this.

- Gavin
 
Old 05-26-2006, 06:59 AM   #4
spirit receiver
Member
 
Registered: May 2006
Location: Frankfurt, Germany
Distribution: SUSE 10.2
Posts: 424

Rep: Reputation: 33
The purpose is of course that the content of cron.daily will executed without the need to have the computer turned on at a specific time. In SUSE 10.1, there's an option in YaST (System->etc/Sysconfig-Editor->System->Cron) named DAILY_TIME. I think this is new in 10.1, and you can probably imagine what it does.
 
Old 05-27-2006, 07:32 AM   #5
dannystaple
Member
 
Registered: Apr 2006
Location: London, Uk
Distribution: Ubuntu on Desktop
Posts: 121

Original Poster
Rep: Reputation: 15
Spirit, thats good to know, it did seem conspicuous in its absence. I am still not quite ready to go to 10.1 - I hear its having teething problems.
 
Old 08-06-2008, 08:31 AM   #6
slarti
LQ Newbie
 
Registered: Jan 2005
Posts: 1

Rep: Reputation: 0
Quote:
Originally Posted by dannystaple View Post
It touches a file with a time/date stamp then, and then runs itself at 1440 minutes (thats 24 hours to us humans) after that time.

Thanks for that. Can you tell us which file it touches? (Ubuntu isn't my main system so I can't easily look myself, but I do occasional work on a Ubuntu system and would like to know for future reference!)
 
  


Reply

Tags
cron, suse, yast2


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cron Job Selective Timing kyosuke Linux - General 3 03-01-2006 10:52 PM
Problem With Script in cron.daily fizbang Linux - Newbie 10 03-21-2005 11:23 AM
cron.daily reporting a squidGuard config problem kalahari875 Mandriva 3 10-03-2004 12:14 PM
cron.daily MrJoshua Linux - General 2 03-19-2003 01:09 PM
dual entries in cron log for cron.daily cpharvey Linux - General 3 02-27-2003 03:30 PM


All times are GMT -5. The time now is 07:25 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration