赞
踩
TP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [crit] 8635#8635: *2 stat() "/home/thunderAI/release/index.html" failed (13: Permission denied), client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
2018/09/06 07:19:41 [error] 8635#8635: *2 rewrite or internal redirection cycle while internally redirecting to "/index.html", client: 103.90.76.205, server: 45smart.thundersoft.com, request: "GET / HTTP/1.1", host: "54.248.145.23"
134down voteaccepted
Nginx operates within the directory, so if you can't cd
to that directory from the nginx user then it will fail (as does the stat
command in your log). Make sure the www-user
can cd
all the way to the /username/test/static
. You can confirm that the stat
will fail or succeed by running
sudo -u www-data stat /username/test/static
In your case probably the /username
directory is the issue here. Usually www-data
does not have permissions to cd
to other users home directories.
The best solution in that case would be to add www-data
to username
group:
gpasswd -a www-data username
and make sure that username
group can enter all directories along the path:
chmod g+x /username && chmod g+x /username/test && chmod g+x /username/test/static
For your changes to work, restart nginx
nginx -s reload
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。