Linux工具 - VMSTAT监视内存使用情况

2019-04-23 18:41 By "Powerless" 2716 0 1

【语法】

    vmstat [-V] [-n] [delay [count]]

    ·    -V表示打印出版本信息;

    ·    -n表示在周期性循环输出时,输出的头部信息仅显示一次;

    ·    delay是两次输出之间的延迟时间;

    ·    count是指按照这个时间间隔统计的次数。

[root@wzxaini9 ~]# vmstat 5 5
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa st
 2  0      0 223332 225464 1212392    0    0     1    11   17    5  0  0 99  0  0
 0  0      0 222960 225464 1212444    0    0     0     8   88  176  1  0 99  0  0
 0  0      0 222960 225464 1212444    0    0     0     3   68  151  0  0 99  0  0


【字段说明】

Procs(进程):

    r: 运行队列中进程数量

    b: 等待IO的进程数量

Memory(内存):

    swpd: 使用虚拟内存大小

    free: 可用内存大小

    buff: 用作缓冲的内存大小

    cache: 用作缓存的内存大小

Swap:

    si: 每秒从交换区写到内存的大小

    so: 每秒写入交换区的内存大小

IO:(现在的Linux版本块的大小为1024bytes)

    bi: 每秒读取的块数

    bo: 每秒写入的块数

system:

    in: 每秒中断数,包括时钟中断

    cs: 每秒上下文切换数

CPU(以百分比表示)

    us: 用户进程执行时间(user time)

    sy: 系统进程执行时间(system time)

    id: 空闲时间(包括IO等待时间)

    wa: 等待IO时间

评 论

View in WeChat

Others Discussion

  • 分布式服务限流
    Posted on 2020-02-07 18:57
  • 有状态服务VS无状态服务
    Posted on 2020-02-07 18:18
  • 企业级PAAS云平台几个关键问题和挑战
    Posted on 2019-06-12 18:33
  • MySQL 单库后期分库策略
    Posted on 2019-08-19 14:31
  • Redis七大经典问题
    Posted on 2021-05-27 11:14
  • 关于HTTPS的五大误区
    Posted on 2020-02-02 01:10
  • PHP实现精确发布时间
    Posted on 2018-12-06 21:00
  • Git五分钟教程
    Posted on 2019-11-18 22:24

1.308971s