Board logo

标题: [分享] discuz上传附件过大提示Server (IO) Error的解决方法 [打印本页]

作者: zhoumo310    时间: 2013-11-28 11:00     标题: discuz上传附件过大提示Server (IO) Error的解决方法

本帖最后由 zhoumo310 于 2013-11-28 11:12 编辑

今天遇到这个问题,我的服务器是 nginx+apache,php.ini里,已经设置了

memory_limit 为200M,post_max_size = 150M,upload_max_filesize = 100M,max_execution_time为600秒,但是上传了一个10来M的压缩包仍然提示Server (IO) Error。后来在这个站点对应的nginx.conf文件中,增加了一行client_max_body_size 100m;,如下:





server {
        listen       80;
        server_name xxx.com www.xxx.com ;
        root /www/web/y/xxx/public_html;
        index  index.html index.php index.htm;
        error_page  400 /errpage/400.html;
        error_page  403 /errpage/403.html;
        error_page  404 /errpage/404.html;
        location ~ \.php$ {
                proxy_pass http://127.0.0.1:88;
                include naproxy.conf;
                client_max_body_size 100m;
        }
        location / {
                try_files $uri @apache;
        }
        location @apache {
                 proxy_pass http://127.0.0.1:88;
                 include naproxy.conf;
        }
}     




问题解决。




作者: admin    时间: 2013-11-28 17:51

加精
作者: esncy    时间: 2014-1-2 23:10

求APACHE+PHP如何解决?
作者: microsoftool    时间: 2014-1-3 13:37

主要是改php.ini 的post_max ,upload_max
作者: yeqiong2006    时间: 2017-6-9 09:02

回复 2# admin


   同样遇到该问题,V3.2系统,nginx+apache双引擎,在apache单引擎下测试没有问题,双引擎下和楼主一样。
通过楼主的方法,完美解决,建议老大能它以上代码能“出厂设置”。 :handshake
作者: admin    时间: 2017-6-9 12:59

加到nginx.conf配置文件里的http段就可以




欢迎光临 WDlinux官方论坛 (http://www.wdlinux.cn/bbs/) Powered by Discuz! 7.2