Description of problem:
The backup configuration page enables administrators to configure automated
course backups and a backup schedule.
This does not work in moodle on Fedora
Core6 and I think this problem also exits in moodle1.8, coming with
Version-Release number of selected component (if applicable):
Login in moodle as admin and go to the administration page.
Activate automatic backup for example from Monday to Friday
Steps to Reproduce:
1.Login in moodle as admin
2.Go to the administration page
3.go to backup
No backups are made
There is a cron-file in the directory /etc/cron.d under the name moodle
containing the following crontab-entry:
*/5 * * * * apache /usr/sbin/moodle-cron
This starts the shellscript /usr/sbin/moodle-cron every 5 minutes.
But the shell-script moodle-cron will not do anything because
it checks if the file /var/lock/subsys/moodle exits:
[ -f /var/lock/subsys/moodle ] && /usr/bin/php /var/www/moodle/web/admin/cron.php
This is never true on my system because moodle did not create
the file /var/lock/subsys/moodle (moodle is not a daemon)
[ -f /var/lock/subsys/httpd ] would make sense!
Check the 1.8.2-1 build in rawhide, it addresses this issue.
moodle-1.8.2-1.fc7 has been pushed to the Fedora 7 stable repository. If problems still persist, please make note of it in this bug report.
The problem with the cron file mentioned in "Additional info" in the original bug report is still there in moodle-1.9.4
The current moodle-cron on all versions is the following:
[ -f /var/lock/subsys/moodle ] && [ -f /var/lock/subsys/httpd ] && /usr/bin/php /var/www/moodle/web/admin/cron.php
Does this not work?
Update coming for F-10 and F-9.
[ -f /var/lock/subsys/moodle ] && [ -f /var/lock/subsys/httpd ] && /usr/bin/php
This would not work, because moodle will not generate a file /var/lock/subsys/moodle (This is true for version 1.6.5-5.fc6, which I use)
Perhaps newer versions will? - but I don't think so, because moodle is not
a daemon and therefor not an independent process and will not be started through a
(see: "Why do init scripts require lock files? by Bradford Hinson": http://www.redhat.com/magazine/008jun05/departments/tips_tricks/)
The file /var/lock/subsys/httpd will generated when httpd starts, and this file
will removed when httpd is stopped through the SystemV-Start/StopScript.
[ -f /var/lock/subsys/httpd ] && /usr/bin/php /var/www/moodle/web/admin/cron.php
moodle-1.9.4-3.fc10 has been submitted as an update for Fedora 10.
moodle-1.9.4-3.fc9 has been submitted as an update for Fedora 9.
moodle-1.9.4-3.fc9 has been pushed to the Fedora 9 stable repository. If problems still persist, please make note of it in this bug report.
moodle-1.9.4-3.fc10 has been pushed to the Fedora 10 stable repository. If problems still persist, please make note of it in this bug report.