Currently I am using Apache in a server with WHM/Cpanel and I'm currently using Prefork MPM with Mod Ruid2 to process PHP pages. While the setup allows it to run very fast, I'm limited to processing about 80 HTTP requests simultaneously since the machine has 8 GB ram. I think google isn't happy enough with that. I feel to make my websites and the server keep up with the times, I need to increase the maximum number of requests that can be served at once. So I thought of using FastCGI with PHP-FPM. I then began playing with my httpd.conf (on my own private test server of course) to see how to configure it for multiple users. Each user has its own domain on the server.For now I am showing my configuration for one user. His website is 127.0.0.1:81. /daemon is a folder accessible by user daemon.This is my php fpm config file that I apply when I execute php-fpm daemon.[global]pid = /daemon/x.piddaemonize = yes[www]user = daemongroup = daemonlisten = /daemon/x.socklisten.owner=daemonlisten.group=daemonlisten.backlog = 65534pm = staticpm.max_children = 10pm.max_requests = 10000pm.status_path = /STATrequest_terminate_timeout = 100sclear_env = nosecurity.limit_extensions=.phpThis is the snippet in my httpd.conf file<virtualhost 127.0.0.1:81>AddHandler php51 .php Action php51 /php51Alias /php51 /daemon/1FastCgiExternalServer /daemon/1 -socket /daemon/x.sock -pass-header Authorization -idle-timeout 120 -flush<Directory /daemon>Order allow,denyAllow from all</Directory>ServerName 127.0.0.1</virtualhost>What I want to do is try to compress these lines so that when I go do a multi-user setup, the amount of typing I have to do will be less.Because I felt theres some redundancy, I replaced:Alias /php51 /daemon/1FastCgiExternalServer /daemon/1 -socket /daemon/x.sock -pass-header Authorization -idle-timeout 120 -flushwith:# Alias /php51 /daemon/1FastCgiExternalServer /php51 -socket /daemon/x.sock -pass-header Authorization -idle-timeout 120 -flushand restarted apache and attempted to access a php file and I'm told the file was not found, yet I never modified the file itself and I used the same URL in both tests.Also, in the apache log, I received:File does not exist: /usr/local/apache2/htdocs/php51When I removed:<Directory /daemon>Order allow,denyAllow from all</Directory>I received permission denied.I never had to add all this configuration when using prefork with ruid2.Is there a more minimal configuration I can use other than having to define an action, alias on top of defining an external server? I want to increase the number of connections apache can handle without eating all the memory or even eating the CPU and I want to be able to use PHP as well.
Speed of prefork+ruid2 with more connections on limited memory
php;apache;apache2;performance;connections