What happens when a Varnish Cache is full?

I use varnish with -s malloc, 1G "

Currently 98% full. Once it is full, what will happen?

With his cleaning?

Perhaps delete old images / pages?

Or is it even better to clear files with the least number of strokes?

+7
source share
1 answer

It looks like Varnish is using the LRU (least recently used) strategy to remove items from the cache when the cache is populated with things whose TTL (lifetime) has not expired (first delete things whose TTL has expired if the cache is still completely deleted, which recently got access).

Cm

https://www.varnish-cache.org/trac/wiki/ArchitectureLRU

Note that you can look at the n_lru_nuked counter to see the speed at which things are washed out of the cache due to LRU.

+10
source

All Articles