linux下测试磁盘IO读写速度
[root@node3 /]# time dd if=/dev/sda2 of=/dev/null bs=8k count=524288
524288+0 records in
524288+0 records out
4294967296 bytes (4.3 GB) copied, 37.4222 seconds, 115 MB/s
real 0m37.497s
user 0m0.036s
sys 0m1.320s
copy了4.3G的数据,平均速度为115M/s
[root@node3 /]# hdparm -t /dev/sda2
/dev/sda2:
Timing buffered disk reads: 284 MB in 3.00 seconds = 94.55 MB/sec
[root@node3 /]# hdparm -t /dev/sda2
/dev/sda2:
Timing buffered disk reads: 292 MB in 3.02 seconds = 96.82 MB/sec
读了将近300M的数据,平均速度大约为95M/s
经过以上的测试数据大体估算该磁盘的性能大约为100M/s