NGINX权限问题-尝试放入邮递员时出现HTTP错误409

NGINX权限问题-尝试放入邮递员时出现HTTP错误409,nginx,permissions,centos7,put,webdav,Nginx,Permissions,Centos7,Put,Webdav,我继承了这个服务器,所以我对NGINX没有太多经验。但在我开始改变事情,把事情搞砸之前,我想看看我是否能在这里找到一些帮助 服务器显示主页,从那里可以访问这些目录。GET方法有效。在WebDAV指令中没有设置POST,但我在尝试时得到403。我检查了access.log,看到的只是GET查询。但是,error.log显示以下内容 2020/08/27 13:43:12[crit]31561#0:*1 open()“/usr/share/nginx/html/tmp/0000000001”失败(1

我继承了这个服务器,所以我对NGINX没有太多经验。但在我开始改变事情,把事情搞砸之前,我想看看我是否能在这里找到一些帮助

服务器显示主页,从那里可以访问这些目录。GET方法有效。在WebDAV指令中没有设置POST,但我在尝试时得到403。我检查了access.log,看到的只是GET查询。但是,error.log显示以下内容

2020/08/27 13:43:12[crit]31561#0:*1 open()“/usr/share/nginx/html/tmp/0000000001”失败(13:权限被拒绝),客户端:myClient.CPE,服务器:server.CPE,请求:“PUT/Tech_Support_Files/2020-08-27T13:43:10_224806691313312_TSI.tar.gz.aes HTTP/1.1”,主机:“server.CPE” 2020/08/27 13:44:12[crit]31561#0:*2 open()“/usr/share/nginx/html/tmp/0000000002”失败(13:权限被拒绝),客户端:myClient.CPE,服务器:server.CPE,请求:“PUT/Tech_Support_Files/2020-08-27T13:43:10_224806691313312_TSI.tar.gz.aes HTTP/1.1”,主机:“server.CPE” 2020/08/27 13:45:13[crit]31561#0:*3 open()“/usr/share/nginx/html/tmp/0000000003”失败(13:权限被拒绝),客户端:myClient.CPE,服务器:server.CPE,请求:“PUT/Tech_Support_Files/2020-08-27T13:43:10_224806691313312_TSI.tar.gz.aes HTTP/1.1”,主机:“server.CPE”

所以这里似乎存在权限问题,但我显然没有找到它的来源。这是我的ls-l,在它试图协商的目录上,在我看来是正确的

/usr/share/nginx/html
total 12
-rw-r--r--. 1 nginx nginx 3650 Oct  3  2019 404.html
-rw-r--r--. 1 nginx nginx 3693 Oct  3  2019 50x.html
lrwxrwxrwx. 1 nginx nginx   20 Apr 13 14:57 en-US -> ../../doc/HTML/en-US
drwxr-xr-x. 2 nginx nginx   27 Apr 13 14:57 icons
lrwxrwxrwx. 1 nginx nginx   18 Apr 13 14:57 img -> ../../doc/HTML/img
lrwxrwxrwx. 1 nginx nginx   25 Apr 13 14:57 index.html -> ../../doc/HTML/index.html
-rw-r--r--. 1 nginx nginx  368 Oct  3  2019 nginx-logo.png
lrwxrwxrwx. 1 nginx nginx   14 Apr 13 14:57 poweredby.png -> nginx-logo.png
drwxrwxr-x. 2 nginx nginx   22 Aug 21 16:59 Tech_Support_Files
drwxrwxr-x. 2 nginx nginx    6 Aug 25 18:48 tmp
非常感谢对这项工作的任何见解。这是当前的.conf文件

user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /run/nginx.pid;

include /usr/share/nginx/modules/*.conf;

events {
    worker_connections 1024;
}

http {
    log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
                      '$status $body_bytes_sent "$http_referer" '
                      '"$http_user_agent" "$http_x_forwarded_for"';

access_log  /var/log/nginx/access.log  main;

sendfile            on;
tcp_nopush          on;
tcp_nodelay         on;
keepalive_timeout   75;
types_hash_max_size 2048;

include             /etc/nginx/mime.types;
default_type        application/octet-stream;

include /etc/nginx/conf.d/*.conf;

 server {
     listen       443 ssl http2 default_server;
     listen       [::]:443 ssl http2 default_server;
     server_name  CPE_Uploads;
     root         /usr/share/nginx/html;

     include /etc/nginx/self-signed.conf;
     include /etc/nginx/default.d/*.conf;

     add_header Strict-Transport-Security "max-age=7200";
     add_header "allow: GET, PUT, HEAD, PURGE, DELETE, PATCH" always;
  
     location / {
     root /usr/share/nginx/html;
     auth_basic "Restricted Site.";
     auth_basic_user_file /etc/nginx/auth/Tech_Support_Files;
     client_body_temp_path /usr/share/nginx/html/tmp/;
     client_body_buffer_size 1M;
     client_max_body_size 8M;
     dav_methods PUT DELETE MKCOL COPY MOVE;
     create_full_put_path on;
     dav_access user:rw group:rw all:rw;
     autoindex on;
     }

     error_page 404 /404.html;
         location = /40x.html {
     }

     error_page 500 502 503 504 /50x.html;
         location = /50x.html {
     }
  }

}

这是通过移动nginx用户主目录中的所有内容来解决的