Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Automatically change network locations with a cron job' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Automatically change network locations with a cron job
Authored by: by on Nov 13, '03 12:05:34PM

Hi,

Isn't it that the smallest cronon that Anacron is using is one day, meaning, you cannot schedule something to run "at 2pm or after"? - IMHO, you can only specify the day/date (see man anacron):

"Anacron can be used to execute commands periodically, with a frequency
specified in days. Unlike cron(8), it does not assume that the machine
is running continuously. Hence, it can be used on machines that aren't
running 24 hours a day, to control daily, weekly, and monthly jobs that
are usually controlled by cron."

Best regards,
Michael



[ Reply to This | # ]
Automatically change network locations with a cron job
Authored by: William McCallum on Nov 13, '03 12:24:12PM

No, Anacron runs its jobs soon after waking up, if they haven't yet been run for that day (or week, or month). I believe it uses the delay set in the "delay" colum of the file anacrontab (although I've never actually checked that).



[ Reply to This | # ]
Automatically change network locations with a cron job
Authored by: jpbjpbjpbjpb on Nov 13, '03 01:18:25PM

Yes, it runs jobs when the machine wakes up, but that doesn't mean you have a higher granularity than a day, it won't run jobs unless it's been at least 24 hours since the last time it ran.

There is no way for you to specify with anacron for things to be run at a specific time, just that they be run at least every N days.



[ Reply to This | # ]