We run a high traffic PHP site. At the moment we're finding that one of the web servers (4 load balanced servers) is running out of memory at least once a day. At the moment we have MaxRequestsPerChild set to 0 so that the children are never restarted, but then each child can start to chew up memory if a memory intensive script is run. When too many children are using too much memory each then the server starts swapping and then it uses all available ram/swap (4GB RAM, 2GB swap). What level of MaxRequestsPerChild does everyone else run for their PHP sites?
I got Timeout 50 KeepAlive On MaxKeepAliveRequests 120 KeepAliveTimeout 10 StartServers 16 MinSpareServers 10 MaxSpareServers 20 MaxClients 125 MaxRequestsPerChild 5000
Most of it's on a vBulletin board. Probably gets less than your server. 19:10:41 up 76 days, 20:49, 1 user, load average: 2.22, 1.85, 2.43 125 processes: 119 sleeping, 4 running, 2 zombie, 0 stopped CPU states: cpu user nice system irq softirq iowait idle total 88.8% 0.0% 11.1% 0.0% 0.0% 0.0% 0.0% Mem: 2047380k av, 1979440k used, 67940k free, 0k shrd, 77708k buff 1367104k actv, 270436k in_d, 26800k in_c Swap: 2096472k av, 8484k used, 2087988k free 1191736k cached Code (markup):