如何配置服务器以允许大文件下载?

问题描述:

我可以从服务器上毫无问题地下载1 Gb以上的文件.今天上传了2.3 GB的文件,发现我无法下载它,下载到1GB后被中断,并且每个用户都会发生.我尝试了Firefox 15,最新的Chrome和IE9.

I can download 1+ Gb files with no problem from my server. Today uploaded 2.3 GB file and discovered that I can't download it, downloading gets interrupted after 1GB and it happens for every user. I tried Firefox 15, latest Chrome, and IE9.

服务器: 阿帕奇2.2.22 fcgi 电子加速器 CPnginx

Server: Apache 2.2.22 fcgi eAccelerator CPnginx

我该如何解决?

我认为我也遇到了同样的问题,希望这可以对其他人有所帮助.

I think I just faced the same problem, hopefully this might help others.

我的服务器设置为使用 ngx_http_proxy_module .此模块的 proxy_max_temp_file_size 指令默认为1024m,并且是什么导致了我的问题.

My server is set up to proxy requests to Apache through Nginx using the ngx_http_proxy_module. The proxy_max_temp_file_size directive of this module defaults to 1024m and is what was causing my problem.

尝试在nginx.conf文件的http,服务器或位置指令中添加proxy_max_temp_file_size 5120m;行,并用/etc/init.d/nginx reload重新加载nginx的配置文件.

Try adding the line proxy_max_temp_file_size 5120m; within a http, server or location directive in your nginx.conf file and reload nginx's config file with /etc/init.d/nginx reload.