Knowledge Base:All available memory is being used

Synopsis
When calling the command to see the available memory, users notice that all memory is in use and therefor not available for applications anymore:

Environment
This article is applicable to all Linux systems.

Analysis
The output of the command is correct, but often misinterpreted.


 * The free column in the Mem: row tells the user how much memory is not used for anything, including buffers or cache (which can be removed at any time when memory is needed).
 * The buffers and cached columns in the Mem: row show how much memory is currently used by buffers and cache (mostly used for file system caching), which is memory that can be immediately reclaimed for applications (and as such should be seen as free for applications)

Resolution
To know how much memory is available for applications (if they need it), one should read the free column on the -/+ buffers/cache line, as that includes free memory + memory used by buffers and cache.

In the above example, more than 3 GiB of memory is available for applications.

External resources

 * Linux ate my ram! — An entire site dedicated to the misinterpretation of available RAM in Linux.