JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Managing System Information, Processes, and Performance in Oracle Solaris 11.1     Oracle Solaris 11.1 Information Library
search filter icon
search icon

Document Information

Preface

1.  Managing System Information (Tasks)

2.  Managing System Processes (Tasks)

3.  Monitoring System Performance (Tasks)

Where to Find System Performance Tasks

System Performance and System Resources

Processes and System Performance

About Monitoring System Performance

Monitoring Tools

Displaying System Performance Information

Displaying System Performance Information (Task Map)

Displaying Virtual Memory Statistics (vmstat)

How to Display Virtual Memory Statistics (vmstat)

How to Display System Event Information (vmstat -s)

How to Display Swapping Statistics (vmstat -S)

How to Display Interrupts Per Device (vmstat -i)

Displaying Disk Utilization Information (iostat)

How to Display Disk Utilization Information (iostat)

How to Display Extended Disk Statistics (iostat -xtc)

Displaying Disk Space Statistics (df)

How to Display Disk Space Information (df -k)

Monitoring System Activities

Monitoring System Activities (Task Map)

Monitoring System Activities (sar)

How to Check File Access (sar -a)

How to Check Buffer Activity (sar -b)

How to Check System Call Statistics (sar -c)

How to Check Disk Activity (sar -d)

How to Check Page-Out and Memory (sar -g)

Checking Kernel Memory Allocation

How to Check Kernel Memory Allocation (sar -k)

How to Check Interprocess Communication (sar -m)

How to Check Page-In Activity (sar -p)

How to Check Queue Activity (sar -q)

How to Check Unused Memory (sar -r)

How to Check CPU Utilization (sar -u)

How to Check System Table Status (sar -v)

How to Check Swapping Activity (sar -w)

How to Check Terminal Activity (sar -y)

How to Check Overall System Performance (sar -A)

Collecting System Activity Data Automatically (sar)

Running the sadc Command When Booting

Running the sadc Command Periodically With the sa1 Script

Producing Reports With the sa2 Shell Script

Setting Up Automatic Data Collection (sar)

How to Set Up Automatic Data Collection

4.  Scheduling System Tasks (Tasks)

5.  Managing the System Console, Terminal Devices, and Power Services (Tasks)

Index

Displaying System Performance Information

This section describes the tasks for monitoring displaying system performance information.

Displaying System Performance Information (Task Map)

Task
Description
For Instructions
Display virtual memory Statistics.
Collect virtual memory statistics by using the vmstat command.
Display system event information.
Display system event information by using the vmstat command with the -s option.
Display swapping statistics.
Use the vmstat command with the -S option to display swapping statistics.
Display interrupts per device.
Use the vmstat command with the -i option to show the number of interrupts per device.
Display disk utilization.
Use the iostat command to report disk input and output statistics.
Display extended disk statistics.
Use the iostat command with the -xtcoption to display extended disk statistics.
Display disk space information.
The df -k command displays disk space information in Kbytes.

Displaying Virtual Memory Statistics (vmstat)

You can use the vmstat command to report virtual memory statistics and information about system events such as CPU load, paging, number of context switches, device interrupts, and system calls. The vmstat command can also display statistics on swapping, cache flushing, and interrupts.

Table 3-4 Output From the vmstat Command

Category
Field Name
Description
procs
Reports on the following:
r
The number of kernel threads in the dispatch queue
b
The number of blocked kernel threads that are waiting for resources
w
The number of swapped out LWPs that are waiting for processing resources to finish
memory
Reports on usage of real memory and virtual memory:
swap
Available swap space
free
Size of the free list
page
Reports on page faults and paging activity, in units per second:
re
Pages reclaimed
mf
Minor faults and major faults
pi
Kbytes paged in
po
Kbytes paged out
fr
Kbytes freed
de
Anticipated memory that is needed by recently swapped-in processes
sr
Pages scanned by the page daemon not currently in use. If sr does not equal zero, the page daemon has been running.
disk
Reports the number of disk operations per second, showing data on up to four disks
faults
Reports the trap/interrupt rates per second:
in
Interrupts per second
sy
System calls per second
cs
CPU context switch rate
cpu
Reports on the use of CPU time:
us
User time
sy
System time
id
Idle time

For a more detailed description of this command, see the vmstat(1M) man page.

How to Display Virtual Memory Statistics (vmstat)

Example 3-1 Displaying Virtual Memory Statistics

The following example shows the vmstat display of statistics that were gathered at five-second intervals:

$ vmstat 5
kthr      memory            page            disk          faults      cpu
 r b w   swap  free  re  mf pi po fr de sr dd f0 s1 --   in   sy   cs us sy id
 0 0 0 863160 365680  0   3  1  0  0  0  0  0  0  0  0  406  378  209  1  0 99
 0 0 0 765640 208568  0  36  0  0  0  0  0  0  0  0  0  479 4445 1378  3  3 94
 0 0 0 765640 208568  0   0  0  0  0  0  0  0  0  0  0  423  214  235  0  0 100
 0 0 0 765712 208640  0   0  0  0  0  0  0  3  0  0  0  412  158  181  0  0 100
 0 0 0 765832 208760  0   0  0  0  0  0  0  0  0  0  0  402  157  179  0  0 100
 0 0 0 765832 208760  0   0  0  0  0  0  0  0  0  0  0  403  153  182  0  0 100
 0 0 0 765832 208760  0   0  0  0  0  0  0  0  0  0  0  402  168  177  0  0 100
 0 0 0 765832 208760  0   0  0  0  0  0  0  0  0  0  0  402  153  178  0  0 100
 0 0 0 765832 208760  0  18  0  0  0  0  0  0  0  0  0  407  165  186  0  0 100

