Nginx – Rails, passenger nginx and upload connection resets

nginxphusion-passengerruby-on-railstimeout

Uploading a largish (2mb) file to nginx/passenger results in my connection being reset. I have tried editing configuration fields of nginx but apparently these are superseded by passenger's config.

I receive the error "Error 101 (net::ERR_CONNECTION_RESET): Unknown error."

Around the net information seems far from definitive so how can I resolve this?

Best Answer

Ok so setting the following in the server block of nginx.conf fixed this:

client_max_body_size 4m;
Related Topic