
On the contrarary, swapping happens when you are lacking physical memory. Thus, it is a feature that kind of behaves like “free lunch” and cannot be disabled. Disk cache can always be given back to applications immediately. If the applications demand more memory, they just take back a RAM that the disk cache used. This makes the system much faster and more responsive.
available memory (or “free + buffers/cache”) has enough room (let’s say, 20%+ of total) \ĭisk caching 3 is done by borrowing unused memory to cache the disk. It means that we have more than 107GB of available memory currently.Īs a rule of thumb 3, a healthy linux system should have: \ In row 2 of output, used indicate the memory actually being used by OS and applications. Linux recognized buffer and cache as used. In row 1 of output, total mem = used mem + free mem. Think of it as a buffer when you try to send a large message over a small-bandwidth network.īoth cache and buffer are available, which means they are used but can be purged without significant effects on the running applications.Ī simple calculation can be done as the following: $ free -m Buffered RAM: buffer is a temporary location to store data for a particular application and this data is not used by any other application. It is similar to the concept of cache in CPU’s architecture.
Cached RAM: cache is a memory location to store frequently used data for faster access.Used RAM = cached RAM + buffered RAM + actural RAM used by the applications and OS 2. free -kĭisplay memory usage every 2 seconds. Command usage freeĭisplay RAM in human readable formats like in KB’s, MB’s, GB’s, TB’s 1.
This post will summerize the usage of free command and how to interpret the output. Free is a command which can give us information on available RAM in Linux machine.