Re: slab usage in linux

2011-01-04 Thread Mulyadi Santosa
Hi

I cc: the reply to the new list address. I hope you don't mind
Now, let's what I can share here

On Tue, Jan 4, 2011 at 18:49, Sowmya Sridharan  wrote:
> I have seen slab cache increase by even 1GB, over two to three days on a
> stable system.(The system was sending and receiving bulk amounts of
> packets).

No kidding? 1 Gig? Wow But that's alright, I think that still make
sense ... highly frequent sock related cache creation I guess
"slabtop -s c" would tell you the highest cache size ...

> When is slab usually freed?

AFAIK when it can no longer "grow" same like page cache, it will
grow to fill your RAM  until  it exhausts everything left by anonymous
page allocation plus some amount of  reserved pages. And AFAIK too,
it's tunable, but I couldn't recall which kernel parameters that
control it.

>Also when I analyzed /proc/slabinfo, I was able
> to see that the number of active slab objects were increasing mostly for
> task_struct, dentry_cache and proc_inode_caches. When are these caches
> allotted objects, in general?

task_struct--> during new process creation

dentry_cache --> after reading directory entry metadata from a block
devices and cache them

proc_inode_cache --> almost similar like above, but this one is
strictly for /proc entries.

-- 
regards,

Mulyadi Santosa
Freelance Linux trainer and consultant

blog: the-hydra.blogspot.com
training: mulyaditraining.blogspot.com

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


slab usage in linux

2011-01-04 Thread Sowmya Sridharan
Hi List,

I have a few queries regarding slab memory and it's usage.
I have seen slab cache increase by even 1GB, over two to three days on a 
stable system.(The system was sending and receiving bulk amounts of 
packets).
 
When is slab usually freed? Also when I analyzed /proc/slabinfo, I was 
able to see that the number of active slab objects were increasing mostly 
for task_struct, dentry_cache and proc_inode_caches. When are these caches 
allotted objects, in general?

Can anyone please explain the behavior related to slab allocation; or 
point to any reference material?

Thanks,
Sowmya.
=-=-=
Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 
not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 
information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 
please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 
and any attachments. Thank you


___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies