Problem with connection rate limiting and backend redirects

Daniel Collis-puro lists at ruby-forum.com
Fri Oct 23 22:39:46 MSD 2009


I love nginx! We're using as a caching front-end proxy in front of our
wordpress mu at http://blogs.law.harvard.edu/, and it's enabled us to
handle MUCH more traffic on less hardware. Roxors!

Anyway - I discovered an issue with connection rate limiting and backend
redirects.

When the backend issues a redirect for a page containing a large amount
of html / xml content, the content of the subsequent 200 status request
may get truncated by nginx. I had fairly aggressive rules to the effect
of:

limit_req_zone  $binary_remote_addr  zone=pagereqzone:10m   rate=3r/s;
limit_req zone=pagereqzone burst=8;

I seemed that increasing the burst to 16 fixed the issue, but this was
the last place I looked because nothing was getting thrown into the
error logs. I also didn't expect backend responses to get impacted by
rate limiting.

We're using 0.7.62 in front of apache, running wordpress 2.8.4a. Apache
and wordpress do no caching any more - nginx handles it all. At some
point I plan to document how this works, because the caching works
(mostly) perfectly for logged in / non-logged in users, rss feeds,
files, etc. It's great.

Thoughts? Pointers? Places to look?

--DJCP
-- 
Posted via http://www.ruby-forum.com/.





More information about the nginx mailing list