Skip to content

Linux Buffers and Cache

How Linux uses buffers and page cache, and how to interpret their impact on memory use.

This English edition keeps the original illustrations and reproducible command or configuration examples.

Commands and configuration

free -h
示例:
              total   used   free   shared  buff/cache  available
Mem:           16G     10G    1G      200M        5G         4G
free -h
vmstat 1
vmstat 1
iostat -x 1
echo 3 > /proc/sys/vm/drop_caches
sysctl -a | grep dirty
free -h
vmstat 1
iostat -x 1
sar -B

Practical notes

Test each change on a recoverable target, keep logs from the boot or failure path, and record the exact kernel and userspace versions used in the result.