Apache: configure prefork in a per-virtualhost way

apache-2.2mpm-preforkpreforkvirtualhost

I host different sites on the same Linux server (an AWS EC2 instance), I would like to give these sites different limits via a virtualhost specific configuration. Is this possible?

Best Answer

No. If you consult the documentation for the prefork MPM (2.4 docs here), you will see that the "context" of all configuration directives have a scope of "server config". This means that they cannot be defined at a VirtualHost level.

MPMs are not the best place to try and implement resource constraints for anything other than the main process itself. You should probably look into modules that are specialized toward throttling virtual hosts.

Related Topic