#free [parameters] shows free, used physical memory and swap memory in Linux system, and buffer used by the kernel
-H Auto-convert unit easy-to-read mode
-B Displays memory usage in bytes.
-K displays memory usage in kilobytes.
-m displays memory usage in megabytes.
-G displays memory usage in gigabytes.
-O does not display buffer throttling columns.
-s< interval seconds > Continuous observation of memory usage.
-T displays the memory sum column.
-V Displays version information.
#free--------total:used:free:shared:buffers/cached: Total memory Size: Used: Available: Total memory shared by multiple processes: size of disk cache: (-/+ buffers/ Cached): Used:free: How big is used: How much is available: swap:2.0g 0B 2.0G
--------
-Buffers/cached= Used (first line)-buffers-cached
is actually the size of the "physical Memory" of the program's current "real use".
+ buffers/cached= buffers + Cached
The combination of the two can be interpreted as "temporarily lending" the memory size used by the system as a "buffer".
Buffer is actually used to store the file system's meta data
Cache caches the contents of recently read-write files
Available RAM = System free Memory + buffers + cached.
=total-buff/cach used
Cat/proc/sys/vm/swappiness
Swappiness=0 indicates maximum use of physical memory and then swap space
SWAPPINESS=100 indicates active use of the swap partition, and the memory data is moved to the swap space in time
Echo 3 >/proc/sys/vm/drop_caches
"3" means releasing all buffers and cached; normal use will rise again.
This article is from the "mediocre" blog, please be sure to keep this source http://zzjasper.blog.51cto.com/9781564/1833706
Free use and interpretation