I have a webserver running on an IBM blade, hardware configuration is:

Intel Xeon E5506 x 2 (8 cores)
12G mem
SAS disk raid1

I use this box as a dedicated webserver serving a dozen of simple php scripts. They do mysql queries and return result codes. There is no pictures, no static files. The mysql server runs locally. Currently I'm using apache2. The purpose is to serve as many clients as I can using this server. I'm wondering what is the best value for the following configuration parameters:


I'm also thinking of switching to nginx + php fastcgi. If I use this type of setup, how should I configure:

how many fastcgi processes
how many worker_processes

Please give your recommends based on your experience. Thanks!


It's impossible for anyone to provide an answer on this.

The purpose is to serve as many clients as I can using this server

WTF? for most of us the problem is making the system accommodate the demand - but this statement implies that you can manipulate the demand to accommodate the capacity?????

The only way you're going to get an answer to this is by testing it out for yourself. There are lots of tools for stress testing a webserver - Apache should come with 'ab' out of the box. But for preference you should run the clients on other boxes.

nginx should be a bit faster than apache. But do apply the standard HTTP tuning stuff (i.e. cache sensibly, use compression, a PHP opcode cache). If you can generate sensible workloads, do try run mysqltuner.

I'm not overly familiar with nginx, but for apache you should be setting MaxRequests to something sensible (say 5000). Your settings for spareservers will depend on the profile of the workload - does it change a lot or is it fairly constant?

Do enable slow query logging in mysql with a low threshiold and setup your apache to log %D.

  • Sorry but my purpose of this question is to get a common sense on what I can expect from this type of setup, then I can use ab or other test tools to stress load the server and make sure everything is ok. If I don't know what is the server's potential, how should i understand any test results. – Long Cheng Apr 11 '11 at 10:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.