phpcronwordpress-themingcyber-panelopenlitespeed

WP Crontrol: There was a problem spawning a call to the WP-Cron system on your site


After upgrading my digitalocean server, Wp crontrol is throwing error "There was a problem spawning a call to the WP-Cron system on your site. This means WP-Cron events on your site may not work. The problem was: Unexpected HTTP response code: 500"

I checked online but not able to find solution.

Server : Cyberpanel Openlitespeed
PHP version: 7.4
Wordpress version :5.5.1

Even tried to reinstall wordpress and used define('DISABLE_WP_CRON', true). But no use,

Let me know how to fix wp crontrol error


Solution

  • If you want to create a real Cron job, first you need to disable WP Cron, so is not executed every time someone loads one of your pages. To disable it, open the wp-config.php file in your main WordPress folder and add the following line before the "/* That's all, stop editing! Happy blogging. */" line:

    define('DISABLE_WP_CRON', true);

    Add a Cron job entry through your web hosting control panel. You can set the job to run every 5 or 10 minutes. Please remember to replace yourdomain.com with your actual domain:

    wget -q -O - http://yourdomain.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1

    Each server has different ways of adding a Cron job, so if you are not sure how to do it you can ask your hosting provider to help you. You can check this short video if you are using