Re: Ghost cronjob
On Mon 03 May 2021 at 09:07:26 (+0200), Mart van de Wege wrote:
> I have the following configured to back up my laptop to my file server:
>
> root@galahad:~# cat /etc/cron.d/backup
> MAILTO=mart@vdwege.eu
> #00 04 * * * root /usr/sbin/btrbk --verbose --format=long run
>
> Note: it is currently disabled.
>
> The only other places I have anything mentioning btrbk in /etc is in
> btrbk's config files:
>
> root@galahad:~# grep btrbk /etc/ -rl
> /etc/btrbk/btrbk.conf.example
> /etc/btrbk/btrbk.conf.old
> /etc/btrbk/btrbk.conf.local
> /etc/btrbk/btrbk.conf~
> /etc/btrbk/btrbk.conf
> /etc/cron.d/backup
>
> And yet I find this in /var/log/btrbk.log:
>
> 2017-03-12T20:16:28+0100 startup v0.24.0 - - - - # btrbk command line client, version 0.24.0
>
> There are no systemd timers related to btrbk either.
>
> This started about 1.5 months ago when I changed the backup time from
> midnight to 04:00; it took me some time to notice in the status mails
> that btrbk was creating duplicate snapshots, and checking the logs
> showed that at ran both at midnight and at 04:00. Disabling the 04:00
> cronjob left the ghost cronjob at 00:00 intact.
>
> How do I find out why a periodic job is running with nothing obviously
> configured for it?
Just guessing. You set the cron job to initiate a backup at 04:00.
Perhaps there's something configured in your /etc/btrbk/btrbk.conf
that says check for retention by day/week/month/year rather than
04:00/day/week/month/year. The former check has to made at midnight.
Cheers,
David.
Reply to: