Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I trying to build a rails application to upload large video file which will be hosted at server it works fine with smaller file but gives 413 Request entity too large error for large file (around 30MB). I change my nginx configuration file and increased client_max_body_size to 4G. Still it does not work.

Can anybody help me ?

share|improve this question
Did you restart nginx after changing your configuration? – Adrian Heine Nov 22 '12 at 12:46
What's in the error log? – VBart Nov 22 '12 at 17:57

I would suggest looking at all the different places where client_max_body_size could be set. For example, in the server and location sections - anywhere that Nginx is pulling configuration files from.

To find any occurrences of client_max_body_size, try the following unix command from the nginx directory:

sudo grep -R 'client_max_body_size' ./*
share|improve this answer

Your Answer


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.