Improve and speed up the performance of Apache in VestaCP

In this tutorial we will learn how to optimize the Apache server under VestaCP install.

For CentOS the conf file for Apache is /etc/httpd/httpd.conf. To edit open with

nano /etc/httpd/httpd.conf

Add at the end of httpd.conf

KeepAlive Off
<IfModule prefork.c>
   StartServers        12
   MinSpareServers     10
   MaxSpareServers     30
   ServerLimit         512
   MaxClients          256
   MaxRequestsPerChild 3000
</IfModule>

Now restart Apache server

service httpd restart

For Ubuntu/Debian systems edit Apache config with the following command

nano /etc/apache2/apache2.conf

Find/edit in apache2.conf

<IfModule mpm_prefork_module>
 StartServers        12
 MinSpareServers     10
 MaxSpareServers     30
 ServerLimit         512
 MaxClients          350
 MaxRequestsPerChild 3000
</IfModule>

After that restart Apache server

service apache2 restart

Leave a Reply

Your email address will not be published.


*