After running cron.php and waiting several minutes the cron run fails with Error 500 Internal Server Error - Does anyone know how I can fix this?

Comments

aristeides’s picture

same issue here....

yan’s picture

There can be many reasons. In my case it was the number of items to index on each cron run. I lowered it and the error disappeared. Do so on admin/settings/search.

But I still don't know which setting causes this error.

dpearcefl’s picture

php is timing out (max_execution_time) because the reindex time is too long. Decreasing the number of items to index will overcome this issue. Or increasing the max_execution_time setting will help also.

If this issue is resolved, please set this issue to closed.

lily.yan’s picture

same issue here...., how to fix it? thanks a lot.

lelizondo’s picture

if you can, try running cron using drush

lily.yan’s picture

After running "sudo drush cron", I got the following:
PHP Fatal error: Call to undefined function views_build_view() in /var/www/html/../drupal-6.22/includes/common.inc(1696) : eval()'d code on line 6
Drush command terminated abnormally due to an unrecoverable error. [error]
Error: Call to undefined function views_build_view() in /var/www/html/../drupal-6.22/includes/common.inc(1696) : eval()'d code, line 6
WD cron: Cron run exceeded the time limit and was aborted.

lelizondo’s picture

Well, now you know that there is a problem with Views. Check for available updates on your modules.

Also, you can configure your php.ini to increase the max_execution_time. In ubuntu it would be something like /etc/php5/cli/php.ini

Status: Active » Closed (outdated)

Automatically closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.