Hdparm slow server

hdparm

My web site server is very slow and I contacted my hosting company. This company ask me to execute this command line:

hdparm -tT /dev/sda

The result is here:

/dev/sda:
 Timing cached reads:   1112 MB in  2.00 seconds = 555.55 MB/sec
 Timing buffered disk reads:    4 MB in  4.80 seconds = 854.16 kB/sec

I don't understand what it means, I read the man but can you explain me clearly what this result means.

Thanks a lot.

Best Answer

First, that is ridiculously slow ... as in slower than internet access slow. Our web server, which cost only $1800 almost 7 years ago, gives these stats for hdparm -tT :

 Timing buffer-cache reads:   1836 MB in  2.00 seconds = 918.00 MB/sec
 Timing buffered disk reads:   98 MB in  1.95 seconds =  50.26 MB/sec

The first speed shows how fast disk reads are if the data is already buffered. The disk is never accessed, so it is probably pretty meaningless for a web server (since most of the time disk reads will probably not be buffered).

The second stat shows real hard drive read performance. In your case, it means that the web server is reading under 1 MB/sec. If you have a database on the same server, it should be moved to a separate server, as scanning even small tables could take seconds.