Checking and identifying server bottlenecks caused by hard drive DISK READ / DISK WRITE operations with iotop on Linux

Thursday, 25th November 2010

As a server system administrator. Every now and then I have an overloading servers, where it is crucial to find the exact reason
for the server overloads / crashes.

In many occasions the top or htop are not enough for me to quickly get a server overload caused by a hard drive i/o operations.

When I got this kind of unusual problems caused by hard drives overheats, the system load avarage numbers increase tremendously. Still I had that cases in which the top shows only a couple of percents of server load and it seems initially like the problem is a kind of mystery.

At that cases I usually check the Hard Disk Drive (HDD) disk I/O operations to determine if, the file read and writes of the server are not exceeding the maximum amount of symultaneous read and writes a hard drive can support, or some kind of hardware problem is not causing a hard drive temperature overheats.

Of course the server hang ups caused by hard disk read or writes slowliness is not news but still it’s something that some administrators does fail to think about or even check and therefore often server access problems appear again and again for quite some time until the problem is identified and resolved.

Thus I wrote this small article to mention about the importance of the Linux System administrator to always have the iostat or sysstat utilities at hand and regularly use them to check the hard drive disk and writes to be sure server overloads doesn’t root at the hard drive read and write opeartions.

This is an absolutely necessary practice especially for busy servers.

My personal experience on the disk caused server slowliness and hangs are that this kind of problems with hard drive overheats more often occurs on servers running either an old hard ATA hard drives, or on Linux machines running Webserver or FTP, Samba etc. in which rapid file transfers from a huge number of clients is being requested or processed.

In that kind of shitty situations, installing and using the iotop will show you statistics about your hard drives Total DISK READ and DISK WRITES and will thus give you a hint if there is a server bottleneck caused by the harddrive.

The iostat is available for Debian package and installing it comes to;


debian:~# apt-get install iotop

Hope this article helps to some lame admin like me out there 🙂

Share this on:

Download PDFDownload PDF

Tags:

One Response to “Checking and identifying server bottlenecks caused by hard drive DISK READ / DISK WRITE operations with iotop on Linux”

  1. hip0 says:
    Epiphany 2.30.6 Epiphany 2.30.6 Debian GNU/Linux x64 Debian GNU/Linux x64
    Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6

    I forgot to mention in the article to also check out also iostat, it’s very valuable and is the next best one every admin should have it’s part of sysstat package. It returns info about hdd similar to the one below;

    avg-cpu: %user %nice %system %iowait %steal %idle
    0.21 0.01 0.06 0.07 0.00 99.65

    Device: tps Blk_read/s Blk_wrtn/s Blk_read Blk_wrtn
    sda 5.32 45.34 187.02 269999730 1113765460
    sda1 0.00 0.00 0.01 3888 53740
    sda2 0.00 0.03 0.11 180480 672648
    sda3 5.32 45.31 186.90 269814034 1113039072
    sdb 5.31 44.70 187.02 266175478 1113765460
    sdb1 0.00 0.00 0.01 4158 53740
    sdb2 0.00 0.03 0.11 173920 672648
    sdb3 5.31 44.67 186.90 265996072 1113039072
    md2 24.39 89.97 182.74 535807658 1088282016
    md1 0.02 0.06 0.11 352016 657016
    md0 0.00 0.00 0.01 5662 52332

    This is quite a lot and nice info about hard drive operations,isn’t it 🙂

    View CommentView Comment

Leave a Reply

CommentLuv badge