Igor Sysoev is at
Wed Jan 31 00:00:42 MSK 2007

On Mon, 29 Jan 2007, [WINDOWS-1252] ?ime Ramov wrote:

> I installed nginx from Debian package and it came configured with
> worker_processes 1; and worker_connections 1024;
> Now, I was wondering (since on the english wiki it states that default
> value for worker_processes is 5), to which value to set this up in
> some common situations?
> For example, if I run one Django site via FastCGI, what value to put
> in worker_processes? And if I run two Django sites? Three Django
> sites? One Django site and a couple of static sites?

As a general rule you need the only worker with large number of
worker_connections, say 10,000 or 20,000.

However, if nginx does CPU-intensive work as SSL or gzipping and
you have 2 or more CPU, then you may set worker_processes to be equal
to CPU number.

Besides, if you serve many static files and the total size of the files
is bigger than memory, then you may increase worker_processes to
utilize a full disk bandwidth.

Igor Sysoev

More information about the nginx mailing list