linux free 命令中的 buffer & free
来源:互联网 发布:口袋妖怪pc网络 编辑:程序博客网 时间:2024/06/03 11:08
Short answer: Cached is the size of the page cache. Buffers is the size of in-memory block I/O buffers. Cached matters; Buffers is largely irrelevant.
Long answer: Cached is the size of the Linux page cache, minus the memory in the swap cache, which is represented by SwapCached (thus the total page cache size is Cached + SwapCached). Linux performs all file I/O through the page cache. Writes are implemented as simply marking as dirty the corresponding pages in the page cache; the flusher threads then periodically write back to disk any dirty pages. Reads are implemented by returning the data from the page cache; if the data is not yet in the cache, it is first populated. On a modern Linux system, Cached can easily be several gigabytes. It will shrink only in response to memory pressure. The system will purge the page cache along with swapping data out to disk to make available more memory as needed.
Buffers are in-memory block I/O buffers. They are relatively short-lived. Prior to Linux kernel version 2.4, Linux had separate page and buffer caches. Since 2.4, the page and buffer cache are unified and Buffers is raw disk blocks not represented in the page cache—i.e., not file data. The Buffers metric is thus of minimal importance. On most systems, Buffers is often only tens of megabytes.
Long answer: Cached is the size of the Linux page cache, minus the memory in the swap cache, which is represented by SwapCached (thus the total page cache size is Cached + SwapCached). Linux performs all file I/O through the page cache. Writes are implemented as simply marking as dirty the corresponding pages in the page cache; the flusher threads then periodically write back to disk any dirty pages. Reads are implemented by returning the data from the page cache; if the data is not yet in the cache, it is first populated. On a modern Linux system, Cached can easily be several gigabytes. It will shrink only in response to memory pressure. The system will purge the page cache along with swapping data out to disk to make available more memory as needed.
Buffers are in-memory block I/O buffers. They are relatively short-lived. Prior to Linux kernel version 2.4, Linux had separate page and buffer caches. Since 2.4, the page and buffer cache are unified and Buffers is raw disk blocks not represented in the page cache—i.e., not file data. The Buffers metric is thus of minimal importance. On most systems, Buffers is often only tens of megabytes.
0 0
- linux free 命令中的 buffer & free
- Linux中的free命令
- Linux中的free命令
- Linux中的free命令
- free 中的buffer 和 cached
- Linux 内存(free buffer cache)
- linux free命令中buffer和cache的区别
- linux free命令中buffer与cache的区别
- Linux Free命令与cache和buffer的主要区别
- Linux命令 之 free (buffer与cache区别 )
- linux free命令中buffer与cache的区别
- linux free命令中buffer与cache的区别
- Linux的free命令以及cache与buffer的区别
- linux free命令中buffer和cache的区别
- Busybox中的free命令
- linux命令free详解
- linux的free命令
- LINUX FREE命令
- android studio 快捷键
- 探究String、StringBuffer、StringBuilder的区别?
- binlog作用
- 机器学习值得一看的优质论文(部分)
- Python:itertools模块
- linux free 命令中的 buffer & free
- CSDN越做越恶心
- 设计理念服从于或者来源于生活
- LeetCode Contains Duplicate II Contains Duplicate III
- Wait A Moment, JavaScript Does Support Multiple Inheritance!
- 进程标志位(ProcessFlag_ProcessState)
- 5.28股票跌没了,红木家具还在那
- Ctrl + C无效 SIGINT -- trap
- ireport中的几个小问题