Installation and Maintenance

Functions

Cron jobs

Setting up cron jobs

A cron job is an automated process that operates at predefined time intervals.
As an example, you can set up a cron job that checks your ILIAS installation every day at 2:00 am for limited user accounts and sends an email notification to users whose account expires within the next 2 weeks.

How to enable this cron job?
- you need write access to the file /etc/crontab
- add the following line in /etc/crontab:

Cron Job Execution ILIAS < 9.x

0 2 * * * APACHEUSER /usr/bin/php ILIAS_ABSOLUTE_PATH/cron/cron.php ILIAS_ADMIN ILIAS_ADMIN_PWD CLIENT > /dev/null

Execution in ILIAS >= 9.x

0 2 * * * APACHEUSER /usr/bin/php ILIAS_ABSOLUTE_PATH/cron/cron.php run-jobs ILIAS_USER CLIENT > /dev/null

Scheduling

To understand this even more, I'll show you what each of the values mean for the above cron tab.
0
Minutes after the hour
2
Hours of the day
*
Days of the month
*
Month of the year
*
Week days of the week
APACHEUSER
The user which runs the cron job. Should be the same as the apache user (wwwrun)
ILIAS_ABSOLUTE_PATH
The absolute path to your ILIAS installation
ILIAS_ADMIN ILIAS
Administrator's user name
ILIAS_ADMIN_PWD
Password of ILIAS admin
CLIENT
Client name of ILIAS installation
This example executes the script cron.php every night at 2 a.m.


No comment has been posted yet.