pgm memory usage

rikona rikona at sonic.net
Fri Nov 5 20:38:10 UTC 2010


Hello Knight,

Friday, November 5, 2010, 3:08:07 AM, Knight wrote:

K> On Fri, 2010-11-05 at 00:01 -0700, rikona wrote:

K> <snipped>
>> 
>> From htop, I can already see physical ram is full, and swap is 80-90%
>> full.
>> 
K> <snipped>
>> -- 
>> 
>>  rikona        

K> While you're already looking at htop, press the key: t (tango)

K> Then you'll get to see the process tree. That makes it easier to
K> find the process which uses a lot of RAM/memory. To determine which
K> is which you can look at the command. It's possible to scroll to
K> the right with the arrows-keys.

I was just sorting by mem usage, which puts the biggies at the top.
I'm not sure I understand why tree view would be easier - it seems to
make it harder...

But mostly, it doesn't tell me which WINDOW, on which DESKTOP, the
process is running in, so I can stop the big memory hogs ***[but AFTER
I finish what I was doing re that task!]***.

K> Another GUI-program you could use is "System Monitor". (System >>
K> Administration) Then, while on the process tab, you can select
K> under "view" extra properties to look at. ie. Dependencies (pstree
K> like), memory maps, open files etc.. Worth a shot I think.

That mostly dupes what htop gives - but still no window ID.

BUT - I did notice that is has a small net speed display, which I had
asked about earlier, and got good suggestions for. Interestingly, of
the multiple suggestions, nobody mentioned the display in System
Monitor. :-) Maybe I'm not the only one who didn't notice it. :-)

K> Another approach is to use "watch" on the command "free" like:

K> watch free
K> OR
K> watch free -mt
K> (easier to read)

K> Then start working and opening your programs and keep an eye on
K> this terminal. Then when your RAM suddenly gets filled up it's
K> obvious that a program runs away with your RAM, stop it and you
K> found your basterd-program.(it's possible that there's a memory
K> leak somewhere)

I'm not looking for some strange pgm that is misbehaving. These are
konq, opera, FF, etc.

I'm actually trying to work 'backward' from the direction you suggest.
I already have MANY copies running, and htop tells me some instances
are memory hogs. Other instances of the same PGM are using very little
mem, so it's not the pgm.

What I want to do is ID the EXACT window and program-INSTANCE that is
the memory hog, and close it AFTER I HAVE FINISHED WITH IT, to get
back some speed when switching apps. Having just the PID does not tell
me the exact window to work on and then close.

K> BTW. How many RAM/swap do you have installed/configured?

2G mem, 6 G swap.

Thanks much for the reply,

-- 

 rikona        





More information about the ubuntu-users mailing list