TimeTrex maintenance jobs have not run in the last 48 hours

Topics brought up by the TimeTrex open source community.
Locked
aathisankar
Posts: 3
Joined: Mon Mar 31, 2008 12:17 am
Contact:

TimeTrex maintenance jobs have not run in the last 48 hours

Post by aathisankar »

i have the crontab entry as follows

* * * * * php /programs/apache/htdocs/timetrex/maint/cron.php > /dev/null 2>&1

getting the mail as an error like follows

Code: Select all

DEBUG [259]:        <b>[Function]()</b>: URI:
/programs/apache/htdocs/timetrex/maint/cron.php<br>
DEBUG [261]:        <b>[Function]()</b>: Version: 2.2.8 Edition: 10 Production: 1 Demo
Mode: 0<br>
DEBUG [107]:        <b>TTDate::setTimeZone()</b>: Setting TimeZone: Asia/Calcutta<br>
DEBUG [476]:        <b>Install::checkPHPVersion()</b>: Comparing with Version: 5.2.5<br>
DEBUG [476]:        <b>Install::checkPHPVersion()</b>: Comparing with Version: 5.2.5<br>
DEBUG [39]:        <b>DBError::__construct()</b>: mysqlt error: [-32000: Cache write error]
in CacheExecute(/tmp/timetrex//93/adodb_936e17385786cc62241b96df62979d85.cache,
select * from cron where id = -1)
<br>
what will be the problem.. help please

Sankar Ganesh S
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Post by shaunw »

Your cronjob isn't running as the same user that your web server is, so when one or the other goes to write cache files in the cache directory they are conflicting due to permissions.

Your cron command should look something like this:

su www-data -c "php /programs/apache/htdocs/timetrex/maint/cron.php"

Where www-data is the same user that your web server is running as.
Locked