CN105511999A - 一种基于iozone的USB接口性能测试的方法 - Google Patents
一种基于iozone的USB接口性能测试的方法 Download PDFInfo
- Publication number
- CN105511999A CN105511999A CN201510915942.7A CN201510915942A CN105511999A CN 105511999 A CN105511999 A CN 105511999A CN 201510915942 A CN201510915942 A CN 201510915942A CN 105511999 A CN105511999 A CN 105511999A
- Authority
- CN
- China
- Prior art keywords
- test
- iozone
- usb interface
- performance test
- performance
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000011056 performance test Methods 0.000 title claims abstract description 24
- 238000000034 method Methods 0.000 title claims abstract description 23
- 238000012360 testing method Methods 0.000 claims abstract description 33
- 238000012986 modification Methods 0.000 abstract description 2
- 230000004048 modification Effects 0.000 abstract description 2
- 238000000638 solvent extraction Methods 0.000 abstract 1
- 238000012545 processing Methods 0.000 description 2
- 238000012356 Product development Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000007812 deficiency Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/26—Functional testing
- G06F11/267—Reconfiguring circuits for testing, e.g. LSSD, partitioning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2205—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
- G06F11/2221—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested to test input/output devices or peripheral units
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
本发明提供一种基于iozone的USB接口性能测试的方法,该方法的实现步骤如下:1)、识别本服务器通过USB接口所连接的存储模块;2)、对存储模块进行分区,挂载和格式化;3)、根据实际配置修改将测试参数传递给性能测试脚本;4)、开始性能测试,并输出结果。本方法摆脱了iozone单条测试命令的局限性,能够对多个存储模块同时进行多个线程的多种模式的读写性能测试。测试过程中的测试存储模块数量、线程数、测试块大小、测试文件大小、测试模式等都是可以根据实际需求进行手动调节。
Description
技术领域
本发明涉及计算机服务器技术领域,具体涉及一种基于iozone的USB接口性能测试的方法。
背景技术
随着IT领域技术的不断发展,传统信息化服务以及日趋强大的云计算服务对服务器的性能要求越来越高。USB接口做为数据传输的一种通道,其性能直接影响服务器的整体呈现。做为服务器硬件供应商,在产品开发时对于USB接口的性能测试需要更多的投入。
Shell脚本与Windows/Dos下的批处理相似,也就是用各类命令预先放入到一个文件中,方便一次性执行的一个程序文件,主要是方便管理员进行设置或者管理用的。但是它比Windows下的批处理更强大,比用其他编程程序编辑的程序效率更高。
Iozone是一个文件***的benchmark工具,可以测试不同的操作***中文件***的读写性能。可以测试Read,write,re-read,re-write,readbackwards,readstrided,fread,fwrite,randomread,pread,mmap,aio_read,aio_write等等不同的模式下的存储盘的性能。
但是iozone只提供了简单的参数,单条iozone命令有非常大的测试局限,如只能对一块存储盘进行测试,测试线程数控制难等。
基于上述技术,如果能够通过shell脚本,根据实际服务器配置来修改测试文件,并能够手动调整部分参数,这将对于多种多样的配置的性能测试带来便利和更高的效率。
发明内容
本发明的技术任务是针对现有技术的不足,提供一种基于iozone的USB接口性能测试的方法。本方法实用性强,可以对iozone的测试参数进行扩展,使之适应多种多样的性能测试需求的方法。
本发明解决其技术问题所采用的技术方案是:
一种基于iozone的USB接口性能测试的方法,该方法的实现步骤如下:
1)、识别本服务器通过USB接口所连接的存储模块;
2)、对存储模块进行分区,挂载和格式化;
3)、根据实际配置修改将测试参数传递给性能测试脚本;
4)、开始性能测试,并输出结果。
脚本执行完成后,在本文件夹中以hddext4开头的文件为最终结果。
本发明的一种基于iozone的USB接口性能测试的方法与现有技术相比,所产生的有益效果是,本方法摆脱了iozone单条测试命令的局限性,能够对多个存储模块同时进行多个线程的多种模式的读写性能测试。测试过程中的测试存储模块数量、线程数、测试块大小、测试文件大小、测试模式等都是可以根据实际需求进行手动调节。
附图说明
图1是基于iozone的USB接口性能测试的方法的流程图。
具体实施方式
下面结合附图和具体实施例对本发明的一种基于iozone的USB接口性能测试的方法与作以下详细地说明。
一种基于iozone的USB接口性能测试的方法,该方法的实现步骤如下:
1)、识别本服务器通过USB接口所连接的存储模块;
2)、对存储模块进行分区,挂载和格式化;
3)、根据实际配置修改将测试参数传递给性能测试脚本;
4)、开始性能测试,并输出结果。
脚本执行完成后,在本文件夹中以hddext4开头的文件为最终结果。
实施例
一、通过USB接口连接外部存储
1)识别本服务器所有的外接存储盘
#!/bin/bash
#判断输入参数个数,不符合时输出usage后退出
if[$#-ne2];then
echo“Usage:./$0RECSIZETHREADS_PERFHDD
exit0;
fi
#识别所有的盘符
functionget_disk()
{
fdisk-l|grep"Disk/dev/sd"|awk'{print$2|"cut-b8"}'>>/root/1.txt
foriin`cat/root/1.txt`
do
echo"/dev/sd$i">>/root/disk.lst
done
}
2)对外接存储进行分区,格式化和挂载
#分区
functionfdisk_disk()
{
fordiskin`cat/root/disk.lst`
do
#对外接存储盘分区
echo-e"fdisk$disknow..."
parted-s$diskmklabelgptmkpart$disk"1"1100gb
echo-e"Done"
fi
done
}
#格式化
functionmkfs_disk()
{
foriin`cat/root/1.txt`
do
if[$i=a]
then
mkfs.ext4/dev/sd$i"3"
else
mkfs.ext4/dev/sd$i"1"
fi
done
}
#挂载
functionmount_disk()
{
foriin`cat/root/1.txt`
if[$i=a]
then
mkdir/mnt/sd$i"3"
mount/dev/sd$i"3"/mnt/sd$i"3"
else
mkdir/mnt/sd$i"1"
mount/dev/sd$i"1"/mnt/sd$i"1"
fi
}
3)根据实际配置修改将测试参数传递给性能测试脚本
functioniozone_disk()
{
count=`cat/root/disk.txt|wc–l`#确定测试的存储盘个数
FILESIZE=10g#测试文件大小
RECSIZE=$1#测试块大小
THREADS=`echo“$2*$count”|bc`#测试总的线程数,根据硬盘数量和输入的每个硬盘的线程数决定
OUTPUTFILE=
#根据每个存储盘测试的线程数,确定测试文件
for((I=0;I<=$2;I++))
do
forJin`cat/root/1.txt`
do
FILE=$FILE"""/mnt/sd$J”1”/k${I}"
done
done
echo$FILE
forTIMESin{1..2}
do
OUTPUTFILE="hddext4_${THREADS}thrd_${FILESIZE}_recsize_${RECSIZE}_sep"
echo"ReadingandWritingtestStarting...">>$OUTPUTFILE
./iozone-r${RECSIZE}-s$FILESIZE-t$THREADS-F$FILE-i0-i1-breport.xls-c-+n-e>>$OUTPUTFILE
echo"ReadingandWritingtestFinished...">>$OUTPUTFILE
echo"">>$OUTPUTFILE
exit1
done
}
5)主程序
#按顺序执行分程序
get_disk
fdisk_disk
mkfs_disk
mount_disk
iozone_disk
二、脚本执行完成后,在本文件夹中以hddext4开头的文件为最终结果。
本方法在各种配置上都可以应用,可以灵活、便捷的根据不同配置修改测试参数来调用iozone测试USB接口性能。解决了单一使用iozone的测试局限性。丰富了测试手段,更好的检测部件的性能。
Claims (2)
1.一种基于iozone的USB接口性能测试的方法,其特征在于该方法的实现步骤如下:
1)、识别本服务器通过USB接口所连接的存储模块;
2)、对存储模块进行分区,挂载和格式化;
3)、根据实际配置修改将测试参数传递给性能测试脚本;
4)、开始性能测试,并输出结果。
2.根据权利要求1所述的一种基于iozone的USB接口性能测试的方法,其特征在于脚本执行完成后,在本文件夹中以hddext4开头的文件为最终结果。
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510915942.7A CN105511999A (zh) | 2015-12-10 | 2015-12-10 | 一种基于iozone的USB接口性能测试的方法 |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510915942.7A CN105511999A (zh) | 2015-12-10 | 2015-12-10 | 一种基于iozone的USB接口性能测试的方法 |
Publications (1)
Publication Number | Publication Date |
---|---|
CN105511999A true CN105511999A (zh) | 2016-04-20 |
Family
ID=55720001
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510915942.7A Pending CN105511999A (zh) | 2015-12-10 | 2015-12-10 | 一种基于iozone的USB接口性能测试的方法 |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105511999A (zh) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111858309A (zh) * | 2020-06-19 | 2020-10-30 | 浪潮电子信息产业股份有限公司 | 一种iozone测试方法、装置、设备及存储介质 |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030046396A1 (en) * | 2000-03-03 | 2003-03-06 | Richter Roger K. | Systems and methods for managing resource utilization in information management environments |
CN104657276A (zh) * | 2015-03-13 | 2015-05-27 | 浪潮集团有限公司 | 一种配置iozone集群测试的方法 |
CN104809042A (zh) * | 2015-04-27 | 2015-07-29 | 浪潮电子信息产业股份有限公司 | 一种基于iozone的硬盘性能测试的方法 |
CN104978250A (zh) * | 2015-06-23 | 2015-10-14 | 浪潮电子信息产业股份有限公司 | 一种基于iozone的HBA卡性能测试的方法 |
-
2015
- 2015-12-10 CN CN201510915942.7A patent/CN105511999A/zh active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030046396A1 (en) * | 2000-03-03 | 2003-03-06 | Richter Roger K. | Systems and methods for managing resource utilization in information management environments |
CN104657276A (zh) * | 2015-03-13 | 2015-05-27 | 浪潮集团有限公司 | 一种配置iozone集群测试的方法 |
CN104809042A (zh) * | 2015-04-27 | 2015-07-29 | 浪潮电子信息产业股份有限公司 | 一种基于iozone的硬盘性能测试的方法 |
CN104978250A (zh) * | 2015-06-23 | 2015-10-14 | 浪潮电子信息产业股份有限公司 | 一种基于iozone的HBA卡性能测试的方法 |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111858309A (zh) * | 2020-06-19 | 2020-10-30 | 浪潮电子信息产业股份有限公司 | 一种iozone测试方法、装置、设备及存储介质 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104809042A (zh) | 一种基于iozone的硬盘性能测试的方法 | |
CN103744759A (zh) | 一种Linux***下无人值守磁盘性能及稳定性验证方法 | |
CN104360919A (zh) | 一种自动进行ssd性能、功能及稳定性测试的方法 | |
US9607120B2 (en) | Implementing system irritator accelerator FPGA unit (AFU) residing behind a coherent attached processors interface (CAPI) unit | |
CN105260281A (zh) | 一种基于iozone的PCIE SSD卡性能测试的方法 | |
CN104850479A (zh) | 一种基于fio的硬盘自动化测试方法 | |
WO2021208512A1 (zh) | 用户界面的控件信息的获取方法、装置、终端及存储介质 | |
CN106682036A (zh) | 一种数据交换***及其交换方法 | |
CN106126421A (zh) | 一种自动测试并对比pcie‑ssd性能的方法 | |
CN106708627B (zh) | 一种基于kvm的多虚拟机映射、多通路的fuse加速方法及*** | |
CN106095528B (zh) | 一种检测虚拟机盘符的方法 | |
CN105487952A (zh) | 一种基于fio的pcie-ssd自动化测试方法 | |
CN108231132B (zh) | 一种nand闪存验证装置和验证*** | |
CN113282555A (zh) | 一种数据处理方法、装置、设备及存储介质 | |
CN104484685A (zh) | 一种批量发行智能卡的方法及*** | |
Tang et al. | Enabling transparent asynchronous I/O using background threads | |
CN107273251A (zh) | 一种在生产环境下Rack机柜JBOD存储的测试方法 | |
CN106649018A (zh) | 一种带扩展柜的存储***稳定性的测试方法 | |
CN104978250A (zh) | 一种基于iozone的HBA卡性能测试的方法 | |
CN105468488A (zh) | 一种基于ib网络的无盘测试cpu的方法、装置及*** | |
US10956294B2 (en) | Methods and systems for testing storage devices via a representative I/O generator | |
CN105511999A (zh) | 一种基于iozone的USB接口性能测试的方法 | |
CN109510740A (zh) | 一种自动监控网卡mtu值的方法、装置、终端及存储介质 | |
US7823018B2 (en) | Methods, systems and computer program products for CPU signaturing to aide in performance analysis | |
CN107885644A (zh) | 一种基于Linux***下快速查看BIOS默认值的方法 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20160420 |