• I get this error in my error log

    [Fri Sep 20 10:43:26 2013] [warn] [client 216.70.122.75] mod_fcgid: read data timeout in 40 seconds
    [Fri Sep 20 10:43:26 2013] [error] [client 216.70.122.75] Premature end of script headers: wp-cron.php

    Any won know how i can fix this?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hello,

    Looks like your execution timeout is configured to 40 seconds, then your wp-cron event had no time to be executed completely — the process was killed by server.

    I can suggest you to replace wp-cron with a real cron job.

    Steps:

    1) Add to wp-config.php:

    define('DISABLE_WP_CRON', 'true');

    2) If you want your cron job being executed daily:

    # vi /etc/cron.d/wpcron

    0 1 * * * www-data wget -O /dev/null -o /dev/null https://www.domain.com/wp-cron.php

    3) Done ??

    Regards

    Thread Starter tokar86a

    (@tokar86a)

    So can you explane little more about this fix?

    This fix will disable wp-cron in your WordPress install and enable a cron job in your server. Once cron have no timeout to run, your problem will be solved.

    Also you may want to review your WordPress scheduled events, since they are taking more than 40 seconds to execute completely.

    Thread Starter tokar86a

    (@tokar86a)

    How can i check this? And can i check what type of scheduled events that make this error?

    You can use the plugin Debug Bar Cron to get informations about your WordPress scheduled events.

    https://www.ads-software.com/plugins/debug-bar-cron/

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘read data timeout in 40 seconds’ is closed to new replies.