Looking at your config you have configured for 500 concurrent users but it will be increased based on your load. During startup if you want to support more, then increase the start servers value the default is 3 i guess. As for the mpm you can only load one at any point in time.
Anyone please correct me or add more details if required. On Dec 9, 2019, at 12:44 AM, Jayaram Ponnusamy <jayaram.ponnusamy@xxxxxxxxx> wrote:
Thanks for your Valuable Comments:
These configuration made by some consultant. We are in the situation to correct all the things to make it for high availability.
we are in the process of upgrading the apache to 2.4.25 with mod_jk/ 1.2.42. And Event MPM instead of Prefork.
Please let me know whether we need to use worker MPM along with EVENT MPM [or] Only Event MPM is fine? Based on your suggestion if we use below configuration for Event MPM then how many concurrent users can access the site? On Tomcat Servers We have 16GB RAM with 8CPU [Two Nodes]
# event MPM
<IfModule event.c>
StartServers 1
ServerLimit 7
MinSpareThreads 250
MaxSpareThreads 2500
ThreadsPerChild 500
ThreadLimit 500
MaxRequestWorkers 3500
MaxConnectionsPerChild 0
</IfModule>
# Tomcat Configuration
<Connector port="9090" protocol="HTTP/1.1" redirectPort="8443" URIEncoding="UTF-8" emptySessionPath="true" maxThreads="600" minSpareThreads="10" connectionTimeout="-1" />
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8" maxThreads="600" minSpareThreads="100" connectionTimeout="20000" acceptCount="2000" />
# Tomcat Configuration
-Xms2048M -Xmx6144M -XX:PermSize=1024m -XX:MaxPermSize=2048m
As a side note there are also many wrong choices regarding configuration.
Using deprecated 2.2.x directives like Order, Allow,Deny,Satisfy .
Using this is very wrong:
<Directory /> <--- this is the / in your filesystem, not the documentroot
Options FollowSymLinks
AllowOverride All <-- always to none
Require all granted <-- set to denied always.
</Directory>
Also consider like suggested earlier to move to event mpm instead of prefork.
Something mode detailed like:
StartServers 1
ServerLimit 7
MinSpareThreads 250
MaxSpareThreads 2500
ThreadsPerChild 500
ThreadLimit 500
MaxRequestWorkers 3500
MaxConnectionsPerChild 0 <-- set this to 0 unless you have a faulty
third party module which may have leaks.
And also monitor your backend is set according to this figures or
capable of dealing with them. It is of no use to configure httpd with
high numbers if your backend is can't cope with the load.
El jue., 5 dic. 2019 a las 15:32, Anil Kumar P (<naeduani@xxxxxxxxx>) escribió:
>
> A quick look at your config tells me you are using prefork mpm instead you should be using event mpm which provides better concurrent access boost. Please look at the apache mpm documentation for more details.
>
> Thanks,
> Anil
>
> On Dec 5, 2019, at 2:13 AM, Jayaram Ponnusamy <jayaram.ponnusamy@xxxxxxxxx> wrote:
>
>
> Hello,
> We are using apache 2.2.21 on RHEL6.9 and in Backend we are using Tomcat AppServer with JavaBased CMS.
> Our Server Architecture is (F5 [For Load Balance] -> Apache WebServer [For Redirection & URL Mapping] -> Tomcat AppServer [Running a Java Based CMS]).
>
> We are using Apache to connect Tomcat by MOD_JK and mapping the URL (Attached VirtualHost.conf), and No applications/code are running on WebServers.
>
> 1. Two WebServers (4 CPU & 8GB RAM on Each Servers)
> 2. Two TomcatServers (8 CPU & 16GB RAM on Each Servers )
>
> PROBLEM:
> When the Child Process count is reached / crossed 200 like below then site is not accessible when the child processes reached 300 or More than site crashed and then we bring the site back by restarting Apache.
> When the Child Processes reaching 200 during the time Google Analytics shows the ACTIVE/CONCURRENT Users are 140-160. We have two Apache & Tomcat Servers with Load-balancing but its unable to serve more than 150 concurrent users. Kindly please check my configuration and help to allow at-least 500 concurrent users.
>
> CONFIGURATION:
> httpd.conf
> <IfModule prefork.c>
> StartServers 80
> ServerLimit 3500
> MaxClients 3500
> MaxRequestsPerChild 0
> </IfModule>
>
> Tomcat:
> <Connector port="9090" protocol="HTTP/1.1" redirectPort="8443" URIEncoding="UTF-8" emptySessionPath="true" maxThreads="600" minSpareThreads="10" connectionTimeout="-1" />
> <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8" maxThreads="600" minSpareThreads="100" connectionTimeout="20000" acceptCount="2000" />
>
> http_error.log:
> [Thu Dec 05 11:05:13 2019] [info] [client 0.0.0.0] (32)Broken pipe: core_output_filter: writing data to the network
> [Thu Dec 05 11:05:13 2019] [info] [client ::1] (32)Broken pipe: core_output_filter: writing data to the network
> [Thu Dec 05 11:06:47 2019] [error] [client 0.0.0.0] (70007)The timeout specified has expired: proxy: error reading status line from remote server stg.test.com
> [Thu Dec 05 11:06:47 2019] [error] [client 0.0.0.0] proxy: Error reading from remote server returned by /research
> [Thu Dec 05 11:06:47 2019] [info] [client 0.0.0.0] (32)Broken pipe: core_output_filter: writing data to the network
> [Thu Dec 05 11:06:49 2019] [info] [client ::1] (32)Broken pipe: core_output_filter: writing data to the network
> [Thu Dec 05 11:07:02 2019] [info] [client 0.0.0.0] (32)Broken pipe: core_output_filter: writing data to the network
>
> error_log
> [Wed Dec 04 14:24:24 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 0 idle, and 165 total children
> [Wed Dec 04 14:24:25 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 0 idle, and 197 total children
> [Wed Dec 04 14:24:26 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 0 idle, and 229 total children
> [Wed Dec 04 14:24:27 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 0 idle, and 261 total children
> [Wed Dec 04 14:24:28 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 0 idle, and 293 total children
> [Wed Dec 04 14:24:40 2019] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 8 children, there are 0 idle, and 324 total children
>
> --
>
> Thanks & Regards,
>
> Jayaram Ponnusamy
> <http_conf.txt>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
--
Daniel Ferradal
HTTPD Project
#httpd help at Freenode
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
-- Thanks & Regards, Jayaram Ponnusamy
Mobile: +974-5512-3315
|