User Tools

Site Tools


max_clients

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
max_clients [2015/04/02 06:35] luke7858max_clients [2024/05/23 07:26] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +**Quick note**: apache 2.4 - Max Clients is now named MaxRequestWorkers
 +\\
 +You can find the apache values in:
 +\\
 +/etc/httpd/conf/httpd.conf
 +\\
 +OR
 +\\
 +/etc/httpd/conf.modules.d/00-mpm.conf
 +\\
 +If no value has been set then chances are the default of 256 is set.  (Tip: run apache2buddy to find out the value if you are having trouble working it out)
 +\\
 +=== CentOS ===
 +Best command to find the current apache processes is:
 +<sxh bash>
 +pstree | grep httpd
 +</sxh>
 +Alternative: 
 +<sxh bash>
 +ps afx | grep httpd | wc
 +</sxh>
 +\\
 +\\
 +What is the number of max connection the server has been configured for?
 +<sxh bash>
 +grep -i maxclients /etc/httpd/conf/httpd.conf
 +</sxh>
 +\\
 +\\
 +When did apache hit max clients?
 +==Centos==
 +<sxh bash>
 +grep -i maxclients /var/log/httpd/error_log
 +</sxh>
 +Has it happened before? zgrep checks through ALL of the compresses and uncompressed logs, the * at the end of error represents all of the logrotated files:
 +<sxh bash>
 +zgrep -i maxclients /var/log/httpd/error_log*
 +</sxh>
 +What are the currently configured max connections?
 +<sxh bash>
 +grep -i maxc /etc/httpd/conf/httpd.conf | head -3
 +</sxh>
 +Ubuntu could have max clients configured in a number of different places, first place to look is:
 +<sxh bash>
 +grep -i maxc /etc/apache2/apache2.conf | head -4
 +</sxh>
 +or
 +<sxh bash>
 +grep -i maxc /etc/apache2/mods-enabled/mpm_prefork.conf
 +</sxh>
 +Current connections:
 +<sxh bash>
 +pstree | grep httpd
 +</sxh>
 +\\
 +== Ubuntu ==
 +<sxh bash>
 +grep -i maxclients /var/log/apache2/error_log
 +</sxh>
 +Has it happened before?
 +<sxh bash>
 +zgrep -i maxclients /var/log/apache2/error_log*
 +</sxh>
 +Current connections:
 +<sxh bash>
 +pstree | grep apache
 +</sxh>
 +\\
 +\\
 ==== CentOS==== ==== CentOS====
  
max_clients.1427956555.txt.gz · Last modified: 2024/05/23 07:26 (external edit)

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki