Koozali.org: home of the SME Server

Obsolete Releases => SME 8.x Contribs => Topic started by: gwalker-it on July 23, 2014, 10:07:41 AM

Title: affa schedule not running jobs
Post by: gwalker-it on July 23, 2014, 10:07:41 AM
Hey guys, I've just installed sme server 8.1 and affa backup.
I've configured a backup and set a time to schedule the backup to run but it doesn't seem to run.
I've set emailAddresses and chattyOnSuccess and I didn't get an email for the scheduled job.
When i run the job manually it runs the backup job fine and emails me the results.

I've searched the forum and online but can't see anything related to affa backup schedule.
Can anybody suggest where I could look to investigate this?

Thanks,
Graham
Title: Re: affa schedule not running jobs
Post by: Stefano on July 23, 2014, 10:10:30 AM
hi, welcome here

what about logs? /var/log/messages to start
Title: Re: affa schedule not running jobs
Post by: gwalker-it on July 23, 2014, 10:20:30 AM
Hi Stefano,

Looking in the affa files in the location you suggested, I can see that the only activity is when I'm logged in doing backups manually.
I've looked in a couple of the cron files, i can't see any reference to affa but I might be missing something.

Thanks for the quick reply.
Title: Re: affa schedule not running jobs
Post by: Stefano on July 23, 2014, 10:22:02 AM
did you follow all the howto page?

I guess you miss the
Code: [Select]
affa --make-cronjobs

step (I'm unsure of the syntax..)
Title: Re: affa schedule not running jobs
Post by: gwalker-it on July 23, 2014, 10:31:18 AM
Yes, I followed the instructions for sme server 8, I don't think I missed the make command.
I can see the affa cron file entries within /etc/cron.d I just can't understand why it's not running.
Title: Re: affa schedule not running jobs
Post by: Stefano on July 23, 2014, 10:49:07 AM
dig in /var/log/cron, if something is wrong you should find the reason
Title: Re: affa schedule not running jobs
Post by: gwalker-it on July 23, 2014, 03:57:37 PM
In the cron file I can see each cron.hourly job ran, purge-junkmail, warnquota, check4updates, cron.daily, squid but no sign of affa jobs.

Jul 22 19:35:17 server crond[3653]: (CRON) STARTUP (V5.0)
Jul 22 20:01:01 server crond[4995]: (root) CMD (run-parts /etc/cron.hourly)
Jul 22 21:01:01 server crond[5246]: (root) CMD (run-parts /etc/cron.hourly)
Jul 22 22:01:11 server crond[6127]: (root) CMD (run-parts /etc/cron.hourly)
Jul 22 23:01:01 server crond[6561]: (root) CMD (run-parts /etc/cron.hourly)
Jul 22 23:25:01 server crond[6626]: (root) CMD (perl /etc/e-smith/events/actions/purge-junkmail-folders)
Jul 23 00:01:01 server crond[6726]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 00:37:01 server crond[6823]: (root) CMD (/sbin/e-smith/warnquota)
Jul 23 01:01:01 server crond[6886]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 02:01:01 server crond[7045]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 03:01:01 server crond[7206]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 04:01:01 server crond[7371]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 04:02:01 server crond[7375]: (root) CMD (sleep $[ $RANDOM % 3600 ]; /sbin/e-smith/check4updates -m )
Jul 23 04:02:01 server crond[7377]: (root) CMD (run-parts /etc/cron.daily)
Jul 23 04:02:01 server anacron[7382]: Updated timestamp for job `cron.daily' to 2014-07-23
Jul 23 04:55:01 server crond[8018]: (root) CMD (squid -k rotate)
Jul 23 05:01:01 server crond[8037]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 06:01:01 server crond[8203]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 07:01:01 server crond[8359]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 08:01:01 server crond[8519]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 09:01:01 server crond[9206]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 10:01:01 server crond[9653]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 11:01:01 server crond[9874]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 12:01:01 server crond[10129]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 13:01:02 server crond[10334]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 14:01:01 server crond[10548]: (root) CMD (run-parts /etc/cron.hourly)
Jul 23 15:01:01 server crond[11113]: (root) CMD (run-parts /etc/cron.hourly)
Title: Re: affa schedule not running jobs
Post by: Jáder on July 24, 2014, 03:50:21 AM
So the entries in cron are wrong... they never execute.
post your cron entries.

Mine are like these:
Code: [Select]
[root@leopardo ~]# grep -r affa /etc/cron*
/etc/cron.d/affa-status:00 5 * * 0 root /sbin/e-smith/affa --send-status
/etc/cron.d/affa:30 22 * * * root  /sbin/e-smith/affa --watchdog=86400 --run Zxxxxa
/etc/cron.d/affa:15 20 * * * root  /sbin/e-smith/affa --watchdog=86400 --run Rxxxxa
/etc/cron.d/affa:00 20 * * * root  /sbin/e-smith/affa --watchdog=86400 --run Bxxx
/etc/cron.d/affa:30 06 * * * root  /sbin/e-smith/affa --watchdog=86400 --run Axxx-xx
/etc/cron.d/affa:30 20 * * * root  /sbin/e-smith/affa --watchdog=86400 --run Axxxxxx
[root@leopardo ~]#
Did you have some like that?
Title: Re: affa schedule not running jobs
Post by: gwalker-it on July 24, 2014, 08:15:50 AM
I have:

/etc/cron.d/affa-status:00 5 * * 0 root /sbin/e-smith/affa --send-status
/etc/cron.d/affa:30 17 * * * root  /sbin/e-smith/affa --watchdog=86400 --run oxxxxxx
Title: Re: affa schedule not running jobs
Post by: brianr on July 25, 2014, 03:57:03 PM
Have you tried:

affa --status

on the backup server to see if the jobs have actually run?

Please post the results of this...
Title: Re: affa schedule not running jobs
Post by: nicolatiana on July 26, 2014, 11:45:41 AM
 . . . and give look at /var/log/affa: you should find an affa specific log and a job specific log.

Did you send ssh keys ?

Run manually a job (affa --run jobname) to generate eventual further errors.

Nicola