nginx 客户端请求大小限制
2016-01-23 16:29
676 查看
SYNTAX: client_max_body_size size; DEFAULT: client_max_body_size 1m; CONTEXT: http, server, location Sets the maximum allowed size of the client request body, specified in the “Content-Length” request header field. If the size in a request exceeds the configured value, the 413 (Request Entity Too Large) error is returned to the client. Please be aware that browsers cannot correctly display this error. Setting size to 0 disables checking of client request body size.
今天上传图片,发现老出错,也没超过程序所设的大小限制,为啥就不行。后来突然想起来以前用nginx接tomcat也出现过,后来证明是nginx默认设置导致的。
在server节点下增加 client_max_body_size 4m; 搞定。nginx 默认限制是1m
相关文章推荐
- nginx+php-fpm的socket配置小结
- SpringMVC+Mybatis框架整合源码SSM Nginx,Hudson
- nginx+ffmpeg搭建rtmp转播rtsp流的flash服务器
- nginx 多网址多端口多项目精简配置-1
- Nginx负载均衡配置实例
- Nginx性能优化
- nginx的部署初级(中)
- IE浏览器在地址栏针对param直接输入中文导致乱码的解决方案
- nginx 配置
- 系统linux/redhat6.5 zabbix 2.47监控nginx1.8.0 (上)
- 系统linux/redhat6.5 zabbix 2.47监控nginx1.8.0 (下)
- nginx
- centos6.5下安装nginx1.8.0
- centos7编译安装nginx1.8
- [转]Linux环境下安装Nginx+Pcre+zlib+OpenSSL
- [转]nginx[+spawn-fcgi]+flup+webpy服务搭建
- Nginx负载均衡:分布式/热备Web Server的搭建
- nginx
- 给nginx打nginx_upstream_check_module补丁
- 解决nginx下载大文件出现文件损坏,文件大小不一致