freebsd的观察系统状况命令systat

systat [-display] [更新-时间]
display system statistics 观察系统状况

-display          The - flag expects display to be one of: icmp, icmp6,
ifstat, iostat, ip, ip6, mbufs, netstat, pigs, swap,
tcp, or vmstat.  These displays can also be requested
interactively (without the ``-'') and are described in
full detail below.

例如

%systat -vm 1
    1 users    Load  5.04  4.35  3.92                  Mar 13 23:58

Mem:KB    REAL            VIRTUAL                       VN PAGER   SWAP PAGER
        Tot   Share      Tot    Share    Free           in   out     in   out
Act 2749488   20628 10344444    60420  167684  count     2
All 2792768   25576 14629708    76304          pages     4
Proc:                                                            Interrupts
  r   p   d   s   w   Csw  Trp  Sys  Int  Sof  Flt     21 cow    8236 total
  2     140 471       38k 9180 135k  225  63k 6927   6135 zfod        ata1 irq15
                                                          ozfod   225 mpt0 irq26
34.4%Sys   3.1%Intr 59.3%User  0.3%Nice  2.8%Idle        %ozfod  4005 cpu0: time
|    |    |    |    |    |    |    |    |    |    |       daefr  4006 cpu1: time
=================++>>>>>>>>>>>>>>>>>>>>>>>>>>>>>-    2162 prcfr
                                      1312 dtbuf     7597 totfr
Namei     Name-cache   Dir-cache    100000 desvn     9460 react
   Calls    hits   %    hits   %     53487 numvn          pdwak
   22102   21938  99                 24392 frevn          pdpgs
                                                          intrn
Disks   da0   da1 pass0 pass1                      501792 wire
KB/t  15.88  5.75  0.00  0.00                     2965052 act
tps     241     7     0     0                      331332 inact
MB/s   3.73  0.04  0.00  0.00                      143876 cache
%busy    38     3     0     0                       23808 free

查看是那头猪头进程在消耗cpu

%systat -pigs

                    /0   /1   /2   /3   /4   /5   /6   /7   /8   /9   /10
     Load Average   |||||||||||||

                    /0%  /10  /20  /30  /40  /50  /60  /70  /80  /90  /100
njava    php-cgi XXX
njava    php-cgi X

Tags: ,

星期六, 13 3 月, 2010 服务器

Leave a Reply

1LMooBmUE153Wnd3zDryWvDyXxQudbFxDr