首页 > CMS建站 > Discuz > 正文

discuz上传附件提示Server (IO) Error的解决方法

2020-07-02 22:19:01
字体:
来源:转载
供稿:网友
这篇文章主要为大家详细介绍了discuz上传附件提示Server (IO) Error的解决方法,具有一定的参考价值,感兴趣的小伙伴们可以参考一下,有需要的朋友可以收藏方便以后借鉴。

      用户使用discuz上传附件在上传一个50M左右的文件时,上传到17%左右的时候,就出现了Server (IO) Error的错误。

当时是怀疑,是不是我php配置的其他上传权限没有改好。

然后去看了下php.ini文件:

memory_limit、post_max_size、upload_max_filesize 、相关上传大小都是128M,max_execution_time时间也是300秒。

所以那就不是php配置的问题了。

又测试了下同服务器下的,其他网站程序,是正常的。

那就是discuz的配置问题了,网站程序配置相关是正常的。

所以是discuz的nginx配置问题,php配置虽然有100多M,但是nginx没有给它授权。

那就需要在nginx增加一个权限。

client_max_body_size 128m;

把这句放到nginx配置中,就解决discuz附件的Server (IO) Error问题了。

具体修改代码如下所示:

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 128m;        }        location / {                try_files $uri @apache;        }        location @apache {                 proxy_pass http://127.0.0.1:88;                 include naproxy.conf;        }}

问题解决。

以上就是discuz上传附件提示Server (IO) Error的解决方法的全部内容,希望对大家的学习和解决疑问有所帮助,也希望大家多多支持错新网。
发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表