On Thu, Jan 14, 2010 at 09:08:50PM +0000, Ian Porter wrote:
Hi Chris
On Thu, Jan 14, 2010 at 7:31 PM, Chris G cl@isbd.net wrote:
I have a backup job that (should) be run daily. There is a script called 'backup' that is in /etc/cron.daily.
If the computer is shutdown regularly then anacron does its job and runs backup a few minutes after the computer is powered up again. If, on the other hand, the computer is on all the time then cron runs the job at 07:30.
However, and this is the problem, if the computer is Suspend[ed] and isn't running at 07:30 then the jobs in /etc/cron.daily never get run. Is there any way around this?
Not sure if this a good guess, but since /etc/cron.d/anacron will not be run since the computer was in a "on" state as such at 7:30.
How about putting in two anacron runs in the cron.d one in the morning and the other at night time ? because if any of the timestamps for the jobs that have been run will be checked.
That's an idea, anacron checks anyway for 'run already' so it should work OK.
As I say just a guess.