Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to configure an NGINX server that's sole purpose is to serve as many 10k JPEGs as it can. I have 16 GB RAM and 2 Intel Xeon E5506 processors, running CentOS.

I'm looking to configure this server in order to serve as many concurrent connections, each delivering a 10 kB JPEG image. Hence, the time of the connection would be very short.

Any ideas would be nice. Thanks.

share|improve this question
up vote 1 down vote accepted

For many small concurrent connections, all you should have to do is increase the worker pool size to improve the ability of nginx to handle all the concurrent connections without slowdown. There really isn't much other tuning to be done; nginx is wicked fast at handling static files.

share|improve this answer
what number of workers would be appropriate for many very small files? More than the number of CPU cores? – UpTheCreek Jan 16 '13 at 13:23
@UpTheCreek: One worker per core is usually enough; nginx uses non-blocking I/O extensively, so each worker will handle another request whenever the processing of one request blocks (on fetching from / writing to disk, reading/writing the network, etc). You won't need a huge number of cores/workers before your network link becomes the limiting factor rather than CPU usage or nginx workers. – womble Jan 17 '13 at 22:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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