preload
福布斯:Facebook网站十大最火爆游戏(组图) 谷歌Chrome开发团队成员亮相
27

top是给Linux设计的。在FreeBSD VM里面的Free概念和其他OS完全不同,使用top查看Free内存对于FreeBSD来说可以说没什么意义。正确的方法是看vmstat。

而vmstat这个指令,在linux系统,sun系统和freebsd系统中得到的结果样式和所代表的意义还很不相同。
procs memory page disk faults cpu
r b w swap free re mf mi po fr de sr f0 s0 s1 s2 in sy cs us sy id
0 0 0 14888 19120 0 4 2 11 10 0 0 0 0 0 8 198 2158 98 11 19 69
SWAP的单位应该是K,不是M。还有两个比较重要的参数是PI、PO,表示内存的调入、调出页面,单位也是K,但是多大值作为一个衡量标准,我也不清楚,不知道是否有经验值。
还有,最好使用vmstat t [n]命令,例如 vmstat 5 5,表示在T(5)秒时间内进行N(5)次采样。如果只使用vmstat,无法反映真正的系统情况,试一下,看看结果就知道了。
procs:
r–>在运行队列中等待的进程数
b–>在等待io的进程数
w–>可以进入运行队列但被替换的进程
memoy
swap–>现时可用的交换内存(k表示)
free–>空闲的内存(k表示)
pages
re--》回收的页面
mf--》非严重错误的页面
pi--》进入页面数(k表示)
po--》出页面数(k表示)
fr--》空余的页面数(k表示)
de--》提前读入的页面中的未命中数
sr--》通过时钟算法扫描的页面
disk 显示每秒的磁盘操作。 s表示scsi盘,0表示盘号
fault 显示每秒的中断数
in--》设备中断
sy--》系统中断
cy--》cpu交换
cpu 表示cpu的使用状态
cs--》用户进程使用的时间
sy--》系统进程使用的时间
id--》cpu空闲的时间
解释:
如果 r经常大于 4 ,且id经常少于40,表示cpu的负荷很重。
如果pi,po 长期不等于0,表示内存不足。
如果disk 经常不等于0, 且在 b中的队列 大于3, 表示 io性能不好。

Leave a Reply

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word