# Too many cache

**URL:** <https://www.ruby-forum.com/t/too-many-cache/196011>\
**Category:** NGINX\
**Created:** [October 5, 2010, 1:23pm UTC](https://www.ruby-forum.com/t/too-many-cache/196011 "2010-10-05T13:23:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Avalon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/ec9cab/32.png) [@Avalon](https://www.ruby-forum.com/u/Avalon)\
**Post date:** [October 5, 2010, 1:23pm UTC](https://www.ruby-forum.com/t/too-many-cache/196011/1 "2010-10-05T13:23:50Z")

</div>

Hello,

I’v got an heavy problem of cache overflow… First I give you the  
problem in an image (by munin) :

![](http://desmond.yfrog.com/Himg825/scaled.php?tn=0&server=825&filename=localhostlocaldomainmem.png&xsize=640&ysize=640)

Like you can see, the cache is taking about 900 Mo !

The installation :[list]  
[_] NGINX - 0.7.67  
[_] PHP - 5.3.3  
[_] APC (bÃªta)  
[_] Suhosin - 0.9.32.1  
[\*] Suhosin-patch - 5.3.3-0.9.10  
[/list]

(If you need of the configure options, I will give them.)

What can I do in that case ?

Thanks,  
J.

Posted at Nginx Forum:

> **[\[Problem\] Too many cache](https://forum.nginx.org/read.php?2,137347,137347#msg-137347)**
>
> Hello, I'v got an heavy problem of cache overflow... First I give you the problem in an image (by munin) : \[img\]http://desmond.yfrog.com/Himg825/scaled.php?tn=0&server=825&filename=localhostlocaldomainmem.png&xsize=640&ysize=640\[/img\]...

---

<div class="post-metadata">

**Author:** ![Avalon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/ec9cab/32.png) [@Avalon](https://www.ruby-forum.com/u/Avalon)\
**Post date:** [October 5, 2010, 1:58pm UTC](https://www.ruby-forum.com/t/too-many-cache/196011/2 "2010-10-05T13:58:23Z")

</div>

Hello!

On Tue, Oct 05, 2010 at 07:22:28AM -0400, Avalon wrote:

> Hello,
> 
> I’v got an heavy problem of cache overflow… First I give you the  
> problem in an image (by munin) :
> 
> ![](http://desmond.yfrog.com/Himg825/scaled.php?tn=0&server=825&filename=localhostlocaldomainmem.png&xsize=640&ysize=640)
> 
> Like you can see, the cache is taking about 900 Mo !

You still have about 700M of free (unused) memory, so it looks  
like cache “underflow” for me. Cache is expected to use all  
available memory as long as it’s not needed for apps and cache  
have something to cache.

Maxim D.

---

<div class="post-metadata">

**Author:** ![Avalon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/ec9cab/32.png) [@Avalon](https://www.ruby-forum.com/u/Avalon)\
**Post date:** [October 5, 2010, 2:01pm UTC](https://www.ruby-forum.com/t/too-many-cache/196011/3 "2010-10-05T14:01:54Z")

</div>

On 10/05/2010 01:22 PM, Avalon wrote:

> Hello,
> 
> I’v got an heavy problem of cache overflow… First I give you the  
> problem in an image (by munin) :
> 
> ![](http://desmond.yfrog.com/Himg825/scaled.php?tn=0&server=825&filename=localhostlocaldomainmem.png&xsize=640&ysize=640)
> 
> Like you can see, the cache is taking about 900 Mo !

The cache adapts dynamically to the workload i.e. as long as you have  
free  
memory the operating system will try to cache data in there. Once you  
run  
out of free memory the os will begin to throw out cached information to  
satisfy allocation requests.

The real amount of free memory (as in “memory that can be allocated by  
applications” also sometimes calles “available memoery”) is free memory  
(as  
in “completely unused memory” that is shown in e.g. top or  
/proc/meminfo)  
plus cached memory.

Regards,  
Dennis

---

<div class="post-metadata">

**Author:** ![Avalon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/ec9cab/32.png) [@Avalon](https://www.ruby-forum.com/u/Avalon)\
**Post date:** [October 5, 2010, 2:57pm UTC](https://www.ruby-forum.com/t/too-many-cache/196011/4 "2010-10-05T14:57:31Z")

</div>

> You still have about 700M of free (unused) memory,  
> so it looks  
> like cache “underflow” for me. Cache is expected  
> to use all  
> available memory as long as it’s not needed for  
> apps and cache  
> have something to cache.
> 
> Maxim D.

Thank you ! I think this cache is “underflow” because this server hasn’t  
many website on it.

> applications" also sometimes calles “available  
> memoery”) is free memory (as  
> in “completely unused memory” that is shown in  
> e.g. top or /proc/meminfo)  
> plus cached memory.
> 
> Regards,  
> Dennis

Thank your for this valuable answer !!

Posted at Nginx Forum:  
[http://forum.nginx.org/read.php?2,137347,137397#msg-137397](http://forum.nginx.org/read.php?2,137347,137397#msg-137397)
