Linux+IO性能测试方法.doc_第1页
Linux+IO性能测试方法.doc_第2页
Linux+IO性能测试方法.doc_第3页
Linux+IO性能测试方法.doc_第4页
Linux+IO性能测试方法.doc_第5页
已阅读5页,还剩1页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

Linux IO性能测试/administer/827851.html 开发环境系统配置如下:Intel SR1625 server , 2 CPU, 32GB内存, 用主板自带卡做了raid1+0,8个7200转SATA硬盘操作系统是RHEL 5.3 64位因为物理内存是32GB,因此整个过程都选用了60GB+的数据量来测试,以避免cache的影响1. 首先用自带的dd命令先测一下, 块大小为8kdd只能提供一个大概的测试结果,而且是连续IO而不是随机IO读测试# time dd if=/dev/sda2 of=/dev/null bs=8k count=83886088388608+0 records in8388608+0 records out68719476736 bytes (69 GB) copied, 516.547 seconds, 133 MB/sreal 8m36.926suser 0m0.117ssys 0m55.216s写测试# time dd if=/dev/zero of=/opt/iotest bs=8k count=83886088388608+0 records in8388608+0 records out68719476736 bytes (69 GB) copied, 888.398 seconds, 77.4 MB/sreal 14m48.743suser 0m3.678ssys 2m47.158s读写测试# time dd if=/dev/sda2 of=/opt/iotest bs=8k count=83886088388608+0 records in8388608+0 records out68719476736 bytes (69 GB) copied, 1869.89 seconds, 36.8 MB/sreal 31m10.343suser 0m2.613ssys 3m25.548s2. 接下来用Oracle 的orion 工具来测一下解压即可使用# gzip orion_linux_x86-64.gz测异步IO时需要libaio库# export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64# echo $LD_LIBRARY_PATH:/opt/oracle/product/10.2.0/lib:/usr/lib64创建配置文件mytest.lun,列出要测试的分区即可. 注意文件名前缀要跟下面的 testname一致# vi mytest.lun查看mytest.jun内容# cat mytest.lun/dev/sda2先来个simple test# ./orion_linux_x86-64 -run simple -testname mytest -num_disks 8查看测试结果# cat mytest_20081111_1431_summary.txtORION VERSION .0Commandline:-run simple -testname mytest -num_disks 8This maps to this test:Test: mytestSmall IO size: 8 KBLarge IO size: 1024 KBIO Types: Small Random IOs, Large Random IOsSimulated Array Type: CONCATWrite: 0%Cache Size: Not EnteredDuration for each Data Point: 60 secondsSmall Columns:, 0Large Columns:, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16Total Data Points: 38Name: /dev/sda2 Size: 6291434419201 FILEs found.Maximum Large MBPS=56.97 Small=0 and Large=7Maximum Small IOPS=442 Small=40 and Large=0Minimum Small Latency=14.62 Small=1 and Large=0最大MBPS为56.97,最大IOPS为442再测一下8k随机读操作# ./orion_linux_x86-64 -run advanced -testname mytest -num_disks 8 -size_small 8 -size_large 8 -type rand &看看结果# cat mytest_20081111_1519_summary.txtORION VERSION .0Commandline:-run advanced -testname mytest -num_disks 8 -size_small 8 -size_large 8 -type randThis maps to this test:Test: mytestSmall IO size: 8 KBLarge IO size: 8 KBIO Types: Small Random IOs, Large Random IOsSimulated Array Type: CONCATWrite: 0%Cache Size: Not EnteredDuration for each Data Point: 60 secondsSmall Columns:, 0Large Columns:, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16Total Data Points: 38Name: /dev/sda2 Size: 6291434419201 FILEs found.Maximum Large MBPS=3.21 Small=0 and Large=13Maximum Small IOPS=448 Small=38 and Large=0Minimum Small Latency=15.16 Small=1 and Large=0最大MBPS为3.21(这么低?),最大IOPS为448再测一下1M顺序读操作, 失败了, 原因不明.# ./orion_linux_x86-64 -run advanced -testname mytest -num_disks 8 -size_small 1024 -size_large 1024 -type seqORION: ORacle IO Numbers - Version .0mytest_20081114_1349Test will take approximately 73 minutesLarger caches may take longerrwbase_run_test: rwbase_reap_req failedrwbase_run_process: rwbase_run_test failedrwbase_rwluns: rwbase_run_process failedorion_warm_cache: Warming cache failed. Continuing看看结果# cat mytest_20081111_1620_summary.txtORION VERSION .0Commandline:-run advanced -testname mytest -num_disks 8 -size_small 1024 -size_large 1024 -type seqThis maps to this test:Test: mytestSmall IO size: 1024 KBLarge IO size: 1024 KBIO Types: Small Random IOs, Large Sequential StreamsNumber of Concurrent IOs Per Stream: 4Force streams to separate disks: NoSimulated Array Type: CONCATWrite: 0%Cache Size: Not EnteredDuration for each Data Point: 60 seconds没结果,失败3. 用iozone 来测一下安装 # tar -xvf iozone3_345.tar# make linux-AMD64指定64G的文件,只测read/reread和write/rewrite,记录大小从4k-16k.同时生成一个excel文件iozone.wks# ./iozone -Rab iozone.wks -s64G -i 0 -i 1 -y 4k -q 16kIozone: Performance Test of File I/OVersion $Revision: 3.345 $Compiled for 64 bit mode.Build: linux-AMD64Contributors:William Norcott, Don Capps, Isom Crawford, Kirby CollinsAl Slater, Scott Rhine, Mike Wisner, Ken GossSteve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,Fabrice Bacchella, Zhenghua Xue, Qin Li.Run began: Tue Nov 11 10:23:25 2008Excel chart generation enabledAuto ModeFile size set to 67108864 KBUsing Minimum Record Size 4 KBUsing Maximum Record Size 16 KBCommand line used: ./iozone -Rab iozone.wks -s64G -i 0 -i 1 -y 4k -q 16kOutput is in Kbytes/secTime Resolution = 0.000001 seconds.Processor cache size set to 1024 Kbytes.Processor cache line size set to 32 bytes.File stride size set to 17 * record size.random random bkwd record strideKB reclen write rewrite read reread read write read rewrite read fwrite frewrite fread freread67108864 4 72882 69470 104898 12551267108864 8 72083 69256 133689 10906167108864 16 73375 69155 142019 116034iozone test complete.Excel output is below:Writer report4 8 1667108864 72882 72083 73375Re-writer report4 8 1667108864 69470 69256 69155Reader report4 8 1667108864 104898 133689 142019Re-Reader report4 8 1667108864 125512 109061 116034可以看到,8k的写是72M/s左右,读是133M/s左右,跟dd的结果比较接近测一下64G文件8k随机读写# ./iozone -Rab iozone.wks -s64G -i 2 -y 8k -q 8kIozone: Performance Test of File I/OVersion $Revision: 3.345 $Compiled for 64 bit mode.Build: linux-AMD64Contributors:William Norcott, Don Capps, Isom Crawford, Kirby CollinsAl Slater, Scott Rhine, Mike Wisner, Ken GossSteve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,Fabrice Bacchella, Zhenghua Xue, Qin Li.Run began: Fri Nov 14 15:52:01 2008Excel chart generation enabledAuto ModeFile size set to 67108864 KBUsing Minimum Record Size 8 KBUsing Maximum Record Size 8 KBCommand line used: ./iozone -Rab iozone.wks -s64G -i 2 -y 8k -q 8kOutput is in Kbytes/secTime Resolution = 0.000001 seconds.Processor cache size set to 1024 Kbytes.Processor cache line size set to 32 bytes.File stride size set to 17 * record size.random random bkwd record strideKB reclen write rewrite read reread read write read rewrite read fwrite frewrite fread freread67108864 8Error reading block at 6501007360read: Success出错了(?)4. 最后用bonnie+ 测一下安装# export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64# ./configure# make# make install开始测试,默认文件大小是内存的2倍# bonnie+ -d /opt/IOTest/ -m sva17 -u rootUsing uid:0, gid:0.Writing with putc().doneWriting intelligently.doneRewriting.doneReading with getc().doneReading intelligently.donestart em.done.done.done.Create files in sequential order.done.Stat files in sequential order.done.Delete files in sequential order.done.Create files in random order.done.Stat files in random order.done.Delete files in random order.done.Version 1.03e -Sequential Output- -Sequential Input- -Random-Pe

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论