vmstat
from http://jashliao.pixnet.net/blog/post/163268336-%E6%AF%8F%E5%A4%A9%E4%B8%80%E5%80%8Blinux%E6%8C%87%E4%BB%A4--vmstat%E6%8C%87%E4%BB%A4(%E9%87%9D%E5%B0%8D%E4%BD%9C%E6%A5%AD%E7%B3%BB%E7%B5%B1%E7%9A%84
[root@localhost ~]# vmstat 5 6procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu------
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 3029876 199616 690980 0 0 0 2 3 2 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 41 1009 39 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 3 1004 36 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 4 1004 36 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 6 1003 33 0 0 100 0 0
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 3029876 199616 690980 0 0 0 2 3 2 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 41 1009 39 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 3 1004 36 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 4 1004 36 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 6 1003 33 0 0 100 0 0
0 0 0 3029752 199616 690980 0 0 0 5 1003 33 0 0 100 0 0
說明:
欄位說明:
Procs(進程):
r: 運行佇列中進程數量
b: 等待IO的進程數量
Memory(記憶體):
swpd: 使用虛擬記憶體大小
free: 可用記憶體大小
buff: 用作緩衝的記憶體大小
cache: 用作緩存的記憶體大小
Swap:
si: 每秒從交換區寫到記憶體的大小
so: 每秒寫入交換區的記憶體大小
IO:(現在的Linux版本塊的大小為1024bytes)
bi: 每秒讀取的塊數
bo: 每秒寫入的塊數
系統:
in: 每秒中斷數,包括時鐘中斷。
cs: 每秒上下文切換數。
CPU(以百分比表示):
us: 使用者進程執行時間(user time)
sy: 系統進程執行時間(system time)
id: 閒置時間(包括IO等待時間),中央處理器的閒置時間 。以百分比表示。
wa: 等待IO時間
vmstat output contains the following fields:
- Procs – r: Total number of processes waiting to run
- Procs – b: Total number of busy processes
- Memory – swpd: Used virtual memory
- Memory – free: Free virtual memory
- Memory – buff: Memory used as buffers
- Memory – cache: Memory used as cache.
- Swap – si: Memory swapped from disk (for every second)
- Swap – so: Memory swapped to disk (for every second)
- IO – bi: Blocks in. i.e blocks received from device (for every second)
- IO – bo: Blocks out. i.e blocks sent to the device (for every second)
- System – in: Interrupts per second
- System – cs: Context switches
- CPU – us, sy, id, wa, st: CPU user time, system time, idle time, wait time
留言
張貼留言