Installing iostat in CentOS with yum

Iostat is a very powerful tool for monitoring the throughput of your storage subsystems. Especially to locate bottle necks and pinpoint possible upgrade scenarios. Not immediately visible here is how to install it on Centos 5.x and 6.x.

We shall use the whatprovides tool in yum to locate the packages that provide iostat

 

[root@torino ~]# yum whatprovides */iostat
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: it.centos.contactlab.it
 * epel: mirror.karneval.cz
 * extras: it.centos.contactlab.it
 * updates: mirror.bofh.so
base/filelists_db | 4.9 MB 00:10 
epel/filelists_db | 4.8 MB 00:10 
extras/filelists_db | 2.7 kB 00:00 
google-chrome/filelists | 1.1 kB 00:00 ... 
updates/filelists_db | 939 kB 00:02 
sysstat-9.0.4-20.el6.i686 : The sar and iostat system monitoring commands
Repo : base
Matched from:
Filename : /usr/bin/iostat

munin-node-1.4.7-5.el5.noarch : Network-wide graphing framework (node)
Repo : epel
Matched from:
Filename : /usr/share/munin/plugins/iostat

sysstat-9.0.4-20.el6.i686 : The sar and iostat system monitoring commands
Repo : installed
Matched from:
Filename : /usr/bin/iostat

After selecting the package we want (usually depending on which other tools we would like to have and also compatibility with other packages might be issues.

[root@torino ~]# yum install sysstat
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.crazynetwork.it
 * epel: mirrors.ircam.fr
 * extras: mirror.crazynetwork.it
 * updates: mirror.crazynetwork.it
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package sysstat.i386 0:7.0.2-11.el5 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

=======================================================================
 Package         Arch         Version               Repository    Size
=======================================================================
Installing:
 sysstat         i386         7.0.2-11.el5          base         182 k

Transaction Summary
=======================================================================
Install       1 Package(s)
Upgrade       0 Package(s)

Total download size: 182 k
Is this ok [y/N]: y
Downloading Packages:
sysstat-7.0.2-11.el5.i386.rpm                   | 182 kB     00:00     
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing     : sysstat                                         1/1 

Installed:
  sysstat.i386 0:7.0.2-11.el5                                          

Complete!
[root@torino ~]#

Once this is completed iostat should work

[root@torino ~]# iostat
Linux 2.6.18-308.11.1.el5xen (torino.maranello.local)    07/29/2012

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           8.82    0.13   59.54    0.54   18.06   12.90

Device:            tps   Blk_read/s   Blk_wrtn/s   Blk_read   Blk_wrtn
sda              66.83       120.54       430.63    4363863   15590257
sda1              0.00         0.05         0.00       1705         38
sda2              2.36        29.78        48.65    1078098    1761448
sda3             64.47        90.66       381.98    3282189   13828771
sda4              0.00         0.00         0.00          8          0
sda5              0.00         0.04         0.00       1439          0
hdc               0.31        58.13         0.00    2104380          0

[root@torino ~]#

Yeah !! See you around ..

Leave a Reply

Your email address will not be published. Required fields are marked *