Server Monitoring using vmstat

iostat / vmstat / mpstat are some tools to monitor server performance. 

 * iostat reports CPU, disk I/O, and NFS statistics.

 * vmstat reports virtual memory statistics.

 *  mpstat reports processors statictics.

 # vmstat

 procs -----------memory-----------------          ---swap-- ------io---- ---system-- -----cpu--
 r  b    swpd     free     buff        cache   si   so    bi    bo   in   cs us sy id wa st
 1  0  196112  75232 151884 611352   0    0     8     91   45   40 20  9 71  0  0

 vmstat output contains the following fields:

    Procs – r: Total number of processes waiting to run
    Procs – b: Total number of busy processes
    Memory – swpd: Used virtual memory
    Memory – free: Free virtual memory
    Memory – buff: Memory used as buffers
    Memory – cache: Memory used as cache.
    Swap – si: Memory swapped from disk (for every second)
    Swap – so: Memory swapped to disk (for every second)
    IO – bi:  Blocks in. i.e blocks received from device (for every second)
    IO – bo:  Blocks out. i.e blocks sent to the device (for every second)
    System –  in: Interrupts per second
    System –  cs: Context switches
    CPU – us, sy, id, wa, st: CPU user time, system time, idle time, wait time

Display active and inactive memory
# vmstat -a

procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu------
 r  b   swpd   free    inact    active    si   so    bi    bo   in  cs us  sy id wa st
 1  0  196112  75236 224864  787620    0    0     8    91   45   41 20  9 71  0  0

Display number of forks since last boot

This displays all the fork system calls made by the system since the last boot.

  # vmstat -f
       500235 forks  

Execute Every x seconds
# vmstat 2
# vmstat 2 5

Display slab info
# vmstat -m

Display statistics in a table format
# vmstat -s

Display disk statistics
# vmstat -d

Display statistics for a partition
 # vmstat -p /dev/sda1

Display in MB
# vmstat -S m


Terima kasih telah membaca artikel tentang Server Monitoring using vmstat di blog Tutorial Opensource and Linux jika anda ingin menyebar luaskan artikel ini di mohon untuk mencantumkan link sebagai Sumbernya, dan bila artikel ini bermanfaat silakan bookmark halaman ini di web browser anda, dengan cara menekan Ctrl + D pada tombol keyboard anda.

Artikel terbaru :

  • How To Install Cinnamon In Ubuntu 14.04
  • How To Install Mate Desktop In Ubuntu 14.04
  • Creating the first Windows Server 2003 Domain Controller in a domain
  • How To Install Ubuntu 13.10 Server
  • How to Install Nuvola Player in Ubuntu
  • How to establish Emerald in Ubuntu 13.10 & Linux Mint 16
  • How to Restoring iptables Automatically On Boot on Debian and Ubuntu
  • How to Compile FFMPEG with H.264 and LAME in Ubuntu And Debian
  • How to Install Linux on a Playstation 2
  • apt-fast: Improve apt-get Download Speed
  • Artikel terkait :