[KLUG Members] Memory dump?
Adam Williams
members@kalamazoolinux.org
Thu, 11 Dec 2003 08:16:22 -0500
> > > I have the same issue
> > > I am running RH9 with the KDE desktop I have 368mg of RAM and I run KDE
> > > system gaurd to monitor the system and the memory just keeps increasing
> > > like thier is a leak or that it is not being released back to the system
> > "free" memory will eventually decline to zero; this is normal healthy
> > system behaviour. Only paging activity indicates memory exhaustion.
> > > after a program is closed it gets to the point were programs wont even
> > > open anymore and I have to reboot this usually takes about 8 days
> > Do you log out and back in, or is this one continual session?
> I am new to Linux please what is paging activity?
Moving pages of memory (usually allocated and managed in 4Kb "pages")
between physical memory (RAM) and virtual memory (Swap partition(s)).
And even just swapping isn't neccesarily bad. For instance:
[awilliam@estate2 tmp]$ vmstat 20 20
procs memory swap io
system cpu
r b w swpd free buff cache si so bi bo in cs
2 0 0 12 30072 207264 325112 0 0 8 51 147 681
1 0 0 56 30176 207272 325524 0 8 18 242 162 4646
4 0 0 72 29824 207280 325648 0 7 0 89 137 471
0 0 0 100 29344 207280 325836 0 7 3 100 135 4605
3 0 0 160 28552 207280 326200 0 15 16 119 136 4584
2 0 0 372 22076 207344 320336 0 21 3 207 137 4644
3 0 0 444 26560 207356 320736 0 5 0 248 130 4273
3 0 0 524 25076 207356 319980 0 18 0 231 133 4233
1 0 0 596 36228 207364 322488 0 4 0 222 138 4790
1 0 0 660 32956 207364 325200 0 3 0 231 138 4843
1 0 0 708 32032 207368 327640 0 2 0 239 140 4607
3 0 0 724 28908 207372 330576 0 1 0 241 147 4596
4 0 0 724 34516 207372 332988 0 0 0 228 137 4346
3 0 0 724 35604 207384 335960 0 0 0 240 138 4825
4 0 0 724 23716 207384 337056 0 0 2 231 733 5851
3 0 0 728 26116 206912 339076 0 0 8 189 779 5364
5 0 0 728 38804 206908 340388 0 0 0 202 831 4591
"si" and "so" are swap-in/swap-out respectively. Free memory may be
declining and the system is swapping out, but it is never asking for
those pages again (swap-in) so they where probably just extra stuff
anyway and the system is using the physical RAM for more pressing
things.
[awilliam@estate2 tmp]$ free -t
total used free shared buffers cached
Mem: 1013640 979924 33716 0 205512 365660
-/+ buffers/cache: 408752 604888
Swap: 522104 680 521424
Total: 1535744 980604 555140
[awilliam@estate2 tmp]$ uptime
08:10:26 up 14:18, 1 user, load average: 2.15, 1.93, 1.28
So out of 1Gb of RAM I've only got 33Mb "free", after running only 14
hours. By the end of the day that 33 will be even lower. But that is a
good thing. What good does "free" RAM do for you? Nothing.
There are really only two critical factors here.
(1) +/- buffers used number is a healthy percentage of my RAM [Good
thing].
(2) Swap utilization is low; less than 20% of physical RAM is a rough
benchmark for goodness. If swap utilization climbs up above 50% of
physical RAM you probably need more RAM than what you have. [This is a
rough benchmark, some types applications drive up swap utilization and
are special cases where higher numbers are still fine].
To be rather blunt, most GUI system monitoring tools focus on entirely
the wrong things, and feel like they were written by people from a Win9x
background.
gtop is OK, if you know how to read it.
Since your bleeding of memory is taking a really long time it might be
hard to spot, but it should be easy to tell if it is a single process
by using something like top/gtop and sorting my memory (press shift-m in
top).
It might not by memory related at all; you could be running out of file
descriptors or something similiar. Are RH Update or NSCD enabled?
These have both been culprits of that in the past.
> Logging out and back in.
Ok.