cron.php and problems in database-mysql.inc.php

Submitted by Anders on 2009-10-09

I am trying to get the crontab working on my server.

Runnig cron gives me the following:

[2009-10-09 12:30:42, unknown]
Cron task started
Cron task completed successfully

[2009-10-09 12:33:31, unknown]
Cron task started
Sent 1 of 1 notification(s)
Cron task completed successfully

[2009-10-09 12:37:46, unknown]
Cron task started
Cron task completed successfully

While the error log gives me:

[2009-10-09 10:44:50, 79.138.154.156.bredband.tre.se]
WARNING in /home/u/u6217857/www/webbissue/include/database-mysql.inc.php(29):
Missing argument 3 for wi_db_escape_arg()

[2009-10-09 10:47:40, unknown]
WARNING in /home/u/u6217857/www/webbissue/include/database-mysql.inc.php(29):
Missing argument 3 for wi_db_escape_arg()

[2009-10-09 12:33:31, unknown]
WARNING in /home/u/u6217857/www/webbissue/include/database-mysql.inc.php(29):
Missing argument 3 for wi_db_escape_arg()

The cron is setup according to this:
0 * * * * php cron.php

When running php cron.php the result is the following:

www12:~/www/webbissue$ php cron.php
X-Powered-By: PHP/4.4.8
Content-type: text/html



Note the jibberish at the end.
But still i need to activate the cron.php manually to get mail sent out.

Hello,

The warning is a bug in the server's code, but it doesn't affect sending emails. Thank for spotting it, I'll fix it.

The "jibberish" is the UTF-8 BOM. WebIssues code doesn't have a BOM anywhere; my guess is that is was added when you edited some file (probably the configuration file). It also doesn't affect sending emails but it could break downloading binary attachments so check it out.

If the cron.php script sends emails when run manually, the problem must be in the crontab itself. Do you have correct paths to php and crop.php? Is the cron job run with appropriate permissions?

I would recommend to check the system log of cron itself. Also are there any entries for 12:00, 13:00 etc. (when the script should be run by cron) in the WebIssues cron log?

Regards,
Michał