title: NGINX Reverse Proxy : Many html status code 400 responses, why?
body: <p>We have recently implemented a nginx based reverse proxy.</p>
  
  <p>While, debugging our access logs, we are seeing quite a bit of status code 400 results.</p>
  
  <p>They look something like this:</p>
  
  <pre><code>[07/Sep/2011:05:49:04 -0700] - "400" 0 "-" "-" "-"
  </code></pre>
  
  <p>We have enabled debug error logging, and they usually correspond to something like this:</p>
  
  <pre><code>2011/09/07 05:09:28 [info] 5937#0: *30904 client closed prematurely connection while reading client request line
  </code></pre>
  
  <p>We have tried raising a number of the buffers, as mentioned by a few pages we were able to google up.</p>
  
  <p><a href="http://www.ruby-forum.com/topic/173362" rel="noreferrer">http://www.ruby-forum.com/topic/173362</a></p>
  
  <p>or</p>
  
  <p><a href="http://blog.craz8.com/articles/2009/06/17/nginx-400-bad-request-errors-due-to-cookies-and-what-to-do-about-them" rel="noreferrer">http://blog.craz8.com/articles/2009/06/17/nginx-400-bad-request-errors-due-to-cookies-and-what-to-do-about-them</a></p>
  
  <p>To no avail.</p>
  
  <p>Why is this happening?</p>
  
  <p>This is a strandard nginx reverse proxy -> apache backend server.</p>
  
  <p>Worth mentioning, the unique type of content on our site is fairly minimal. We have tested this using many browsers and are not personally receiving any of these 400 results.</p>
  
  <p>Thanks!</p>
  
  <hr>
  
  <p>Further urls detailing similar entries in their logs:</p>
  
  <p><a href="http://blog.rayfoo.info/2009/10/weird-web-server-access-log-entries" rel="noreferrer">http://blog.rayfoo.info/2009/10/weird-web-server-access-log-entries</a></p>