sar
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
sar [2015/04/04 12:06] – luke7858 | sar [2024/05/23 07:26] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ==== Installing sar ==== | + | ~~NOCACHE~~ |
- | === CentOS | + | ====== |
- | + | {{tabembed>[[[[sar_install|Install, | |
- | <sxh bash> | + | |
- | yum install sysstat | + | |
- | </ | + | |
- | + | ||
- | === Ubuntu | + | |
- | <sxh bash> | + | |
- | sudo apt-get install sysstat | + | |
- | </ | + | |
- | \\ | + | |
- | ==== Common Sar Commands | + | |
- | Show **version** of systat: | + | |
- | <sxh bash> | + | |
- | sar -V | + | |
- | </ | + | |
- | \\ | + | |
- | Show **CPU statistics** 3 times with 1 second interval: | + | |
- | <sxh bash> | + | |
- | sar 1 3 | + | |
- | </ | + | |
- | \\ | + | |
- | CPU usage of **all CPUs** (focus on the last field “%idle” to see the cpu load): | + | |
- | <sxh bash> | + | |
- | sar -u 1 3 | + | |
- | </ | + | |
- | \\ | + | |
- | Show **CPU** usage for the **current day** | + | |
- | <sxh bash> | + | |
- | sar -u | + | |
- | </ | + | |
- | \\ | + | |
- | **Swap Space** show for **current day** | + | |
- | <sxh bash> | + | |
- | sar -S | + | |
- | </ | + | |
- | Show swap space for 1 second interval 3 times: | + | |
- | <sxh bash> | + | |
- | sar -S 1 3 | + | |
- | </ | + |
sar.1428149190.txt.gz · Last modified: 2024/05/23 07:26 (external edit)