trhosting.net

Well-Known Member
Mar 7, 2006
152
1
168
Turkey
Hello,

I am having trouble with apache MaxClients limit.
I want to increase it and set it to 800 from httpd-mpm.conf file but on apache status page it doesn't exeed 256. It always shown as "256 requests currently being processed, 0 idle workers". It seems a server limit or compile time limit but i don't know how to change it.

How can i increase it?

My httpd-mpm.conf files prefork section:
<IfModule mpm_prefork_module>
StartServers 50
MinSpareServers 50
MaxSpareServers 100
MaxClients 800
MaxRequestsPerChild 0
</IfModule>
 

felosi

Active Member
Aug 27, 2006
39
0
156
Its something with the apache compile. I never figured out how to raise it with 2 and 2.2 . But you can raise it in 1.3 in the easyapache, if that is not enough you can edit the httpd.h file I think and add the line for hard limit
 

trhosting.net

Well-Known Member
Mar 7, 2006
152
1
168
Turkey
The limit is hardcoded to apache 2.x and it is not possible to change it from config files.
This is the information about this that i can find. I didn't find any way to change it.

I have downgraded to apache 1.3.41. The hardcoded limit automatically increased to 2048. Then i set the MaxClients variable.

This is a big problem with the apache 2.x config.
I have created a bug report for this that you can poll.
http://bugzilla.cpanel.net/show_bug.cgi?id=7853
 

alex318

Member
Jun 4, 2005
11
0
151
Just insert ServerLimit directive before MaxClients will help.

For example:

ServerLimit 512

StartServers 32
MinSpareServers 5
MaxSpareServers 20
MaxClients 512
MaxRequestsPerChild 1000

Don't forget to distill your apache configuration for the next cpanel update.
 
Last edited:

charliesxia

Member
Aug 3, 2006
18
1
153
seems useless
i always get
ServerLimit directive before MaxClients
128 requests currently being processed:confused:, 0 idle workers
Just insert ServerLimit directive before MaxClients will help.

For example:

ServerLimit 512

StartServers 32
MinSpareServers 5
MaxSpareServers 20
MaxClients 512
MaxRequestsPerChild 1000

Don't forget to distill your apache configuration for the next cpanel update.
 

trhosting.net

Well-Known Member
Mar 7, 2006
152
1
168
Turkey
ServerLimit works if you set it from WHM.
But not works if you set it from config files.

You can set it from Apache Configuration -> Include Editor

Write your configuration to Pre Main Include field.
This works