Maxim Dounin
December 19, 2017 01:12PM
Hello!

On Tue, Dec 19, 2017 at 12:48:41PM -0500, erick3k wrote:

> what i observe is the folder cachemaster going over 1gb, way over until it
> fills the hard drive.

Please define "until it fills the hard drive". It is ok if you
have only 1gb or 2gb free, but it is certainly not ok if it fills
a free 200gb drive.

Additional question is about temporary files. As previously
explained, temporary files are not counted against the cache
max_size limit, yet will occupy space in the same folder due to
"use_temp_path=off". Consider using "use_temp_path=on" (the
default) with a proxy_temp_path pointing to a different folder to
test if the space is occupied by the cache or temporary files.

You may also want to take a look into the error log, to see if
there are any crit/alert/emerg errors. Also you may want to
check what the nginx cache manager process is doing.

> so what is the correct way to limit the cache size used by nginx?

The "proxy_cache_path ... max_size=..." is the correct way.
Though it should be understood that it doesn't limit the size of
the folder, but rather instruct nginx to remove old cache items if
the size of the cache is above the limit.

--
Maxim Dounin
http://mdounin.ru/
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Problem with proxy_cache_path and limit

erick3k December 18, 2017 09:14PM

Re: Problem with proxy_cache_path and limit

tokers December 18, 2017 09:44PM

Re: Problem with proxy_cache_path and limit

erick3k December 18, 2017 09:51PM

Re: Problem with proxy_cache_path and limit

erick3k December 18, 2017 09:59PM

Re: Problem with proxy_cache_path and limit

Maxim Dounin December 19, 2017 08:46AM

Re: Problem with proxy_cache_path and limit

erick3k December 19, 2017 12:48PM

Re: Problem with proxy_cache_path and limit

erick3k December 19, 2017 12:51PM

Re: Problem with proxy_cache_path and limit

Maxim Dounin December 19, 2017 01:12PM

Re: Problem with proxy_cache_path and limit

erick3k December 19, 2017 01:31PM

Re: Problem with proxy_cache_path and limit

Maxim Dounin December 19, 2017 02:40PM

Re: Problem with proxy_cache_path and limit

erick3k December 19, 2017 04:13PM

Re: Problem with proxy_cache_path and limit

Maxim Dounin December 20, 2017 08:08AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 143
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready