[Glass] GC on Gems only fired when temp space is over?

Martin McClure via Glass glass at lists.gemtalksystems.com
Thu Jul 2 20:33:14 PDT 2015


On 06/23/2015 06:51 AM, Mariano Martinez Peck via Glass wrote:
> 
> I ask because I did not noticed much of a change if I shutdown all
> seaside gems and start them again. However.....if I shut down all stones
> and start them again (with all seaside gems again), then the memory used
> decreases A LOT. While this may be obvious, it is not fully clear to me
> why. As a first thought I would guess the main difference is the SPC.
> However, SPC is a segment/shared and that memory is reserved from the
> very beginning. So I don't expect that to change wether I reset the
> stone or not. 
> 
> So...if it is not the SPC.... they are not the seaside gems, they are
> not the admin/reclaim gc (those use very little temp space), what else
> could be such a difference if memory consumption when I reset the stone?  

With reference to my recent reply on a different thread...

If you're judging memory use by how much free memory the system has, you
probably shouldn't. /proc/meminfo's MemAvailable or equivalent is a
better indicator of whether your system is under memory pressure. That
and how much swap activity is going on.

It's normal to see free memory increase when you shut the stone down --
you've freed the entire SPC, among other things. When you shut down a
gem, only the private memory that was used by that gem is freed, and
most of the memory in a gem's RSS is shared with other processes or is
cached file memory. Bottom line, stopping and starting a stone when your
system is not under serious memory pressure just throws a bunch of stuff
out of memory that you then have to read back in from disk on demand,
slowing your system down.

Regards,

-Martin


More information about the Glass mailing list