[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How anacron get started?



On 12/07/16 22:37, Marvin Renich wrote:
> * solitone <solitone@mail.com> [160712 12:50]:
>> Besides, why
>> anacron says "0 jobs run",
>> when at least one job (zz-backup2l) is in fact run?
> Because anacron determined that it had already run backup2l today, so it
> didn't need to run it again (see the entries at 07:05:30).

Ok, thanks! BTW, anacron ran at 7:05:30 because at that time I plugged
my laptop into AC power and woke it up:

> $ cat /etc/apm/event.d/anacron    
> #! /bin/sh
>
> # This script makes anacron jobs start to run when the machine is
> # plugged into AC power, or woken up.  For a laptop, these are the
> # closest parallels to turning on a desktop.
>
> # [...]
>
> case "$1,$2" in
> change,power|resume,*)
>     /usr/sbin/invoke-rc.d anacron start >/dev/null  
>     ;;
> esac 



Reply to: