Current time: 12-26-2024, 11:50 AM Hello There, Guest! (LoginRegister)


Post Reply 
Default fcgid configuration is wrong...
Author Message
kilburn Offline
Development Team
*****
Dev Team

Posts: 2,182
Joined: Feb 2007
Reputation: 34
Post: #7
RE: Default fcgid configuration is wrong...
Quote:Can you describe your servers configuration?
CPU, RAM, domains count in panel?

I can (Core i5, 8Gb, 250 domains), but this is not useful to anyone. You have to play with the parameters and see by yourself which are the sane values for your own server.

Basically, the most important aspect of setting up mod_fcgid is to keep the memory usage at bay. Therefore, what I would do is repeatedly trying to increase the maximum number of processes and testing how well the server handles it. "Receipt":
Code:
1. Set "FcgidMaxProcessesPerClass" to #X#, a number of processes that you think your server is going to handle well.
2. From another machine, run 'ab -c #X# -n1000 "http://domain.in/your/server/"'
3. Monitor the server, making sure that #X# php5-cgi processes are spawned for the domain under stress and that it doesn't eat all your memory.
4. The objective is to have approximately 200-300 free Mb of memory when all the processes have spawned.
5. If you have more free memory, go back to 1 with an increased #X#
6. If you have less free memory, go back to 1 with a decreased #X#
7. Once you reach this "sweet spot" (200-300 free Mb under load), you know the *total* maximum of php5-cgi processes that your server can handle.
8. Set "FcgidMaxProcessesPerClass" to a number lower than that, so no single website can completely exhaust the server.
9. Set "FcgidMaxProcesses" to #X#, so that you don't eat up all the ram when there's more than one website under heavy load.
09-13-2011 07:54 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Default fcgid configuration is wrong... - Nuxwin - 10-19-2010, 06:12 PM
RE: Default fcgid configuration is wrong... - kilburn - 09-13-2011 07:54 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)