nginx阻挡flv视频文件上传解决方案
问题:nginx阻挡flv上传
上传flv视遇到出现IO错误,尝试使用ip直接访问页面上传,可以成功
解决方法:
一.重新编译nginx,添加upload模块
1.拷贝nginx-upload-module-master
2../configure--add-module=/www/nginx-1.8.0/nginx-upload-module-master--add-module=/www/nginx-1.8.0/nginx_ajp_module-master/--with-pcre=/www/nginx-1.8.0/pcre-8.33--with-zlib=/www/nginx-1.8.0/zlib-1.2.8--with-http_sub_module
3.Make
4.Makeinstall
二.修改nginx.conf:
upload_pass/web/Resource/jsp/fileUp.jsp?allowType=*.flv&fileTypes=*.flv&path=_netpat_temp;
upload_cleanup400404499500-505;
upload_store/usr/local/platform/file/upload/1;
upload_store_accessuser:r;
upload_limit_rate128k;
upload_pass_argson;
Q:clientintendedtosendtoolargebody:12061790bytes,
A:打开nginx.conf并在http{}字段里添加
client_max_body_size64M;#多少M根据实际情况填写