We got stuck with this problem on our hosting account that hosts about a dozen Wordpress sites.
After checking our server logs, wp-cron.php appeared to be the culprit.
Wp-cron.php helps by doing some automated things like posting scheduled content, checking comments for spam, and emailing comment notifications. The problem is that wp-cron.php loads on every single page view, so this could be running hundreds, thousands, or millions of time each day, depending on your website traffic.
To stop wp-cron.php from running on every page visit, add this near the top of wp-config.php
define('DISABLE_WP_CRON', true);
To run wp-cro.php at your own chosen interval, create a cron job that runs every hour with the following line. If your site only receives one or two comments per day, the cron job could be run every 12 or 24 hours.
wget -O /dev/null http://www.example.com/wp-cron.php?doing_wp_cron
via: wp-cron.php – How To Stop It From Running Frequently
Bayard, Thank you so much. Added the line and the problem evaporated immediately!
ReplyDeleteGlad to hear this worked for you! It can be a very frustrating and timely problem. When it first happened on our web host, we didn't know what to do and it had crippled several of our websites. :(
Delete