标签:
服务器架构是:Nginx+uWSGI+Django
某一天,发现服务器返回的response不完整,例如文档大小是200K的,但是只返回了100K给浏览器。
查了一下uWSGI的日志,发现以下错误:
Mon May 16 18:01:02 2016 - uwsgi_response_write_body_do(): Connection reset by peer [core/writer.c line 322] during GET /access?gid=5&action=edit&rand=20160516180050335056 (192.168.5.205)
IOError: write error
同时查一下Nginx的错误日志,发现:
mkdir() "/usr/local/nginx/uwsgi_temp/3/25" failed (13: Permission denied)
看来是因为Nginx没有权限操作目录/usr/local/nginx/uwsgi_temp/3/25
修改目录的拥有者为启动Nginx进程的用户
chown -R www /usr/local/nginx/uwsgi_temp
uWSGI uwsgi_response_write_body_do(): Connection reset by peer 报错的解决方法
标签:
原文地址:http://www.cnblogs.com/Xjng/p/bff2326efa75a01c72673aaece9e8af9.html