View Full Version : How do i change HARD_SERVER_LIMIT - PLEASE HELP!


newbiedude85
04-17-2006, 11:27 PM
Hi guys,

Im trying to change the HARD_SERVER_LIMIT on my server but its not working.

I edit the following in "httpd.h"...

#ifndef HARD_SERVER_LIMIT
#ifdef WIN32
#define HARD_SERVER_LIMIT 512
#elif defined(NETWARE)
#define HARD_SERVER_LIMIT 1024
#else
#define HARD_SERVER_LIMIT 1024 <---- i change this to 2048 or what ever.
#endif
#endif

I save httpd.h and then recompile apache thru /scritps/easyapache

After doing all that.. the HARD_SERVER_LIMIT is still the same, it doesnt save my new value.

I dont know what to do now! :(

CAN SOMEONE PLEASSSE HELP ME!

Thank you in advance
newbiedude85

Steven
04-18-2006, 01:09 AM
You need to recompile apache for the changes to take effect.

newbiedude85
04-18-2006, 03:24 AM
doesnt running /scripts/easyapache mean that im recompiling apache????

how else do i recompile?

thank you steven :)

Steven
04-18-2006, 09:36 AM
easyapache already raises it to like 16k

newbiedude85
04-18-2006, 04:39 PM
when i try to increase maxclients above 1024, i get this msg:

WARNING: MaxClients of 2048 exceeds compile time limit of 1024 servers,
lowering MaxClients to 1024. To increase, please see the
HARD_SERVER_LIMIT define in src/include/httpd.h

thats why i edit the httpd.h file and increase HARD_SERVER_LIMIT from 1024 to 2048.

But after editing the HARD_SERVER_LIMIT to 2048 the value doesnt change, remains 1024. i didnt think it would be that hard :( arrghhh.

Please HELP!

Thank you

newbiedude85
04-19-2006, 06:06 AM
Can anyone PLEASE help... ive looked everywhere for a solution.. i cant find anything :(

What do i need to do in order to change HARD_SERVER_LIMIT...

Im desperate to get this resolved, there has to be someone that knows how to do this???

Please reply, thank you

Bilco105
04-19-2006, 06:50 AM
As steven said, you need to recompile apache for the change to take place. httpd.h is a make file, not a binary.

newbiedude85
04-19-2006, 07:32 AM
isnt running /scripts/easyapache mean that its recompiling apache???

how do i recompile apache????

Please reply, thank you

Bilco105
04-19-2006, 07:38 AM
easyapache will redownload the apache package and overwrite any changes you make.

newbiedude85
04-19-2006, 07:41 AM
ok.. i understand now, i thought that might be happening.

SO, how do i recompile apache so is has the new HARD_SERVER_LIMIT

thank you

newbiedude85
04-19-2006, 05:57 PM
No one knows how to recompile apache so that the new HARD_SERVER_LIMIT value i set takes affect????

How can i recompile apache to have the new HARD_SERVER_LIMIT, someone has to know??

please reply, thank you

newbiedude85
04-20-2006, 09:00 AM
can anyone please help with this???

someone has to know how to change HARD_SERVER_LIMIT and recompile apache?

If anyone knows please reply.. it would be much appreciated.

thank you

andren
04-20-2006, 12:04 PM
http://www.cpanel.net/docs.htm
http://httpd.apache.org/docs/

Read

Zenutech
04-20-2006, 02:04 PM
Of course we know how to compile apache from source. The problem is that if you have any "particular" settings pertaining to your install of apache, it may screw things up.

For example ./configure; make; make install;
will probably break things. Do you have SSL, etc? You should look at your the head of the log file created during the compilation of apache using easyapache. That should give you an indication of what you need to put after ./configure --things here.
For example, if your source files are located in /usr/local/src/apache-version-x
Then look at the file /usr/local/src/apache-version-x/config.status

Don't forget that if you have mod ssl, extra steps are necessary.

newbiedude85
04-20-2006, 06:09 PM
When i try ./configure i get this:

-bash: ./configure: No such file or directory

What now?? :(

Please reply

Thanks guys

Zenutech
04-20-2006, 07:01 PM
When i try ./configure i get this:

-bash: ./configure: No such file or directory

What now?? :(

Please reply

Thanks guys


I pretty much made it clear that you shouldn't run that command without any parametters. You should ask for 1-on-1 help or a real technician to do this for you.

Or like Andren said:
http://www.cpanel.net/docs.htm
http://httpd.apache.org/docs/

Read

newbiedude85
04-20-2006, 07:34 PM
k, well is anyone able to help me 1-on-1???

those docs arent too specific.

thanks

Bilco105
04-20-2006, 08:16 PM
When i try ./configure i get this:

-bash: ./configure: No such file or directory

What now?? :(

Please reply

Thanks guys
Logout of your server and hire an admin before you do any damage to your server.

reliableDerrick
05-05-2006, 09:12 PM
ive looked everywhere for a solution.. i cant find anything
I know the feeling.

can anyone please help with this???

someone has to know how to change HARD_SERVER_LIMIT and recompile apache?

If anyone knows please reply.. it would be much appreciated.

thank you
I ran into this problem today as well, here's what I did:

1) Rebuild apache from the WHM or easyapache, it should create a dir /home/cpapachebuild.

2) Go into /home/cpapachebuild/buildapache. Edit limit.patch, find the line that starts like this:

+#define HARD_SERVER_LIMIT

(note the plus symbol in front) and change the number following it to whatever you want the HARD_SERVER_LIMIT to be.

3) Run bs by typing, "./bs" select the Advanced option ("6) Advanced (Experts Only, At Your Own Risk)"). It'll bring up a little dialog screen with checkboxes just like the Apache Update part of the WHM, make sure to uncheck the "Skip apache build if up to date" option, and to check the "Raise HARD_SERVER_LIMIT" option. Exit the dialog and it should take care of itself from there.

HTH

newbiedude85
05-07-2006, 07:48 PM
YES! that worked. :peace:

Ive being trying to do this for so long

THANK YOU SO MUCH FOR YOUR HELP!!!!!!!!!!!!!!!:) :) :) :) :) :)