• 흐림동두천 -1.3℃
  • 맑음강릉 3.3℃
  • 구름조금서울 -0.9℃
  • 흐림대전 -0.3℃
  • 흐림대구 3.4℃
  • 흐림울산 5.2℃
  • 구름많음광주 2.3℃
  • 구름많음부산 6.6℃
  • 구름많음고창 1.0℃
  • 흐림제주 8.0℃
  • 맑음강화 -1.7℃
  • 흐림보은 -0.5℃
  • 흐림금산 0.1℃
  • 흐림강진군 3.8℃
  • 구름많음경주시 4.5℃
  • 구름많음거제 6.8℃
기상청 제공

nginx 웹서버에서 파일 업로드시 "413 Request Entity Too Large" 오류 날 때

  • 등록 -0001.11.30 00:00:00

nginx 웹서버에서 파일 업로드시 "413 Request Entity Too Large" 오류 날 때

# nginx error
2010/05/31 14:58:09 [error] 6524#0: *31 client intended to send too large body: 5399571 bytes, client: {IP}, {hostname}, request: "POST /adm_common/ HTTP/1.1", host: "{hostname}", referrer:"{http://referrer}'

아래 설정에서 client_max_body_size 1m; 설정을 수정 후 nginx를 재시작 한다.

http {
  client_body_in_file_only off;
  client_body_buffer_size 16k;
  client_body_temp_path /var/tmp/nginx/client_temp 1 2
  client_body_timeout 60;
  client_header_buffer_size 1k;
  client_header_timeout 60;
  client_max_body_size 1m;