S
S
sashamaro2018-04-04 00:33:13
Nginx
sashamaro, 2018-04-04 00:33:13

How to fix nginx config to serve cached content?

There is a file (600Mb) it is proxied by nginx using slice and cached. And now the problem is, when downloading this file, the download stops, that is, the connection is open, and the speed is 0. Hanging occurs when limit_rate 2m is set;
Config:

proxy_cache cache;
slice 10m;
proxy_cache_key    $host$uri$is_args$args$slice_range;
proxy_set_header   Range $slice_range;        
proxy_cache_valid  200 206 100m;
limit_rate 2m;

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question