2001-04-10 17:37:39

by gis88530

[permalink] [raw]
Subject: memory usage

Hello,

I can use "ps" to see memory usage of daemons and user programs.
I can't find any memory information of kernel with "top" and "ps".

Do you know how to take memory usage information of kernel ?
Thanks for your help.


Cheers,
Tom


2001-04-10 17:49:42

by Andi Kleen

[permalink] [raw]
Subject: Re: memory usage

On Wed, Apr 11, 2001 at 01:42:55AM +0800, gis88530 wrote:
> Hello,
>
> I can use "ps" to see memory usage of daemons and user programs.
> I can't find any memory information of kernel with "top" and "ps".
>
> Do you know how to take memory usage information of kernel ?

Try cat /proc/slabinfo


-Andi

2001-04-10 20:05:44

by gis88530

[permalink] [raw]
Subject: Re: memory usage

Thanks.
cat /proc/slabinfo look like as follows.
Each row have three columns.
Could you tell me what do they mean in second and third column?
kmem_cache 29 42
pio_request 0 0

My second question is:
We can find memory usage of daemon(apache) by ps or top.
e.g. apache use 5400k physical memory

Does the memory usage of /proc/slabinfo include some of
5400k ? I guess 5400k can separate into two part
(kernel space part and user space part).

Is any thing wrong? Thanks
Cheers,
Tom

2001-04-11 08:38:12

by Marcin Kowalski

[permalink] [raw]
Subject: Re: memory usage


> I can use "ps" to see memory usage of daemons and user programs.
> I can't find any memory information of kernel with "top" and "ps".

> Do you know how to take memory usage information of kernel ?
> Thanks for your help.


Regarding this issue, I have a similar problem if I do a free on my system I
get :
--- total used free shared buffers cached
Mem: 1157444 1148120 9324 0 22080 459504
-/+ buffers/cache: 666536 490908
Swap: 641016 19072 621944
---
Now what I do a ps there seems no way to accound for the 500mb + of memory
used. No single or group of processes uses that amount of memory. THis is
very disconcerting, coupled with extremely high loads when cache is dumped to
disk locking up the machine makes me want to move back to 2.2.19 from 2.4.3.

I would also be curious to see how the kernel is using memory...

TIA
MARCin


--
-----------------------------
Marcin Kowalski
Linux/Perl Developer
Datrix Solutions
Cel. 082-400-7603
***Open Source Kicks Ass***
-----------------------------