Welcome! Log In Create A New Profile

Advanced

Re: Error - Using Nginx Proxy Cache

naidile.pn
May 18, 2020 01:28PM
Hi,

Can you please help here - basically after the cache expires, the upstream
call is failing as not accessible and we are serving stale data to avoid
failures.

After we reload the nginx- first call to upstream is successful and data is
cached.

Thanks!


On Fri, May 15, 2020, 2:14 PM naidile.pn <naidilepn@gmail.com> wrote:

> Hi All,
>
> We are using proxy cache to cache the response from upstream for a day.
> But, when the cache expires, API stops responding with 500.
>
> Getting the error: open() "proxycachepath" failed (13: Permission denied)
>
> On reloading the nginx, server is able to connect to upstream and cache
> response for the first time and works for next one day.
>
> Below is the nginx rule :
>
> location /somelocation {
> add_header X-Proxy-Cache $upstream_cache_status;
> proxy_cache my_zone;
> proxy_ignore_headers X-Accel-Expires Expires Cache-Control;
> proxy_cache_valid 200 1440m;
> proxy_cache_use_stale error timeout http_500 http_502
> http_503 http_504;
> proxy_pass someupstream;
> proxy_pass_request_headers on;
> proxy_connect_timeout 120;
> proxy_send_timeout 120;
> proxy_read_timeout 120;
> }
>
> Can anyone please help here.
>
> Thanks!
>
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Error - Using Nginx Proxy Cache

naidile.pn 69 May 15, 2020 04:46AM

Re: Error - Using Nginx Proxy Cache

naidile.pn 13 May 18, 2020 01:28PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 78
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready