I forgot to add.
Would it be more beneficial to have NGinx pass off the PHP requests to
Apache as it runs PHP as a module?
In my opinion tottaly no (although people sometimes make proxy setups to
pass the dynamic requests back to apache backend but handle the static
nginx - still its often because of some apaches features like php_flag
Although you can try to play arround with the apache MPM modules -
is still the common mechanism which means that for each request a new
process is forked/launched and after it finishes the child killed…
PHP childs in fastcgi mode live much longer (can be specified) and dont
consume cpu resources just on spawning also something like persistant
connections to DBs or other services work much better instead of dieing
time with apache.
Well initially it seems something wrong with your setup/performance
results - at first getting only 1.5k req/sec for static content is
low …You should be able to get 15-30k and even more requests per second
least with ‘ab’ testing one file)… Of course php is much slower but
simple ‘hello world’ on a single box should be able to manage up to 2k
So either the box is kinda weak or you havent tweaked some system
like max open files or tcp params.