For a few days we were struggling with a problem on one of our web servers. All websites/domains kept crashing at the same time. We therefore went in search of the Plesk problem and then determined the cause. A look at Plesk's error_logs provided clarity: The MaxRequestWorkers variable is set too low (150) and if there is a lot of traffic, the operation is then stopped. Relatively annoying if you run a few websites and then the pages are no longer accessible. We went looking for problems, googled and looked at logs. Then we got the error message:

The problem (the error message)

The Apache web server periodically fails with the following error message in its error log:

server reached MaxRequestWorkers setting, consider raising the MaxRequestWorkers setting

The error logs are visible here:

  • CentOS/RHEL-based distributions: /var/log/httpd/error_log
  • Debian/Ubuntu-based distributions: /var/log/apache2/error.log

Explanation for the failures: If the MaxRequestWorkers variable is set too low, the server practically overhauls itself and can no longer process queries. Plesk simply set this variable too low. That's pretty stupid and it's also difficult to adjust the variable (as a layman). We hope that Plesk will fix this variable or make it customizable in an update. But we will still show you how to adjust or change them.

Fix: Increase variable or switch to nginx

We could not change the variable (for permission reasons). So we decided to switch from Apache to nginx:

Switch Apache to Nginx via Plesk

You can increase the value of MaxRequestWorkers, but be sure to increase the ServerLimit as well. Just set it to 16.

Here example settings:


StartServers 2
MinSpareThreads 25
MaxSpareThreads 75
Thread limit 64
ThreadsPerChild 25
MaxRequestWorkers 400
MaxConnectionsPerChild 0
Server limit 16

 

Questions? Just leave a comment. We're happy to try to help with Plesk and server crashes if needed.

 

Wasn't that your problem?

Troubleshooting Plesk isn't always easy. But start with the server logs. Login to Plesk backend and check error logs. Otherwise simply log in as root via SSH/FTP and go to the var/logs directory. You should be able to see daily error logs there.

Published On: February 7th, 2022 / Categories: Technik im Web / Tags: /

Leave A Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

The latest newsletters

Sign up to stay informed.

[contact-form-7 id=”1362″ /]

By submitting the form, you agree to our privacy policy.