SAR

Display the CPU Load : sar -P ALL


[root@testserver ~]# sar -P ALL -f /var/log/sa/sa25
Linux 2.6.9-023stab048.6-smp (testserver.thomas-krenn.com)  

00:00:01          CPU     %user     %nice   %system   %iowait     %idle
00:10:01          all           9.63        0.00      3.81            6.20     80.36
00:10:01            0           8.69        0.00      3.63            7.18     80.50
00:10:01            1            9.28      0.00      3.96             4.47     82.29
00:10:01            2           10.22      0.00      3.86             6.31     79.62
00:10:01            3             9.84      0.00      3.66              6.91     79.59
00:10:01            4             9.86      0.00      3.94              5.28     80.92
00:10:01            5             9.97      0.00      3.84              6.37     79.81
00:10:01            6             9.90      0.00      4.04               7.21     78.85
00:10:01            7             9.32      0.00      3.54                5.83     81.32
[...]
Average:          all      9.21      0.00      1.68      0.27     88.84
Average:            0      9.03      0.00      1.70      0.31     88.97
Average:            1      9.20      0.00      1.67      0.25     88.88
Average:            2      9.45      0.00      1.70      0.28     88.56
Average:            3      9.84      0.00      1.68      0.26     88.22
Average:            4      9.23      0.00      1.68      0.26     88.84
Average:            5      9.05      0.00      1.68      0.27     89.00
Average:            6      8.90      0.00      1.68      0.29     89.14
Average:            7      8.97      0.00      1.66      0.28     89.10
[root@testserver ~]#






Displaying the RAM Load: sar -r



[root@testserver ~]# sar -r
Linux 2.6.9-023stab048.6-smp (testserver.thomas-krenn.com)   05/26/09

00:00:01    kbmemfree kbmemused  %memused kbbuffers  kbcached kbswpfree kbswpused  %swpused  kbswpcad
00:10:01        67248  16292680     99.59     42320  12502420   2047648       628      0.03         0
00:20:01       129776  16230152     99.21     47020  12527100   2047648       628      0.03         0
[...]
14:50:01       638680  15721248     96.10    158392   6953128   2047648       628      0.03         0
15:00:01       646272  15713656     96.05    159880   6966980   2047648       628      0.03         0
15:10:01        59784  16300144     99.63    132044   6565036   2047648       628      0.03         0
Average:       554290  15805638     96.61    124889  10992802   2047648       628      0.03         0
[root@testserver ~]# 





Displaying the Load Average: sar -q


The average load values (-q) for the current day will be displayed here.

[root@testserver ~]# sar -q 
Linux 2.6.9-023stab048.6-smp (testserver.thomas-krenn.com)  05/26/09

00:00:01      runq-sz  plist-sz   ldavg-1   ldavg-5  ldavg-15
00:10:01            0       590      1.62      1.89      1.21
00:20:01           11       574      0.24      0.63      0.86
[...]
15:10:01            7       671      2.36      2.26      2.03
15:20:01            9       651      1.85      1.96      1.99
Average:            7       600      1.02      1.04      1.00
[root@testserver ~]# 


Displaying the I/O Transfer Rate: sar -b


The I/O transfer rates (-r) for the current day will be displayed here.

[root@testserver ~]# sar -b
Linux 2.6.9-023stab048.6-smp (testserver.thomas-krenn.com)  05/26/09

00:00:01          tps      rtps      wtps   bread/s   bwrtn/s
00:10:01       402.21    197.20    205.00  35133.80  27616.04
00:20:01        66.61     56.36     10.24   2034.96    288.93
[...]
15:20:01        72.43      6.54     65.89    176.29   2720.35
15:30:01        73.28      6.08     67.20    399.04   3516.21
Average:        40.21      5.57     34.64    585.00   1561.78
[root@testserver ~]# 

tps - Total number of transfers per second that were issued to physical devices. A transfer is an I/O request to a physical device. Multiple logical requests can be combined into a single I/O request to the device. A transfer is of indeterminate size

rtps - Total number of read requests per second issued to physical devices
wtps - Total number of write requests per second issued to physical devices
bread/s - Total amount of data read from the devices in blocks per second. Blocks are equivalent to sectors with 2.4 kernels and newer and therefore have a size of 512 bytes. With older kernels, a block is of indeterminate size.
bwrtn/s - Total amount of data written to devices in blocks per second.


Displaying the Network Statistics: sar -n DEV




The statistical network values (-n) for the current day will be displayed here.

[root@testserver ~]# sar -n DEV
Linux 2.6.9-023stab048.6-smp (testserver.thomas-krenn.com)  05/26/09

00:00:01        IFACE   rxpck/s   txpck/s   rxbyt/s   txbyt/s   rxcmp/s   txcmp/s  rxmcst/s
00:10:01           lo      0.82      0.82    177.69    177.69      0.00      0.00      0.00
00:10:01         eth0     31.56     40.21   4537.41  35891.07      0.00      0.00      0.00
00:10:01         eth1   4876.29   9919.22 451754.61 14927283.09      0.00      0.00      0.00
00:10:01       venet0     52.88     44.19  46547.68  15279.15      0.00      0.00      0.00
[...]
15:30:01           lo      0.82      0.82    176.68    176.68      0.00      0.00      0.00
15:30:01         eth0    113.08    155.70  17825.90 188643.77      0.00      0.00      0.00
15:30:01         eth1    634.80   1268.92  58495.76 1888004.02      0.00      0.00      0.00
15:30:01       venet0    189.86    147.08 213164.21  42532.10      0.00      0.00      0.00
Average:           lo      0.82      0.82    177.10    177.10      0.00      0.00      0.00
Average:         eth0     56.42     78.90   9104.66  94428.28      0.00      0.00      0.00
Average:         eth1    281.59    559.55  25919.74 830592.96      0.00      0.00      0.00
Average:       venet0     87.26     64.75  99974.13  14933.05      0.00      0.00      0.00
[root@testserver ~]# 

sar -d -p -s 12:40:00 -e 01:40:00


Displaying All Values : 


The collective values for all devices (CPU, RAM, etc.) can be displayed using sar -A





















Comments

Popular posts from this blog

RPM

RAID

Wild Cards