How to Display System Event Information (vmstat -s)

How to Display Swapping Statistics (vmstat -S)

How to Display Interrupts Per Device (vmstat -i)

Example 3-2 Displaying Interrupts Per Device

The following example shows output from the vmstat -i command.

$ vmstat -i
interrupt         total     rate
--------------------------------
clock          52163269      100
esp0            2600077        4
zsc0              25341        0
zsc1              48917        0
cgsixc0             459        0
lec0             400882        0
fdc0                 14        0
bppc0                 0        0
audiocs0              0        0
--------------------------------
Total          55238959      105

Displaying Disk Utilization Information (iostat)

Use the iostat command to report statistics about disk input and output, and to produce measures of throughput, utilization, queue lengths, transaction rates, and service time. For a detailed description of this command, refer to the iostat(1M) man page.

How to Display Disk Utilization Information (iostat)

Example 3-3 Displaying Disk Utilization Information

The following example shows disk statistics that were gathered every five seconds.

$ iostat 5
tty        sd0           sd6           nfs1         nfs49           cpu
tin tout kps tps serv  kps tps serv  kps tps serv  kps tps serv  us sy wt id
 0    0   1   0   49    0   0    0    0   0    0    0   0   15   0  0  0 100
 0   47   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16  44   6  132    0   0    0    0   0    0    0   0    0   0  0  1 99
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   3   1   23    0   0    0    0   0    0    0   0    0   0  0  1 99
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100
 0   16   0   0    0    0   0    0    0   0    0    0   0    0   0  0  0 100

The following table describes the fields in the output of the iostat n command.

Device Type
Field Name
Description
Terminal
Device Type
tin
Number of characters in the terminal input queue
tout
Number of characters in the terminal output queue
Disk
Device Type
bps
Blocks per second
tps
Transactions per second
serv
Average service time, in milliseconds
CPU
Device Type
us
In user mode
sy
In system mode
wt
Waiting for I/O
id
Idle

How to Display Extended Disk Statistics (iostat -xtc)

Displaying Disk Space Statistics (df)

Use the df command to show the amount of free disk space on each mounted disk. The usable disk space that is reported by df reflects only 90 percent of full capacity, as the reporting statistics allows for 10 percent above the total available space. This head room normally stays empty for better performance.

The percentage of disk space actually reported by the df command is used space divided by usable space.

If the file system exceeds 90 percent capacity, you could transfer files to a disk that is not as full by using the cp command. Alternately, you could transfer files to a tape by using the tar or cpio commands. Or, you could remove the files.

For a detailed description of this command, see the df(1M) man page.

How to Display Disk Space Information (df -k)

Example 3-4 Displaying File System Information

The following example shows the output from the df -k command.

$ df -k
Filesystem           1024-blocks        Used   Available Capacity  Mounted on
rpool/ROOT/solaris-161   191987712     6004395   140577816     5%    /
/devices                       0           0           0     0%    /devices
/dev                           0           0           0     0%    /dev
ctfs                           0           0           0     0%    /system/contract
proc                           0           0           0     0%    /proc
mnttab                         0           0           0     0%    /etc/mnttab
swap                     4184236         496     4183740     1%    /system/volatile
objfs                          0           0           0     0%    /system/object
sharefs                        0           0           0     0%    /etc/dfs/sharetab
/usr/lib/libc/libc_hwcap1.so.1   146582211     6004395   140577816     5%    /lib/libc.so.1
fd                             0           0           0     0%    /dev/fd
swap                     4183784          60     4183724     1%    /tmp
rpool/export           191987712          35   140577816     1%    /export
rpool/export/home      191987712          32   140577816     1%    /export/home
rpool/export/home/123   191987712    13108813   140577816     9%    /export/home/123
rpool/export/repo      191987712    11187204   140577816     8%    /export/repo
rpool/export/repo2010_11   191987712          31   140577816     1%    /export/repo2010_11
rpool                  191987712     5238974   140577816     4%    /rpool
/export/home/123      153686630    13108813   140577816     9%    /home/123

The following table describes the output of the df -k command.

Field Name
Description
kbytes
Total size of usable space in the file system
used
Amount of space used
avail
Amount of space available for use
capacity
Amount of space used, as a percentage of the total capacity
mounted on
Mount point

Example 3-5 Displaying File System Information by Using the df Command Without Any Options

When the df command is used without operands or options, it reports on all mounted file systems, as shown in the following example:

$ df
/                  (rpool/ROOT/solaris):100715496 blocks 100715496 files
/devices           (/devices          ):       0 blocks        0 files
/dev               (/dev              ):       0 blocks        0 files
/system/contract   (ctfs              ):       0 blocks 2147483601 files
/proc              (proc              ):       0 blocks    29946 files
/etc/mnttab        (mnttab            ):       0 blocks        0 files
/system/volatile   (swap              ):42257568 blocks  2276112 files
/system/object     (objfs             ):       0 blocks 2147483441 files
/etc/dfs/sharetab  (sharefs           ):       0 blocks 2147483646 files
/dev/fd            (fd                ):       0 blocks        0 files
/tmp               (swap              ):42257568 blocks  2276112 files
/export            (rpool/export      ):100715496 blocks 100715496 files
/export/home       (rpool/export/home ):100715496 blocks 100715496 files
/export/home/admin (rpool/export/home/admin):100715496 blocks 100715496 files
/rpool             (rpool             ):100715496 blocks 100715496 files
/export/repo2010_11(rpool/export/repo2010_11):281155639 blocks 281155639 files
/rpool             (rpool             ):281155639 blocks 281155639 files