Lustre 性能测试方法
2011-09-15 16:35
218 查看
1. 单个裸设备性能测试:/usr/bin/sgpdd-survey
安装包:sg3_utils, 包含了sgpdd-survey需要的命令”sg_map”
注意: 对大分区,sg_readcap会报一行错误,然后给出结果,这个错误会导致spgdd-survey报错
# sg_readcap/dev/sdb
READ CAPACITY(10) indicates device capacity too large
now trying 16 byte cdb variant
解决方法是把/usr/bin/sgpdd-survey中所有的 “sg_readcap–b”,换成”sg_readcap –l -b”
测试前提是:
/sys/block/sdN/queue/max_sectors_kb= 4096
/sys/block/sdN/queue/max_phys_segments= 256
/proc/scsi/sg/allow_dio= 1
/sys/module/ib_srp/parameters/srp_sg_tablesize= 255
如果要测试16个进程,每个进程写读一块区域,总共64GB大小的数据,每次读写块大小为1MB 应该设置测试命令为:
size=65536 rszlo=1024 rszhi=1024crglo=16 crghi=16 thrlo=16 thrhi=16 scsi-devs=/dev/sdX sh sgpdd-survey
结果示例:
Thu Sep 1511:49:57 CST 2011 sgpdd-survey on /dev/sdX from X.Y
total_size 8388608K rsz 1024 crg 1 thr 1 write 246.77 MB/s 1 x 246.81 = 246.81 MB/s read 281.40 MB/s 1 x 281.45 = 281.45 MB/s
total_size 8388608K rsz 1024 crg 1 thr 2 write 305.75 MB/s 1 x 305.81 = 305.81 MB/s read 373.08 MB/s 1 x 373.17 = 373.17 MB/s
….
出错信息示例:
total_size 8388608K rsz 1024 crg 64 thr 256 write 7 failed read 10 failed
total_size 8388608K rsz 1024 crg 64 thr 512 write 28 failed read 27 failed
total_size 8388608K rsz 1024 crg 64 thr 1024 write 47 failed read 45 failed
2. 单个OST本地性能测试:/usr/bin/obdfilter-survey
前提:将设备mount成lustre模式
如果要在一个OST测试16个进程,每个进程写读一个object,总共64GB大小的数据,每次读写块大小为1MB 应该设置测试命令为,默认块大小为1M,可以用:
size=65536 nobjlo=16rszlo=1024 rszhi=1024thrlo=16 nobjhi=16 thrhi=16 case=disk sh obdfilter-survey
结果示例:
Thu Sep 15 16:06:09 CST 2011Obdfilter-survey for case=disk from X.Y
ost 1 sz 67108864K rsz 1024K obj 16thr 16 write 329.33 [ 119.88, 343.66] rewrite 327.31 [ 286.71, 335.67] read 348.52 [ 177.82, 368.63]
done!
3. I/Ozone 测试脚本
前提:安装iozone
在客户端mount了lustre
如果要在多个客户端运行多线程测试,测试发起节点,需要
#!/bin/bash
j=1
for (( i=0;i<=2;i++)) do
j=$(($j+$i*20))
#iozone -t $j -i 0 -i 1 -i 5 -j 2M -s $((20000/$j))M -r 1M -Rbresult$j.xls | tee result$j.log
echo $j
j=0
done
注: 测试1,20, 40 个(-t)进程读(-i 0),写(-i 1),跳读(-i 5)(每次跳读区域为-j 2MB,总共–s 20GB数据的性能,测试结果输出到Excel文件(-Rb),日志输出到log文件
4. dd 测试
#!/bin/bash
while true
do
filename=”/mountpoint/$HOSTNAME-$$-$RANDOM"
dd if=/dev/zero of="$filename" bs=1M count=10000
sleep 1
rm "$filename"
done
安装包:sg3_utils, 包含了sgpdd-survey需要的命令”sg_map”
注意: 对大分区,sg_readcap会报一行错误,然后给出结果,这个错误会导致spgdd-survey报错
# sg_readcap/dev/sdb
READ CAPACITY(10) indicates device capacity too large
now trying 16 byte cdb variant
解决方法是把/usr/bin/sgpdd-survey中所有的 “sg_readcap–b”,换成”sg_readcap –l -b”
测试前提是:
/sys/block/sdN/queue/max_sectors_kb= 4096
/sys/block/sdN/queue/max_phys_segments= 256
/proc/scsi/sg/allow_dio= 1
/sys/module/ib_srp/parameters/srp_sg_tablesize= 255
如果要测试16个进程,每个进程写读一块区域,总共64GB大小的数据,每次读写块大小为1MB 应该设置测试命令为:
size=65536 rszlo=1024 rszhi=1024crglo=16 crghi=16 thrlo=16 thrhi=16 scsi-devs=/dev/sdX sh sgpdd-survey
结果示例:
Thu Sep 1511:49:57 CST 2011 sgpdd-survey on /dev/sdX from X.Y
total_size 8388608K rsz 1024 crg 1 thr 1 write 246.77 MB/s 1 x 246.81 = 246.81 MB/s read 281.40 MB/s 1 x 281.45 = 281.45 MB/s
total_size 8388608K rsz 1024 crg 1 thr 2 write 305.75 MB/s 1 x 305.81 = 305.81 MB/s read 373.08 MB/s 1 x 373.17 = 373.17 MB/s
….
出错信息示例:
total_size 8388608K rsz 1024 crg 64 thr 256 write 7 failed read 10 failed
total_size 8388608K rsz 1024 crg 64 thr 512 write 28 failed read 27 failed
total_size 8388608K rsz 1024 crg 64 thr 1024 write 47 failed read 45 failed
2. 单个OST本地性能测试:/usr/bin/obdfilter-survey
前提:将设备mount成lustre模式
如果要在一个OST测试16个进程,每个进程写读一个object,总共64GB大小的数据,每次读写块大小为1MB 应该设置测试命令为,默认块大小为1M,可以用:
size=65536 nobjlo=16rszlo=1024 rszhi=1024thrlo=16 nobjhi=16 thrhi=16 case=disk sh obdfilter-survey
结果示例:
Thu Sep 15 16:06:09 CST 2011Obdfilter-survey for case=disk from X.Y
ost 1 sz 67108864K rsz 1024K obj 16thr 16 write 329.33 [ 119.88, 343.66] rewrite 327.31 [ 286.71, 335.67] read 348.52 [ 177.82, 368.63]
done!
3. I/Ozone 测试脚本
前提:安装iozone
在客户端mount了lustre
如果要在多个客户端运行多线程测试,测试发起节点,需要
#!/bin/bash
j=1
for (( i=0;i<=2;i++)) do
j=$(($j+$i*20))
#iozone -t $j -i 0 -i 1 -i 5 -j 2M -s $((20000/$j))M -r 1M -Rbresult$j.xls | tee result$j.log
echo $j
j=0
done
注: 测试1,20, 40 个(-t)进程读(-i 0),写(-i 1),跳读(-i 5)(每次跳读区域为-j 2MB,总共–s 20GB数据的性能,测试结果输出到Excel文件(-Rb),日志输出到log文件
4. dd 测试
#!/bin/bash
while true
do
filename=”/mountpoint/$HOSTNAME-$$-$RANDOM"
dd if=/dev/zero of="$filename" bs=1M count=10000
sleep 1
rm "$filename"
done
相关文章推荐
- 性能测试监控工具nmon安装及使用方法
- python 字典(dict)遍历的四种方法性能测试报告
- Web性能测试和CC攻击和方法和防范
- 老李谈性能测试调优方法
- 最新的性能测试用例设计方法
- 一种简单的数据库性能测试方法
- android APP 性能测试方法
- 静态方法,实例方法,反射调用性能测试
- PHP性能测试工具xhprof安装与使用方法详解
- Jmeter进行性能测试时多台负载机的配置方法
- C#中实现并发的几种方法以及其性能测试
- 老李谈性能测试调优方法
- 数据库非共享集群性能测试方法研究
- Jmeter实现WebSocket协议的接口和性能测试方法
- C#测试代码、函数、方法执行时间,方便进行系统性能评估
- 干货|性能测试模型初探及应用方法分析
- (转)性能测试之----瓶颈分析方法
- 服务器性能测试方法培训文档--本人于2014年2月编写
- Jmeter实现WebSocket协议的接口和性能测试方法
- Java性能优化指南系列(一):概述和性能测试方法