• 欢迎访问搞代码网站,推荐使用最新版火狐浏览器和Chrome浏览器访问本网站!
  • 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏搞代码吧

wordpress错误ERR_INCOMPLETE_CHUNKED_ENCODING解决方法

php 搞代码 3年前 (2022-01-23) 71次浏览 已收录 0个评论

在阿里云上,搭建了个nginx服务器,今天wordpress访问不正常,css没有加载成功,后台媒体库也加载不了。Chrome控制台看到如下错误:ERR_INCOMPLETE_CHUNKED_ENCODING。

看了下nginx/logs/error.log下日志:

open() "/aliyun/server/nginx/fastcgi_temp/1/02/0000000021" failed (13: Permission denied) while reading upstream, client: x.x.x.x, server: /本文来源gaodai#ma#com搞*!代#%^码网%搞代gaodaima码x.x.x.x, request: "GET /blog/wp-admin/load-styles.php?c=1&dir=ltr&load=dashicons,admin-bar,wp-admin,buttons,wp-auth-check&ver=4.1.1 HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "123.57.1.14", referrer: "http://x.x.x.x/blog/wp-admin/"


搜索了下,找到这篇文章http://www.tuicool.com/articles/7Bjiyq跟我遇到的问题类似。

发现nginx目录下fastcgi_temp属于nobody用户和用户组。

drwx------ 12 nobody  nobody    4096 Mar 14 18:24 fastcgi_temp

再看php-fpm配置文件:

#vi /etc/php-fpm.d/www.conf; Unix user/group of processes; Note: The user is mandatory. If the group is not set, the default user's group;       will be used.; RPM: apache Choosed to be able to access some dir as httpd;user = nobodyuser=www; RPM: Keep a group allowed to write in log dir.;group = nobodygroup=www

用户和用户组已经改成了www。将fastcgi_temp及子目录改为www。如下:

#chown -R www:www fastcgi_temp#ls -aldrwx------ 12 nobody  nobody    4096 Mar 14 18:24 fastcgi_temp

再次访问wordpress,一切正常!

参考:http://www.tuicool.com/articles/7Bjiyq

以上就介绍了wordpress错误ERR_INCOMPLETE_CHUNKED_ENCODING解决方法,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。


搞代码网(gaodaima.com)提供的所有资源部分来自互联网,如果有侵犯您的版权或其他权益,请说明详细缘由并提供版权或权益证明然后发送到邮箱[email protected],我们会在看到邮件的第一时间内为您处理,或直接联系QQ:872152909。本网站采用BY-NC-SA协议进行授权
转载请注明原文链接:wordpress错误ERR_INCOMPLETE_CHUNKED_ENCODING解决方法

喜欢 (0)
[搞代码]
分享 (0)
发表我的评论
取消评论

表情 贴图 加粗 删除线 居中 斜体 签到

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址