加大对Nginx的上传大小 [英] Increase upload size on Nginx
问题描述
我不断收到试图上传大文件(约135MB)时连接被重置。当我看的网站conf目录下的last_nginx.conf它说:client_max_body_size128米;我认为是上传限制,因此如何/我在哪里改呢?它说,不要打扰更改该文件中的值,因为它只会被覆盖。顺便说一句Nginx的通过的Plesk管理面板中启用。
I keep getting "The connection was reset" when trying to upload a large file (around 135MB). When I look at the "last_nginx.conf" of the website conf directory it says "client_max_body_size 128m;" I assume that is the upload limit, so how/where do I change it? It says not to bother changing the value in that file because it will only be overwritten. Btw Nginx is enabled via Plesk admin panel.
推荐答案
答改变虚拟主机Nginx的文件是这样的:
Answer to change vhosts nginx file is this :
的mkdir的/ usr /本地/ PSA /管理/ conf目录/模板/自定义/域
mkdir /usr/local/psa/admin/conf/templates/custom/domain
CP /usr/local/psa/admin/conf/templates/default/domain/nginxDomainVirtualHost.php在/ usr /本地/ PSA /管理/ conf目录/模板/自定义/域/
cp /usr/local/psa/admin/conf/templates/default/domain/nginxDomainVirtualHost.php /usr/local/psa/admin/conf/templates/custom/domain/
中添加/usr/local/psa/admin/conf/templates/custom/domain/nginxDomainVirtualHost.php:
add in /usr/local/psa/admin/conf/templates/custom/domain/nginxDomainVirtualHost.php:
在/ usr /本地/ PSA /管理/斌/ httpdmng --reconfigure-所有#申请新的配置所有域
/usr/local/psa/admin/bin/httpdmng --reconfigure-all # to apply new configuration for all domains
至于结果,如果域具有的conf / nginx.conf - 它将被纳入虚拟主机配置。
As result, if domain has conf/nginx.conf - it will be included into virtual host config.
这篇关于加大对Nginx的上传大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!