ITPub博客

首页 > 应用开发 > IT综合 > How to Display Disk Utilization Information

How to Display Disk Utilization Information

原创 IT综合 作者:rwq_ 时间:2006-03-05 20:39:59 0 删除 编辑

You can display disk activity information by using the iostat command with a time interval.

[@more@]

$ iostat 5
     tty          fd0           sd3          nfs1         nfs31          cpu
tin tout kps tps serv  kps tps serv  kps tps serv  kps tps serv  us sy wt id
  0    1   0   0  410    3   0   29    0   0    9    3   0   47   4  2  0 94

The first line of output shows the statistics since the last boot. Each subsequent line shows the interval statistics. The default is to show statistics for the terminal (tty), disks (fd and sd), and CPU (cpu).

The table below describes the fields in the iostat command output.

Table 36-4 Output From the iostat n Command

For Each ...

Field Name

Description

Terminal

tin

Number of characters in the terminal input queue

tout

Number of characters in the terminal output queue

Disk

bps

Blocks per second

tps

Transactions per second

serv

Average service time, in milliseconds

CPU

us

In user mode

sy

In system mode

wt

Waiting for I/O

id

Idle

Example--Displaying Disk Utilization Information

The following example shows disk statistics 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

How to Display Extended Disk Statistics (iostat -xtc)

Run iostat -xtc to get extended disk statistics.

$ iostat -xtc
                  extended device statistics                      tty         cpu
device       r/s    w/s   kr/s   kw/s wait actv  svc_t  %w  %b  tin tout  us sy wt id
fd0          0.0    0.0    0.0    0.0  0.0  0.0    0.0   0   0    0    0   0  0  0 100
sd0          0.0    0.0    0.4    0.4  0.0  0.0   49.5   0   0 
sd6          0.0    0.0    0.0    0.0  0.0  0.0    0.0   0   0 
nfs1         0.0    0.0    0.0    0.0  0.0  0.0    0.0   0   0 
nfs49        0.0    0.0    0.0    0.0  0.0  0.0   15.1   0   0 
nfs53        0.0    0.0    0.4    0.0  0.0  0.0   24.5   0   0 
nfs54        0.0    0.0    0.0    0.0  0.0  0.0    6.3   0   0 
nfs55        0.0    0.0    0.0    0.0  0.0  0.0    4.9   0   0 

This command displays a line of output for each disk. The output fields are described in the table below.

Table 36-5 Output From the iostat -xtc Command

Field Name

Description

r/s

Reads per second

w/s

Writes per second

Kr/s

Kbytes read per second

Kw/s

Kbytes written per second

wait

Average number of transactions waiting for service (queue length)

actv

Average number of transactions actively being serviced

svc_t

Average service time, in milliseconds

%w

Percentage of time the queue is not empty

%b

Percentage of time the disk is busy

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/814/viewspace-818472/,如需转载,请注明出处,否则将追究法律责任。

上一篇: ORACLE RAW设备操作
请登录后发表评论 登录
全部评论
  • 博文量
    36
  • 访问量
    637447