If your server starts getting more and more traffic you’ll need to lift up number of allowed Apache connections. This guide works only on cPanel/WHM powered servers.
The easy way
Log in at WHM and to go to Service Configuration > Apache Configuration > Global Configuration. In there find ServerLimit and MaxClients and set those to some nice value (eg. 1024 or 2048 depends how much memory you have). Save and that should be it.
The geek way
Edit of httpd.conf (usually located at /usr/local/apache/conf folder). It should look something like this (depending on your server specification):
StartServers 5 MinSpareServers 5 MaxSpareServers 10 ServerLimit 1024 MaxClients 1024 MaxRequestsPerChild 10000
Save, Distill settings, restart Apache:
/usr/local/cpanel/bin/apache_conf_distiller --update /scripts/rebuildhttpdconf /etc/init.d/httpd restart
Check
After you do something like this you simply MUST take a look at your Apache error_log file (usually located at /usr/local/apache/logs folder). If you see following line in Apache error_log:
** [warn] WARNING: Attempt to change ServerLimit ignored during restart
You should stop and run the Apache again since ServerLimit can’t be changed by restarting Apache. To do so execute following at SSH:
apachectl stop apachectl start
Can't download new apps to your phone because there isn't enough storage space? Lack of…
This issue started to appear on macOS 13 Ventura after recent Dropbox update. I would…
Since this morning (Feb 5th 2020) search just stopped working on my Windows 10 (version…
Many of you have run into a problem when you were working on some old…
After 10 years of running my main desktop computer on Windows 7 - time has…
I installed VestaCP for a clien on a new dedicated server running CentOS 7. Once…