Memory usage

Mark Syms mark at
Mon Nov 29 14:53:50 UTC 2010

> Message: 6
> Date: Mon, 29 Nov 2010 14:15:29 +0100
> From: Markus Sch?nhaber <ubuntu-users at>
> Subject: Re: Memory usage
> To: ubuntu-users at
> Message-ID: <4CF3A771.901 at>
> Content-Type: text/plain; charset=ISO-8859-1
> 29.11.2010 13:37, Billie Walsh:
>> On 11/28/2010 11:41 PM, Cristopher Thomas wrote:
>>> Over the past week I've tried disabling a few different applications
>>> that I thought likely culprits.  Gnome Do, Zeitgeist, offlineimap,
>>> Dropbox... Still no luck.
>>> Oddly enough, I've also noticed that swap isn't being used at all,
>>> seems weird.
>> I could be wrong, and I'm sure that if I am someone will correct me. If

>> I remember correctly your OS will use memory to the maximum amount 
>> available before it uses swap. If you have sufficient memory to run 
>> whatever applications are open it will show the memory maxed out and 
>> nothing in swap.
> Well, your statement is a bit too general. From man 5 proc:
> | /proc/sys/vm/swappiness
> |    The  value in this file controls how aggressively the kernel
> |    will swap memory pages.  Higher values increase agressiveness,
> |    lower values descrease aggressiveness.  The default value is 60.
> So, you can manipulate the kernel's behaviour wrt to swapping by writing
> to /proc/sys/vm/swappiness or changing the corresponding sysctl variable
> vm.swappiness. IAW there's no absolutely fixed point wrt to memory load
> when the kernel starts swapping.
> LWN has an article about this topic:
> Although old, I guess it still presents the general idea correctly.
> That said, if taken as a rule of thumb like "the more RAM available, the
> less likely it is for the kernel to swap", your statement above points
> in the right direction.

Indeed, which is why if you run the 'free' command from a terminal the
second line is "-/+ buffers/cache" and this shows how much "free" memory
is being consumed in buffering and caching data read from disk. If this
is needed for running applications the buffers and caches get flushed and
the requried space allocated to the applications. My home server shows 77M
free but
496M after discounting buffers and cache.



More information about the ubuntu-users mailing list