Support

Home Forums Event Espresso Premium Our EE4 sites keeps going down

Our EE4 sites keeps going down

Posted: June 28, 2017 at 10:47 am

Viewing 3 reply threads


Elizabeth

June 28, 2017 at 10:47 am

We have a VPS server and have 15 EE4 sites running. Our server keeps crashing because of the following: EE is the main plugin on all of the sites.

I am seeing that a lot of WordPress faux-cron jobs are being run by your sites. By default, every time someone loads your site, the wp-cron.php file is run. Most of the time, this isn’t harmful. But if your wp-cron.php file is set to do some intense tasks, this can drive up resource usage. Thus, you should convert the wp-cron.php task into a Linux cron job. This is actually easier than you think. You simply need to have the Linux cron job utilize wget once an hour on the file via your URL. So let us say you URL is http://example.com . Then the URL need to call would be http://example.com/wp-cron.php?doing_wp_cron . Since you don’t want a million emails letting you know it run, you want to add 2>&1 at the end. Then we just want to call that via wget quietly. Since we only want it running once per hour, the coding for the cron job becomes:
0 * * * * /usr/bin/wget -q -O – http://example.com/wp-cron.php?doing_wp_cron 2>&1
Add that as a Linux cron job via the cPanel cron job tool, then add the following to your wp-config.php file:
define( ‘DISABLE_WP_CRON’, true );
This will ensure the tasks still run without overdoing it. This reduces the resource usage overhead. This makes the site load faster without harming the server.

3) The 503 errors are a function of the process limits being reached due to stacked requests. If the sites are optimized enough that php processes open/close quickly, that may alleviate the 503 temporary unavailable error messages.


Josh

  • Support Staff

June 28, 2017 at 11:16 am

Hi Dorian,

Do you have any basis for your assumption that the website crashes because of Event Espresso? The message (from your host maybe) indicate issues with crons and stacked request, and they gave you some solid advice on how to address those issues. You may need more specific information on how to do make those adjustments, and that may be able to give you more specifics.


Elizabeth

June 28, 2017 at 11:24 am

Was seeing if you have heard of this before with too many EE sites running on the same server.

Does EE not use CRON?


Josh

  • Support Staff

June 28, 2017 at 11:36 am

Event Espresso does use wp_cron (and WordPress core does too, and other WP plugins as well). If you do go that route where you deactivate wp_cron you will need to set up a replacement for it.

Viewing 3 reply threads

The support post ‘Our EE4 sites keeps going down’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso