I am willing to shift my application server from default prefork MPM module to worker MPM. My server configuration is
OS - CentOS 6 Apache - Apache/2.2.15 (Unix) PHP 5.4.35 (fpm-fcgi) CPU - 4 RAM - 8 GB
I am only considering 60% RAM available i.e. 5GB. My apache process takes average 6 MB and php-fpm takes 25 MB.So based on RAM consumption I have following configurations
Worker Configuration:
Timeout 60 KeepAlive On MaxKeepAliveRequests 100 KeepAliveTimeout 15
ServerLimit 16 StartServers 4 MaxClients 400 MinSpareThreads 25 MaxSpareThreads 75 ThreadsPerChild 25 MaxRequestsPerChild 0
PHP-FPM Configuration
pm.max_children = 100 pm.start_servers = 10 pm.min_spare_servers = 5 pm.max_spare_servers = 15 pm.max_requests = 500
emergency_restart_threshold = 10 emergency_restart_interval = 1m process_control_timeout = 5s
When I add this machine to clusture the load average goes high upto 100 and behaves very strange.
Any help or suggestion would be greatly appreciated if I am doing any wrong configuration.
Thanks