LinTut

Dstat linux monitoring tools

dstat monitoring tool

Dstat is a versatile replacement for vmstat, iostat, netstat and ifstat. Dstat overcomes some of their limitations and adds some extra features, more counters and flexibility. Dstat is handy for monitoring systems during performance tuning tests, benchmarks or troubleshooting.
Dstat allows you to view all of your system resources in real-time, you can eg. compare disk utilization in combination with interrupts from your IDE controller, or compare the network bandwidth numbers directly with the disk throughput (in the same interval).
Dstat gives you detailed selective information in columns and clearly indicates in what magnitude and unit the output is displayed. Less confusion, less mistakes. And most importantly, it makes it very easy to write plugins to collect your own counters and extend in ways you never expected.
Dstat’s output by default is designed for being interpreted by humans in real-time, however you can export details to CSV output to a file to be imported later into Gnumeric or Excel to generate graphs.

Features

Install dstat on Ubuntu 12.10/13.04/13.10/14.04 and Linux Mint 12/13/14/15/16

To install dstat on Ubuntu 12.10/13.04/13.10/14.04 and Linux Mint 12/13/14/15/16 enter following command:

# sudo apt-get install dstat

Install dstat on RHEL/CentOS 5.x/6.x and fedora 16/17/18/19/20

First, install rpmforge repository and enter folloving command:

# yum install dstat

Getting started with dstat

Now dstat should be installed and ready to display your systems performance stats.
In its simplest form dstat can be invoked by issuing the command : dstat

# dstat
Example dstat output
# dstat -c --top-cpu -d --top-bio --top-latency
dstat -c –top-cpu -d –top-bio –top-latency

To send the output to a csv file for later use we can issue the following command:

# dstat --output /tmp/sampleoutput.csv -cdn

Sample csv file

Other options available to dstat:

Dstat options:

For a full list of all the options available, issue the command: dstat –help