CN107908517A - 一种基于shell脚本的CPU压力测试方法 - Google Patents

一种基于shell脚本的CPU压力测试方法 Download PDF

Info

Publication number
CN107908517A
CN107908517A CN201711286035.6A CN201711286035A CN107908517A CN 107908517 A CN107908517 A CN 107908517A CN 201711286035 A CN201711286035 A CN 201711286035A CN 107908517 A CN107908517 A CN 107908517A
Authority
CN
China
Prior art keywords
volume
cpu
testing pressure
pressure based
shell scripts
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.)
Granted
Application number
CN201711286035.6A
Other languages
English (en)
Other versions
CN107908517B (zh
Inventor
庄甲平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201711286035.6A priority Critical patent/CN107908517B/zh
Publication of CN107908517A publication Critical patent/CN107908517A/zh
Application granted granted Critical
Publication of CN107908517B publication Critical patent/CN107908517B/zh
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2205Detection 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/2236Detection 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 CPU or processors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2273Test methods

Abstract

本申请发明一种基于shell脚本的CPU压力测试方法。通过循环shell脚本设计,创建不同MDISK、卷,包括自精简卷、压缩卷、镜像卷等,并通过综合几种卷操作来提高CPU使用压力。本申请发明压力测试方法不仅针对于存储系统CPU使用率进行测试,同时可针对于MCS自体的性能统计分析工具,能够快速提高性能统计里的MCS系统CPU占用率,为实际测试过程中实现MCS系统CPU压力提供了一种切实可行的方法。

Description

一种基于shell脚本的CPU压力测试方法
技术领域
本发明涉及服务器测试领域,具体涉及一种基于shell脚本的CPU压力测试方法。
背景技术
CPU是电脑中最为核心的部件之一。当CPU出现性能问题的时候,就会导致整个电脑系统的运行不稳定。
MCS系统是基于Linux内核的精简linux。为了保证MCS系统稳定性及可靠性,运行在Linux系统的大部分的普通命令并不能运行在MCS系统下面,MCS对相关命令进行了私有化设置。另外MCS系统下设计了一个可以实时统计CPU使用率的内核插件,GUI界面下的性能统计的CPU使用率就依赖于这个MCS下内核插件,因此单纯的通过提高linux系统CPU使用率并不能触发MCS系统的CPU使用率升高或者超过相应的阈值,要想使MCS系统CPU使用率的升高,根本的解决方法是让存储端持续执行占用CPU使用的操作。
针对上述问题,本申请发明一种基于shell脚本的CPU压力测试方法。通过循环shell脚本设计,创建不同MDISK、卷,包括自精简卷、压缩卷、镜像卷等,并通过综合几种卷操作来提高CPU使用压力。
发明内容
本发明通过循环shell脚本创建不同MDISK、卷的方法,包括自精简卷、压缩卷、镜像卷等,并通过综合执行几种卷操作来提高CPU使用压力进而进行测试。
具体地,本申请请求保护一种基于shell脚本的CPU压力测试方法,其特征在于,该方法具体包括:
确定硬盘数量和ID;
每3块硬盘创建1个RAID5的MDISK;
Get 1/2Pool容量;
输入需要创建的卷的个数;
根据Pool容量创建多个类型卷;
对每个卷进行多种操作;
将所有现有卷映射到前端服务器;
前端服务器使用IOmeter进行4KB小数据块范围随机读写操作;
使用性能统计工具实时输出CPU使用情况。
如上所述的基于shell脚本的CPU压力测试方法,其特征还在于,根据Pool容量创建多个类型卷包括自精简卷、压缩卷和镜像卷。
如上所述的基于shell脚本的CPU压力测试方法,其特征还在于,对每个卷进行多种操作可以是卷镜像、卷复制、快照。
如上所述的基于shell脚本的CPU压力测试方法,其特征还在于,前端服务器是双服务器端。
如上所述的基于shell脚本的CPU压力测试方法,其特征还在于,该使用性能统计工具是MCS利用率分析工具lssystemstats。
附图说明
图1、本发明所述压力测试方法工作流程图
具体实施方式
本发明所述的基于shell脚本的CPU压力测试方法,可运行在简化版的基于linux内核的MCS系统下,采用bash shell脚本进行语言设计,并使用MCS利用率分析工具lssystemstats这个内核插件查看CPU使用率,通过运行shell脚本循环创建镜像卷、压缩卷、自精简卷,并对所有现有卷循环进行卷镜像、卷复制、快照等操作。
该方法包括以下几个步骤:
1、确定硬盘数量、ID,执行每3块硬盘建立类型为RAID5的MDISK的脚本;
2、Get 1/2Pool容量;
3、根据Pool容量执行创建每Volume 200G的自精简卷、压缩卷和镜像卷脚本;
4、执行对每个卷进行快照、备份、克隆的脚本文件;
5、将所有现有卷映射到双服务器端,双服务器端使用IOmeter进行4KB小数据块范围随机读写操作;
6、使用lssystemstats性能统计命令实时输出CPU使用情况。
通过这种方式,可以针对基于linux内核的MCS系统对CPU进行压力测试。
部分shell脚本的内容如下:
显而易见地,上面所示的仅仅是本发明的一个具体实施方式,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据上述实施例获得其他的技术方案,以及在本发明保护的范围内做出的等同变化均应落入本发明的保护范围内,都属于本发明保护的范围。
综上所述,本申请发明压力测试方法不仅针对于存储系统CPU使用率进行测试,同时可针对于MCS自体的性能统计分析工具,能够快速提高性能统计里的MCS系统CPU占用率,为实际测试过程中实现MCS系统CPU压力提供了一种切实可行的方法。

Claims (5)

1.一种基于shell脚本的CPU压力测试方法,其特征在于,该方法具体包括:
确定硬盘数量和ID;
每3块硬盘创建1个RAID5的MDISK;
Get 1/2Pool容量;
输入需要创建的卷的个数;
根据Pool容量创建多个类型卷;
对每个卷进行多种操作;
将所有现有卷映射到前端服务器;
前端服务器使用IOmeter进行4KB小数据块范围随机读写操作;
使用性能统计工具实时输出CPU使用情况。
2.如权利要求1所述的基于shell脚本的CPU压力测试方法,其特征还在于,根据Pool容量创建多个类型卷包括自精简卷、压缩卷和镜像卷。
3.如权利要求2所述的基于shell脚本的CPU压力测试方法,其特征还在于,对每个卷进行多种操作包括卷镜像、卷复制、快照。
4.如权利要求3所述的基于shell脚本的CPU压力测试方法,其特征还在于,前端服务器是双服务器端。
5.如权利要求4所述的基于shell脚本的CPU压力测试方法,其特征还在于,该使用性能统计工具是MCS利用率分析工具lssystemstats。
CN201711286035.6A 2017-12-07 2017-12-07 一种基于shell脚本的CPU压力测试方法 Active CN107908517B (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711286035.6A CN107908517B (zh) 2017-12-07 2017-12-07 一种基于shell脚本的CPU压力测试方法

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711286035.6A CN107908517B (zh) 2017-12-07 2017-12-07 一种基于shell脚本的CPU压力测试方法

Publications (2)

Publication Number Publication Date
CN107908517A true CN107908517A (zh) 2018-04-13
CN107908517B CN107908517B (zh) 2021-07-13

Family

ID=61853833

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711286035.6A Active CN107908517B (zh) 2017-12-07 2017-12-07 一种基于shell脚本的CPU压力测试方法

Country Status (1)

Country Link
CN (1) CN107908517B (zh)

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050193269A1 (en) * 2000-03-27 2005-09-01 Accenture Llp System, method, and article of manufacture for synchronization in an automated scripting framework
US20080307178A1 (en) * 2007-05-31 2008-12-11 International Business Machines Corporation Data migration
CN101354667A (zh) * 2007-07-24 2009-01-28 英业达股份有限公司 一种外围组件互连总线级压力测试方法
CN101833493A (zh) * 2010-03-24 2010-09-15 浪潮电子信息产业股份有限公司 一种基于linux系统下服务器稳定性可靠性的测试方法
CN102411526A (zh) * 2011-12-31 2012-04-11 曙光信息产业股份有限公司 一种用于刀片服务器主板的测试方法
CN103000228A (zh) * 2011-09-08 2013-03-27 上海宝信软件股份有限公司 存储设备的测试方法及系统
CN104407951A (zh) * 2014-11-05 2015-03-11 浪潮电子信息产业股份有限公司 一种自动化进行服务器整机测试的方法
US20160132090A1 (en) * 2013-07-17 2016-05-12 Fujitsu Limited Cluster system, controller, method for controlling, and computer-readable recording medium having stored therein controlling program
CN106326067A (zh) * 2016-08-05 2017-01-11 浪潮电子信息产业股份有限公司 一种在压力测试下对cpu性能进行监控的方法及装置
CN206489220U (zh) * 2017-02-17 2017-09-12 河南工业职业技术学院 一种基于单片机微电阻测量系统
CN107402833A (zh) * 2017-06-23 2017-11-28 郑州云海信息技术有限公司 一种对存储系统上的功能模块进行自动测试的方法

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050193269A1 (en) * 2000-03-27 2005-09-01 Accenture Llp System, method, and article of manufacture for synchronization in an automated scripting framework
US20080307178A1 (en) * 2007-05-31 2008-12-11 International Business Machines Corporation Data migration
CN101354667A (zh) * 2007-07-24 2009-01-28 英业达股份有限公司 一种外围组件互连总线级压力测试方法
CN101833493A (zh) * 2010-03-24 2010-09-15 浪潮电子信息产业股份有限公司 一种基于linux系统下服务器稳定性可靠性的测试方法
CN103000228A (zh) * 2011-09-08 2013-03-27 上海宝信软件股份有限公司 存储设备的测试方法及系统
CN102411526A (zh) * 2011-12-31 2012-04-11 曙光信息产业股份有限公司 一种用于刀片服务器主板的测试方法
US20160132090A1 (en) * 2013-07-17 2016-05-12 Fujitsu Limited Cluster system, controller, method for controlling, and computer-readable recording medium having stored therein controlling program
CN104407951A (zh) * 2014-11-05 2015-03-11 浪潮电子信息产业股份有限公司 一种自动化进行服务器整机测试的方法
CN106326067A (zh) * 2016-08-05 2017-01-11 浪潮电子信息产业股份有限公司 一种在压力测试下对cpu性能进行监控的方法及装置
CN206489220U (zh) * 2017-02-17 2017-09-12 河南工业职业技术学院 一种基于单片机微电阻测量系统
CN107402833A (zh) * 2017-06-23 2017-11-28 郑州云海信息技术有限公司 一种对存储系统上的功能模块进行自动测试的方法

Also Published As

Publication number Publication date
CN107908517B (zh) 2021-07-13

Similar Documents

Publication Publication Date Title
WO2017012392A1 (zh) 一种磁盘检测的方法和装置
US9311176B1 (en) Evaluating a set of storage devices and providing recommended activities
US20160149828A1 (en) Clustered storage system path quiescence analysis
CN104850480B (zh) 高密度存储服务器硬盘性能测试的方法及装置
US20130197863A1 (en) Performance and capacity analysis of computing systems
CN104022913B (zh) 用于数据集群的测试方法和装置
CN102243599A (zh) 根据资源使用率易失性管理分区计算系统的资源的系统和方法
Gunasekaran et al. Comparative I/O workload characterization of two leadership class storage clusters
CN106919380B (zh) 利用基于向量估计的图分割的计算装置的数据流编程
CN103399797A (zh) 服务器资源配置方法及装置
US9317387B2 (en) Methods and systems for reducing metrics used to monitor resources
US11487462B2 (en) Method and device of predicting inter-volume copy time based on inter-pool copy speed
CN110780821A (zh) 分布式存储系统的优化方法、装置、服务器和存储介质
CN101883019A (zh) 一种验证存储服务器是否满足视频应用的测试方法
CN107908517A (zh) 一种基于shell脚本的CPU压力测试方法
US20130318499A1 (en) Test script generation
CN112764979A (zh) 一种硬盘压力测试强度控制方法、系统及介质
Méndez et al. Modeling parallel scientific applications through their input/output phases
CN107729200A (zh) 一种存储系统性能的测试方法及相关装置
CN117009196A (zh) 一种企业级固态硬盘的性能测试方法、测试装置和测试平台
US9513839B2 (en) Management system and management method for computer system comprising remote copy system for performing asynchronous remote copy
CN107145414B (zh) 一种用于测试分布式对象存储的方法和系统
US10509808B2 (en) Data analysis support system and data analysis support method
CN103902421A (zh) 一种企业eda设计平台运行环境基础性能测试方法
CN109542695A (zh) 确定逻辑存储单元性能的方法和装置

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant