Hack 97. vmstat Command Examples
For a typical performance monitoring all you need is only vmstat command. This display memory, swap, IO, system and cpu performance information.The following command executes vmstat every 1 second for 100 times.
- b field: Total number of blocked process
Memory section
- Swpd field: Used swap space
- Free field: Available free RAM
- Buff field: RAM used for buffers
- Cache field: RAM used for filesystem cache
- Si field: Amount of memory swapped from disk per second
IO Section
- Bi field: Blocks received from disk
- Bo field: Blocks sent to disk.
- In field: Number of interrupts per second.
- Cs field: Number of context switches per second.
CPU Section
- Us field: Time spend running user code. (non-kernel code)
- Sy field: Time spent running kernel code.
- Wa field: Time spent waiting for the IO