Nginx performance test

hi,

last week, I did a nginx performance test.
Yes, with no surprise, nginx is perfect.

First, I proxyed 15 web hosts after nginx, the cpu utilization and
disk
IO were a little high, this was cause by the file download and access
log,
after I closed the access log, and changed the download to
synchronization by
set proxy_max_temp_file_size to zero, nginx run with little CPU
consumption.

So I turned more web hosts after nginx, the disk IO became some high
again, this was caused by uploading, so I changed the
client_body_tmp_path
to a tmpfs,
and disk IO disappear, and the bottleneck was the memory capacity.

Finally with 50+ web host proxyed, the nginx host's CPU utilization 

is
about 30%, and the client_body_tmp_path occupied 4-6G, the peak
throughput
of each network
adater was 400-450M.

It is a good result. Thanks you, sysoev.


Best Regards,

peterxue

QQ:312200

e-mail:[email protected] [email protected]

Good!
One thing we must do is tuning. Your experience on temp files is useful
for me.

2010/1/29 yong xue [email protected]:

  So I turned more web hosts after nginx, the disk IO became some high

nginx mailing list
[email protected]
nginx Info Page


Ren Xiaolei

Is there a page about performance optimizations in the wiki? If not I
think
it would be useful to create one so this and other performance related
information can be collected there.

Regards,
Dennis

hi, sysoev,

for proxy, can nginx give an new option, for example

client_max_body_size_in_buffer, it will be served synchronously from
client
if client body size is greater than client_max_body_size_in_buffer ?

2010/1/30 Dennis J. [email protected]

Good!

First, I proxyed 15 web hosts after nginx, the cpu utilization and
and disk IO disappear, and the bottleneck was the memory capacity.
Best Regards,
[email protected]
[email protected]
nginx Info Page


Best Regards,

薛 勇

QQ:312200

e-mail:[email protected] [email protected]
MSN:[email protected] [email protected]

2010/1/30 yong xue [email protected]:

hi, sysoev,
for proxy, can nginx give an new option, for example
client_max_body_size_in_buffer, it will be served synchronously from
client
if client body size is greater than client_max_body_size_in_buffer ?

According to the current implementation, no easy way. ngx_proxy calls
the ngx_http_read_client_request_body function to do the content body
reading task for it, which always buffer the input request before
creating the request for the remote upstream server.

Even though technically speaking we can do that, but I’m afraid it
will make things even worse if the backend server blocks a thread or a
process on slow request processing (as in the Apache prefork mpm).

So I don’t think Igor S. will do that big refactoring for
something that often has little gain in real world :wink:

Cheers,
-agentzh

QQ 279005114 grin

Yes, I think so too.
I reviewed the code, and this is problem about design.

the current design is much clear.
Maybe Sysoev have some simple approach.

2010/2/1 agentzh [email protected]

reading task for it, which always buffer the input request before
-agentzh

QQ 279005114 grin


nginx mailing list
[email protected]
nginx Info Page


Best Regards,

QQ:312200

e-mail:[email protected] [email protected]
MSN:[email protected] [email protected]