Hello all ,
We're using nginx 1.1.6 ver. 5 server connected NetApp storage via NFS . (/var/www )
Sometimes 1 or 2 server return cache size 0-byte and don't answer http request. Other 3 server working well .
If i restarted nginx or delete cache file , 0-byte problem resolve.
Example service conf :
upstream upstream.test.com {
server 1.1.1.1:80;
server 2.2.2.2:80 backup;
server 3.3.3.3:80 backup;
}
server {
listen 80;
server_name video.test.com;
access_log off;
location / {
proxy_pass http://upstream.test.com;
proxy_ignore_headers Expires Cache-Control Set-Cookie;
proxy_cache_valid 200 30d;
proxy_cache $host;
proxy_connect_timeout 5;
proxy_read_timeout 10;
proxy_next_upstream error timeout http_500 http_502 http_503 http_504 http_404;
set $maincache "main-a:";
proxy_cache_key $maincache$host$uri;
proxy_redirect off;
proxy_set_header Host $proxy_host;
proxy_max_temp_file_size 0;
proxy_hide_header Cache-Control;
proxy_hide_header X-Powered-By;
proxy_hide_header X-AspNet-Version;
expires 30d;
}
location ~ /delete(/.*) {
allow 5.5.5.5;
deny all;
set $deluri $1;
set $maincache "main-a:";
proxy_cache_purge $host $maincache$host$deluri;
}
}
Where i'm mising ?
Thanks