美文网首页
mac下nginx的client_body_temp目录权限不够

mac下nginx的client_body_temp目录权限不够

作者: dbasy | 来源:发表于2021-07-21 14:59 被阅读0次

查看nginx错误日志,日志显示报错
日志所在位置:/usr/local/Cellar/nginx/1.17.3_1/logs/error.log

2021/07/21 14:04:32 [crit] 3126#0: *3195 open() "/usr/local/var/run/nginx/client_body_temp/0000000026" failed (13: Permission denied), client: 127.0.0.1, server: localhost, request: "POST /plat/pss//upload HTTP/1.1", host: "scm.mynatapp.cc", referrer: "http://scm.mynatapp.cc/plat/h5/pages/complaint/complaint"
2021/07/21 14:04:32 [crit] 3126#0: *3195 open() "/usr/local/var/run/nginx/client_body_temp/0000000026" failed (13: Permission denied), client: 127.0.0.1, server: localhost, request: "POST /plat/pss//upload HTTP/1.1", host: "scm.mynatapp.cc", referrer: "http://scm.mynatapp.cc/plat/h5/pages/complaint/complaint"
2021/07/21 14:04:32 [crit] 3126#0: *3195 open() "/usr/local/var/run/nginx/client_body_temp/0000000026" failed (13: Permission denied), client: 127.0.0.1, server: localhost, request: "POST /plat/pss//upload HTTP/1.1", host: "scm.mynatapp.cc", referrer: "http://scm.mynatapp.cc/plat/h5/pages/complaint/complaint"

open() "/usr/local/var/run/nginx/client_body_temp/0000000034" failed (13: Permission denied),
切换到root用户 sudo su

(base) wangheng@localhost nginx % sudo su
sh-3.2# ls

赋权

chmod 777 client_body_temp/

上传成功


image.png

相关文章

网友评论

      本文标题:mac下nginx的client_body_temp目录权限不够

      本文链接:https://www.haomeiwen.com/subject/brejmltx.html