Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have an nginx 1.0.6 server set up in front of a Ruby on Rails application using Passenger.

I have noticed some strange behaviour when making POST requests. Consider this little code snippet:

http://pastie.org/2803941

I make two identical POST request - the only difference is, that in the last one, the actual post data has 1 more character than the Content-Length specifies (I've inserted a trailing blank).

The first request is responded to fine, but the last one just hangs until my client times out.

Is there any way to configure nginx, so that it can accept both requests? I have no way of making the client behave correctly.

UPDATE: I have just tried to make the same test against another virtual host on the same nginx server, where the backend is PHP. Here it works correctly.

So it is not nginx but Passenger, that is the culprit - still if anyone has had the same problem, please let me know.

/ Carsten

share|improve this question

1 Answer 1

Have you tried to increase the value of: client_max_body_size ?

share|improve this answer
    
No because it is default 1 megabyte, and I am only sending 10 bytes –  Carsten Gehling Nov 3 '11 at 12:17

Your Answer

 
discard

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.