memory troubles?

Smoot Carl-Mitchell smoot at tic.com
Mon Dec 17 20:05:44 UTC 2007


On Mon, 2007-12-17 at 20:17 +0100, Aart Koelewijn wrote:

> Do not worry. *nix always has lots of programs running (or waiting) in
> the background. In general they are needed to keep the whole system
> running at all. Also it is usual that almost all RAM is used. A program
> that is stopped usually wil stay in RAM to see if it is needed again.
> Only when a new program is started and needs free RAM stopped programs
> are deleted from RAM (but often kept in swap, because programs usually
> start faster from swap then from RAM). For me:
> 

I think you meant that processes in RAM are more responsive.  A process
which is completely swapped will take more time to read in its active
pages.

Processes are never really stopped -- they are waiting on an event (e.g.
I/O or a signal) when they do not need the cpu.  When the event happens,
then the process is scheduled to use the cpu along with all the other
processes which need the cpu at the time.  I guess you could consider
the process to be stopped, but I prefer to think of them as waiting and
not using the cpu.

As for memory utilization, it is typical for most of the available
memory to be used.  The system uses memory for both process memory as
well as memory needed for buffering recently used disk blocks. Since
processes are demand paged, it is rare to have an entire process in
memory and it is far more efficient to free up memory for other purposes
than have processes be memory resident all the time.
-- 
Smoot Carl-Mitchell
System/Network Architect
email: smoot at tic.com
cell: +1 602 421 9005
home: +1 480 922 7313




More information about the ubuntu-users mailing list