I've migrated to a new faster server. The old server was handling the site fine after some serious tweaks, the new server though with an extra 2gigs of ram (4 total) is very slow to respond to requests after 2 days of various tweaks. I'm running PHP in FastCGI mode and the error logs are filled with the following errors:
mod_fcgid: can't apply process slot for /var/www/cgi-bin/cgi_wrapper/cgi_wrapper
and a few
mod_fcgid: read data timeout in 200 seconds
CPU hovers at 40% with around ~80 processes spawned, site is super slow, I tried tweaking fcgid.conf but to no avail:
LoadModule fcgid_module modules/mod_fcgid.so
<IfModule mod_fcgid.c>
<IfModule !mod_fastcgi.c>
AddHandler fcgid-script fcg fcgi fpl
</IfModule>
FcgidIPCDir /var/run/mod_fcgid/sock
FcgidProcessTableFile /var/run/mod_fcgid/fcgid_shm
FcgidIdleTimeout 200
FcgidProcessLifeTime 1000
FcgidMaxProcesses 5
FcgidMaxProcessesPerClass 10
FcgidMinProcessesPerClass 0
FcgidConnectTimeout 8
FcgidIOTimeout 200
FcgidInitialEnv RAILS_ENV production
FcgidIdleScanInterval 20
FcgidMaxRequestsPerProcess 500
FcgidBusyTimeout 300
</IfModule>
Any suggestions?
EDIT: top result
Tasks: 94 total, 1 running, 93 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.1%us, 0.0%sy, 0.0%ni, 99.9%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 5379200k total, 1765840k used, 3613360k free, 0k buffers
Swap: 0k total, 0k used, 0k free, 0k cached
93 sleeping????