System Administration Guide: Advanced Administration

How to Check Swapping Activity (sar -w)

Use the sar -w command to report swapping and switching activity.


$ sar -w
00:00:00 swpin/s bswin/s swpot/s bswot/s pswch/s
01:00:00    0.00     0.0    0.00     0.0      22

The following table describes target values and observations.

Table 24–19 Output From the sar -w Command

Field Name 

Description 

swpin/s

The number of LWP transfers into memory per second. 

bswin/s

The average number of processes that are swapped out of memory per second. If the number is greater than 1, you might need to increase memory. 

swpot/s

The average number of processes that are swapped out of memory per second. If the number is greater than 1, you might need to increase memory. 

bswot/s

The number of blocks that are transferred for swap-outs per second. 

pswch/s

The number of kernel thread switches, per second. 


Note –

All process swap-ins include process initialization.


Example—Checking Swap Activity

The following example shows output from the sar -w command.


$ sar -w
SunOS venus 5.9 Generic sun4u    06/24/2001

00:00:00 swpin/s bswin/s swpot/s bswot/s pswch/s
01:00:00    0.00     0.0    0.00     0.0      22
02:00:02    0.00     0.0    0.00     0.0      22
03:00:00    0.00     0.0    0.00     0.0      22
04:00:00    0.00     0.0    0.00     0.0      22
05:00:01    0.00     0.0    0.00     0.0      22
06:00:00    0.00     0.0    0.00     0.0      22
07:00:00    0.00     0.0    0.00     0.0      22
08:00:01    0.00     0.0    0.00     0.0      22
08:20:00    0.00     0.0    0.00     0.0      22
08:40:00    0.00     0.0    0.00     0.0      22
09:00:00    0.00     0.0    0.00     0.0      22
09:20:00    0.00     0.0    0.00     0.0      22
09:40:00    0.00     0.0    0.00     0.0      22
10:00:00    0.00     0.0    0.00     0.0      22
10:20:00    0.00     0.0    0.00     0.0      22
10:40:01    0.00     0.0    0.00     0.0      23
11:00:00    0.00     0.0    0.00     0.0     144

Average     0.00     0.0    0.00     0.0      24