CN104866402A - Server testing method and apparatus - Google Patents
Server testing method and apparatus Download PDFInfo
- Publication number
- CN104866402A CN104866402A CN201510239625.8A CN201510239625A CN104866402A CN 104866402 A CN104866402 A CN 104866402A CN 201510239625 A CN201510239625 A CN 201510239625A CN 104866402 A CN104866402 A CN 104866402A
- Authority
- CN
- China
- Prior art keywords
- database
- server
- tested
- press
- unit
- 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
- 238000012360 testing method Methods 0.000 title claims abstract description 56
- 238000000034 method Methods 0.000 claims abstract description 39
- 230000004044 response Effects 0.000 claims abstract description 27
- 238000004088 simulation Methods 0.000 claims abstract description 24
- 238000012545 processing Methods 0.000 claims abstract description 16
- 239000007787 solid Substances 0.000 claims description 6
- 230000008569 process Effects 0.000 description 9
- 230000005540 biological transmission Effects 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 238000011056 performance test Methods 0.000 description 3
- 239000013307 optical fiber Substances 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000004590 computer program Methods 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
Landscapes
- Debugging And Monitoring (AREA)
Abstract
本发明提供了一种测试服务器的方法及装置,包括:预先在待测服务器上设置数据库,向所述数据库中存储模拟数据;S1:向所述数据库发送多个对所述模拟数据的请求;S2:接收所述数据库返回的对所述请求的响应;S3:根据所述请求和所述响应,确定待测服务器的每秒事务处理量TPS。通过本发明提供的一种测试服务器的方法及装置,能够对服务器的整体性能进行测试。
The present invention provides a method and device for testing a server, comprising: setting up a database on the server to be tested in advance, storing simulation data in the database; S1: sending multiple requests for the simulation data to the database; S2: Receive the response to the request returned by the database; S3: Determine the transaction processing per second TPS of the server under test according to the request and the response. Through the method and device for testing the server provided by the present invention, the overall performance of the server can be tested.
Description
技术领域technical field
本发明涉及电子技术领域,特别涉及一种测试服务器的方法及装置。The invention relates to the field of electronic technology, in particular to a method and device for testing a server.
背景技术Background technique
随着大数据技术的发展,需要对大量的数据进行处理,对服务器的处理能力的要求越来越高,为了确定服务器是否满足要求,需要对服务器进行性能测试。With the development of big data technology, a large amount of data needs to be processed, and the requirements for the processing capacity of the server are getting higher and higher. In order to determine whether the server meets the requirements, it is necessary to perform a performance test on the server.
现有技术中,对服务器的测试方法中,一般对服务器的单个硬件性能进行独立测试。例如,测试服务器的磁盘容量、服务器的磁盘转速、服务器的处理器的工作频率等性能进行测试。In the prior art, in the testing method for the server, the single hardware performance of the server is generally tested independently. For example, test performance such as the disk capacity of the server, the disk rotation speed of the server, and the operating frequency of the processor of the server.
通过上述描述可见,现有技术中,对服务器的性能测试一般只是对服务器的硬件分别进行独立测试,但是,服务器在工作时需要各个硬件合作完成,整个服务器的性能并不是单个硬件的性能的叠加,现有技术无法实现对服务器整体性能的测试。It can be seen from the above description that in the prior art, the performance test of the server generally only tests the hardware of the server independently. However, the server needs to cooperate with each hardware to complete the work, and the performance of the entire server is not the superposition of the performance of a single hardware. , the prior art cannot realize the test of the overall performance of the server.
发明内容Contents of the invention
有鉴于此,本发明提供了一种测试服务器的方法及装置,能够对服务器的整体性能进行测试。In view of this, the present invention provides a method and device for testing a server, which can test the overall performance of the server.
一方面,本发明提供了一种测试服务器的方法,包括:预先在待测服务器上设置数据库,向所述数据库中存储模拟数据,还包括:On the one hand, the present invention provides a method for testing a server, comprising: pre-setting a database on the server to be tested, storing simulation data in the database, and further comprising:
S1:向所述数据库发送多个对所述模拟数据的请求;S1: Send multiple requests for the simulated data to the database;
S2:接收所述数据库返回的对所述请求的响应;S2: Receive a response to the request returned by the database;
S3:根据所述请求和所述响应,确定待测服务器的每秒事务处理量TPS。S3: Determine the transaction processing per second TPS of the server to be tested according to the request and the response.
进一步地,所述预先在待测服务器上设置数据库,向所述数据库中存储模拟数据,包括:Further, setting up a database on the server to be tested in advance, and storing simulation data in the database includes:
预先在待测服务器上安装oralce数据库,向所述oralce数据库中存储模拟数据。The oralce database is installed on the server to be tested in advance, and the simulated data is stored in the oralce database.
进一步地,在所述S1之前,还包括:预先设置压力机,将所述压力机与待测服务器相连;Further, before the S1, it also includes: presetting a press, and connecting the press to the server to be tested;
所述S1,包括:The S1 includes:
通过所述压力机向所述数据库发送多个对所述模拟数据的请求。A plurality of requests for the simulation data are sent by the press to the database.
进一步地,所述预先设置压力机,包括:将所述压力机设置为BenchmarkFactory;Further, the preset press includes: setting the press as BenchmarkFactory;
和/或,and / or,
在所述S1之前,还包括:Before said S1, also include:
通过万兆网卡和万兆交换机将所述压力机与待测服务器相连;The press is connected to the server to be tested through a 10G network card and a 10G switch;
和/或,and / or,
在所述S1之前,还包括:Before said S1, also include:
预先将所述数据库中数据的存储介质设置为固态硬盘SSD。The storage medium of the data in the database is set in advance as a solid state disk SSD.
进一步地,所述预先设置压力机,包括:根据所述待测服务器,预先设置第一预设数量个压力机;Further, the preset press includes: according to the server to be tested, pre-set a first preset number of presses;
和/或,and / or,
所述S1,包括:通过所述压力机模拟第二预设数量个用户分别向所述数据库发送多个对所述模拟数据的请求。The S1 includes: simulating a second preset number of users through the press and respectively sending a plurality of requests for the simulation data to the database.
另一方面,本发明提供了一种测试服务器的装置,包括:In another aspect, the present invention provides a device for testing a server, including:
数据库单元,用于在待测服务器上设置数据库,向所述数据库中存储模拟数据;A database unit, configured to set a database on the server to be tested, and store simulation data in the database;
请求单元,用于向所述数据库发送多个对所述模拟数据的请求;a requesting unit, configured to send a plurality of requests for the simulated data to the database;
响应单元,用于接收所述数据库返回的对所述请求的响应;a response unit, configured to receive a response to the request returned by the database;
确定单元,用于根据所述请求和所述响应,确定待测服务器的每秒事务处理量TPS。The determination unit is configured to determine the transaction processing per second (TPS) of the server under test according to the request and the response.
进一步地,所述数据库单元,用于在待测服务器上安装oralce数据库,向所述oralce数据库中存储模拟数据。Further, the database unit is configured to install an oral database on the server to be tested, and store simulation data in the oral database.
进一步地,还包括:第一设置单元,用于设置压力机,将所述压力机与待测服务器相连;Further, it also includes: a first setting unit, configured to set the press, and connect the press to the server to be tested;
所述请求单元,用于通过所述压力机向所述数据库发送多个对所述模拟数据的请求。The request unit is configured to send a plurality of requests for the simulation data to the database through the press machine.
进一步地,所述第一设置单元,用于将所述压力机设置为BenchmarkFactory;Further, the first setting unit is used to set the press as BenchmarkFactory;
和/或,and / or,
还包括:连接单元,用于通过万兆网卡和万兆交换机将所述压力机与待测服务器相连;Also includes: a connection unit, used to connect the press with the server to be tested through a 10G network card and a 10G switch;
和/或,and / or,
还包括:第二设置单元,用于将所述数据库中数据的存储介质设置为固态硬盘SSD。It also includes: a second setting unit, configured to set the storage medium of the data in the database as a solid state disk SSD.
进一步地,所述第一设置单元,用于根据所述待测服务器,设置第一预设数量个压力机;Further, the first setting unit is configured to set a first preset number of presses according to the server under test;
和/或,and / or,
所述请求单元,用于通过所述压力机模拟第二预设数量个用户分别向所述数据库发送多个对所述模拟数据的请求。The requesting unit is configured to simulate a second preset number of users through the press and send a plurality of requests for the simulated data to the database respectively.
本发明提供了一种测试服务器的方法及装置,通过在待测服务器上设置数据库,对数据库中的模拟数据进行请求,通过待测服务器对这些请求的响应来测试服务器的性能,通过计算出的TPS来反映待测服务器的整体性能,该方法中,通过数据库来模拟服务器的实际处理场景,通过TPS来反映服务器从接收请求到给出响应的处理过程中的整体性能,实现对服务器的整体性能的测试。The invention provides a method and device for testing a server. By setting up a database on the server to be tested, requesting simulated data in the database, and testing the performance of the server through the response of the server to be tested to these requests, the calculated TPS is used to reflect the overall performance of the server to be tested. In this method, the actual processing scene of the server is simulated through the database, and the overall performance of the server in the processing process from receiving the request to giving the response is reflected through TPS, so as to realize the overall performance of the server. test.
附图说明Description of drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are For some embodiments of the present invention, those skilled in the art can also obtain other drawings based on these drawings without creative work.
图1是本发明一实施例提供的一种测试服务器的方法的流程图;Fig. 1 is a flow chart of a method for testing a server provided by an embodiment of the present invention;
图2是本发明一实施例提供的另一种测试服务器的方法的流程图Fig. 2 is a flow chart of another method for testing a server provided by an embodiment of the present invention
图3是本发明一实施例提供的一种测试服务器的装置的示意图;Fig. 3 is a schematic diagram of a device for testing a server provided by an embodiment of the present invention;
图4是本发明一实施例提供的另一种测试服务器的装置的示意图。Fig. 4 is a schematic diagram of another device for testing a server provided by an embodiment of the present invention.
具体实施方式Detailed ways
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例,基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动的前提下所获得的所有其他实施例,都属于本发明保护的范围。In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments It is a part of the embodiments of the present invention, but not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative work belong to the protection of the present invention. scope.
如图1所示,本发明实施例提供了一种测试服务器的方法,该方法可以包括以下步骤:As shown in Figure 1, an embodiment of the present invention provides a method for testing a server, which may include the following steps:
S0:预先在待测服务器上设置数据库,向所述数据库中存储模拟数据;S0: setting up a database on the server to be tested in advance, and storing simulation data in the database;
S1:向所述数据库发送多个对所述模拟数据的请求;S1: Send multiple requests for the simulated data to the database;
S2:接收所述数据库返回的对所述请求的响应;S2: Receive a response to the request returned by the database;
S3:根据所述请求和所述响应,确定待测服务器的TPS(Transaction PerSecond,每秒事务处理量)。S3: Determine the TPS (Transaction Per Second, transaction processing volume per second) of the server to be tested according to the request and the response.
通过本发明实施例提供的一种测试服务器的方法,通过在待测服务器上设置数据库,对数据库中的模拟数据进行请求,通过待测服务器对这些请求的响应来测试服务器的性能,通过计算出的TPS来反映待测服务器的整体性能,该方法中,通过数据库来模拟服务器的实际处理场景,通过TPS来反映服务器从接收请求到给出响应的处理过程中的整体性能,实现对服务器的整体性能的测试。Through a method for testing a server provided by an embodiment of the present invention, by setting a database on the server to be tested, requesting simulated data in the database, and testing the performance of the server through the response of the server to be tested to these requests, by calculating TPS to reflect the overall performance of the server to be tested. In this method, the actual processing scene of the server is simulated through the database, and the overall performance of the server in the processing process from receiving the request to giving the response is reflected through the TPS, so as to realize the overall performance of the server. Performance testing.
oracle数据库可操作性高,能够多方面调优,以达到最优性能,尽量减少非服务器性能的因素对测试结果的影响。在一种可能的实现方式中,所述预先在待测服务器上设置数据库,向所述数据库中存储模拟数据,包括:The oracle database has high operability and can be tuned in various aspects to achieve optimal performance and minimize the impact of non-server performance factors on test results. In a possible implementation manner, the pre-setting a database on the server to be tested, and storing simulation data in the database includes:
预先在待测服务器上安装oralce数据库,向所述oralce数据库中存储模拟数据。The oralce database is installed on the server to be tested in advance, and the simulated data is stored in the oralce database.
在一种可能的实现方式中,可以通过压力机向数据库中存储模拟数据,并通过压力机向数据库发送请求。在所述S1之前,还包括:预先设置压力机,将所述压力机与待测服务器相连;In a possible implementation manner, the simulation data may be stored in the database through the press, and a request may be sent to the database through the press. Before the S1, it also includes: pre-setting a press, and connecting the press to the server to be tested;
所述S1,包括:The S1 includes:
通过所述压力机向所述数据库发送多个对所述模拟数据的请求。A plurality of requests for the simulation data are sent by the press to the database.
在一种可能的实现方式中,所述预先设置压力机,包括:将所述压力机设置为BenchmarkFactory。选取Benchmark Factory,应用此工具的高可操控性能,可实现多种模型下模拟数据库的应用,测试服务器在多种应用场景下的性能表现。In a possible implementation manner, the preset press includes: setting the press as a BenchmarkFactory. Select Benchmark Factory and apply the high controllability of this tool to realize the application of simulated database under various models and test the performance of the server in various application scenarios.
为了减少非服务器的原因对测试结果的影响,可以应用高性能存储设备来消除IO上的性能瓶颈,可以高性能的传输设备来降低数据传输过程对测试结果的影响。在所述S1之前,还包括:通过万兆网卡和万兆交换机将所述压力机与待测服务器相连。另外,在所述S1之前,还包括:预先将所述数据库中数据的存储介质设置为SSD(Solid State Drives,固态硬盘)。In order to reduce the impact of non-server reasons on test results, high-performance storage devices can be used to eliminate performance bottlenecks on IO, and high-performance transmission devices can be used to reduce the impact of data transmission on test results. Before the S1, it also includes: connecting the press machine to the server to be tested through a 10G network card and a 10G switch. In addition, before the S1, it also includes: setting the storage medium of the data in the database as SSD (Solid State Drives, solid state disk) in advance.
在一种可能的实现方式中,所述预先设置压力机,包括:根据所述待测服务器,预先设置第一预设数量个压力机。根据待测服务器的性能不同,可以设置不同数量的压力机给被测服务器发送请求,使得服务器有较高的处理压力,例如,可以通过设置压力机的个数,使得服务器的处理器的使用率到达80%以上。In a possible implementation manner, the pre-setting the presses includes: pre-setting a first preset number of presses according to the server to be tested. According to the performance of the server to be tested, different numbers of presses can be set to send requests to the server under test, so that the server has a higher processing pressure. For example, by setting the number of presses, the processor utilization of the server can be increased. Reach more than 80%.
在一种可能的实现方式中,所述S1,包括:通过所述压力机模拟第二预设数量个用户分别向所述数据库发送多个对所述模拟数据的请求。每个压力机都可以模拟多个用户,可以根据需要模拟预设数量的用户来发送请求,使得待测服务器能够得到较大的处理压力。In a possible implementation manner, the S1 includes: using the press machine to simulate a second preset number of users and respectively sending multiple requests for the simulated data to the database. Each press can simulate multiple users, and a preset number of users can be simulated to send requests as needed, so that the server under test can receive greater processing pressure.
为使本发明的目的、技术方案和优点更加清楚,下面结合附图及具体实施例对本发明作进一步地详细描述。In order to make the purpose, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments.
在该实施例中,待测服务器是安腾平台的服务器,待测服务器的处理器为安腾处理器,该待测服务器可以是K1-910,预先在待测安腾平台的服务器上安装K-UNIX操作系统,可以将压力机安装在NF5140M3服务器上。针对安腾平台的服务器,需选取与安腾处理器想适配的操作系统及测试软件,搭建测试环境来模拟数据库的实际应用场景,来反映出搭载安腾处理器的服务器实际性能,选取K-UNIX能够更好地适配K1-910。按照测试规模合理配置交换机,将NF5140M3安装Windows操作系统并接入到配置好的交换机上作为管理端,配置DHCP(Dynamic Host Configuration Protocol,动态主机配置协议)服务,设置DHCP可分配的地址段等网络参数,实现压力机与数据库的连接。另外,为了提高数据的传输速度,可以通过光纤存储卡和光纤交换机将待测服务器与SSD连接。In this embodiment, the server to be tested is a server of the Itanium platform, and the processor of the server to be tested is an Itanium processor. The server to be tested can be K1-910, and the K -UNIX operating system, the press can be installed on the NF5140M3 server. For servers on the Itanium platform, it is necessary to select the operating system and test software that are compatible with the Itanium processor, build a test environment to simulate the actual application scenario of the database, and reflect the actual performance of the server equipped with the Itanium processor. Select K -UNIX can better adapt to K1-910. Reasonably configure the switch according to the test scale, install the Windows operating system on NF5140M3 and connect it to the configured switch as the management terminal, configure DHCP (Dynamic Host Configuration Protocol, Dynamic Host Configuration Protocol) service, set the address segment that can be allocated by DHCP and other networks Parameters to realize the connection between the press and the database. In addition, in order to increase the data transmission speed, the server to be tested can be connected to the SSD through an optical fiber memory card and an optical fiber switch.
Intel安腾(Itanium)处理器专为要求苛刻的企业和技术应用而设计。基于Intel安腾处理器的平台以较低的成本,提供了业界领先的性能。安腾处理器是构建在IA-64(Intel Architecture 64),不同于x86服务器,其安装操作系统及应用软件都是需要软件开发商单独定制以适配,相对于x86平台,应用于安腾平台软件相对较少。The Intel Itanium processor is designed for demanding business and technical applications. Intel Itanium processor-based platforms provide industry-leading performance at a lower cost. The Itanium processor is built on IA-64 (Intel Architecture 64), which is different from the x86 server. The installation of the operating system and application software needs to be customized by the software developer to adapt. Compared with the x86 platform, it is applied to the Itanium platform There is relatively little software.
如图2所示,本发明实施例提供了一种测试安腾平台的服务器的方法,该方法可以包括以下步骤:As shown in Figure 2, the embodiment of the present invention provides a method for testing the server of the Itanium platform, the method may include the following steps:
步骤201:预先在待测安腾平台的服务器上安装oralce数据库,向所述oralce数据库中存储模拟数据,根据待测安腾平台的服务器,预先设置第一预设数量个压力机,将所述压力机与待测安腾平台的服务器相连,通过万兆网卡和万兆交换机将所述压力机与待测安腾平台的服务器相连,预先将所述数据库中数据的存储介质设置为SSD,将所述压力机设置为BenchmarkFactory。Step 201: Install an oral database on the server of the Itanium platform to be tested in advance, store simulation data in the oral database, and set a first preset number of presses in advance according to the server of the Itanium platform to be tested, and set the The press is connected to the server of the Itanium platform to be tested, and the press is connected to the server of the Itanium platform to be tested through a 10 Gigabit network card and a 10 Gigabit switch. The storage medium of the data in the database is set to SSD in advance, and the The press was set to BenchmarkFactory.
具体地,oralce数据库为oralce 10G数据库。针对安腾平台,安装oracle数据库时,修改oracle对操作系统的检测,对操作系统进行自主适配,针对安腾平台服务器,进行与K-UNIX的协调调优。Specifically, the oralce database is an oralce 10G database. For the Itanium platform, when installing the oracle database, modify the oracle detection of the operating system, self-adapt the operating system, and coordinate and optimize with K-UNIX for the Itanium platform server.
步骤202:通过第一预设数量个BenchmarkFactory模拟第二预设数量个用户分别向oralce数据库发送多个对所述模拟数据的请求。Step 202: Use the first preset number of BenchmarkFactories to simulate the second preset number of users to send a plurality of requests for the simulated data to the oral database.
在测试时,通过BenchmarkFactory选择标准化的测试模型,并定义测试规模,测试时间和测试策略等,同时,能通过BenchmarkFactory能看到实时的测试数据情况和CPU利用率,测试数据等信息,方便了解测试实时状态。另外,Server(服务器)端开启数据库监听,压力机通过oracle客户端进行访问和操作。During the test, select a standardized test model through BenchmarkFactory, and define the test scale, test time and test strategy, etc. At the same time, you can see real-time test data, CPU utilization, test data and other information through BenchmarkFactory, which is convenient for understanding the test real-time status. In addition, the server (server) side opens the database monitor, and the press machine is accessed and operated through the oracle client.
步骤203:接收oralce数据库返回的对所述请求的响应。Step 203: Receive a response to the request returned by the oralce database.
步骤204:根据所述请求和所述响应,确定待测安腾平台的服务器的TPS。Step 204: Determine the TPS of the server of the Itanium platform to be tested according to the request and the response.
待测服务器在接收到请求后,对这些请求进行处理,返回对应的响应,根据待测服务器的性能不同,待测服务器处理这些请求的所需要的时间不同,可以将待测服务器每返回一个响应作为一个事务,通过计算每秒事务处理量来反映代偿服务器的整体性能。After the server under test receives the requests, it processes these requests and returns the corresponding response. According to the performance of the server under test, the time required for the server under test to process these requests is different. The server under test can return each response As a transaction, the overall performance of the compensating server is reflected by calculating the transaction volume per second.
如图3、图4所示,本发明实施例提供了一种测试服务器的装置,装置实施例可以通过软件实现,也可以通过硬件或者软硬件结合的方式实现。从硬件层面而言,如图3所示,为本发明实施例提供的一种测试服务器的装置所在设备的一种硬件结构图,除了图3所示的处理器、内存、网络接口、以及非易失性存储器之外,实施例中装置所在的设备通常还可以包括其他硬件,如负责处理报文的转发芯片等等。以软件实现为例,如图4所示,作为一个逻辑意义上的装置,是通过其所在设备的CPU将非易失性存储器中对应的计算机程序指令读取到内存中运行形成的。本实施例提供的一种测试服务器的装置,包括:As shown in FIG. 3 and FIG. 4 , an embodiment of the present invention provides a device for testing a server. The embodiment of the device can be realized by software, or by hardware or a combination of software and hardware. From the perspective of hardware, as shown in Figure 3, it is a hardware structure diagram of the device where the device of the test server provided by the embodiment of the present invention, except for the processor, memory, network interface, and non- In addition to the volatile memory, the device where the device in the embodiment is located may generally include other hardware, such as a forwarding chip responsible for processing packets, and the like. Taking software implementation as an example, as shown in Figure 4, as a device in a logical sense, it is formed by reading the corresponding computer program instructions in the non-volatile memory into the memory for operation by the CPU of the device where it is located. A device for testing a server provided in this embodiment includes:
数据库单元401,用于在待测服务器上设置数据库,向所述数据库中存储模拟数据;A database unit 401, configured to set a database on the server to be tested, and store simulation data in the database;
请求单元402,用于向所述数据库发送多个对所述模拟数据的请求;a requesting unit 402, configured to send multiple requests for the simulated data to the database;
响应单元403,用于接收所述数据库返回的对所述请求的响应;a response unit 403, configured to receive a response to the request returned by the database;
确定单元404,用于根据所述请求和所述响应,确定待测服务器的TPS。The determining unit 404 is configured to determine the TPS of the server to be tested according to the request and the response.
在一种可能的实现方式中,所述数据库单元,用于在待测服务器上安装oralce数据库,向所述oralce数据库中存储模拟数据。In a possible implementation manner, the database unit is configured to install an oral database on the server to be tested, and store simulation data in the oral database.
在一种可能的实现方式中,还包括:第一设置单元,用于设置压力机,将所述压力机与待测服务器相连。In a possible implementation manner, it further includes: a first setting unit, configured to set a press, and connect the press to the server to be tested.
所述请求单元,用于通过所述压力机向所述数据库发送多个对所述模拟数据的请求。The request unit is configured to send a plurality of requests for the simulation data to the database through the press machine.
在一种可能的实现方式中,所述第一设置单元,用于将所述压力机设置为BenchmarkFactory。In a possible implementation manner, the first setting unit is configured to set the press machine as a BenchmarkFactory.
在一种可能的实现方式中,还包括:连接单元,用于通过万兆网卡和万兆交换机将所述压力机与待测服务器相连。In a possible implementation manner, it further includes: a connection unit, configured to connect the press machine to the server to be tested through a 10G network card and a 10G switch.
在一种可能的实现方式中,还包括:第二设置单元,用于将所述数据库中数据的存储介质设置为SSD。In a possible implementation manner, it further includes: a second setting unit, configured to set a storage medium for data in the database as an SSD.
在一种可能的实现方式中,所述第一设置单元,用于根据所述待测服务器,设置第一预设数量个压力机。In a possible implementation manner, the first setting unit is configured to set a first preset number of presses according to the server to be tested.
在一种可能的实现方式中,所述请求单元,用于通过所述压力机模拟第二预设数量个用户分别向所述数据库发送多个对所述模拟数据的请求。In a possible implementation manner, the requesting unit is configured to use the press machine to simulate a second preset number of users and respectively send multiple requests for the simulated data to the database.
上述装置内的各单元之间的信息交互、执行过程等内容,由于与本发明方法实施例基于同一构思,具体内容可参见本发明方法实施例中的叙述,此处不再赘述。The information exchange and execution process among the units in the above-mentioned device are based on the same concept as the method embodiment of the present invention, and the specific content can refer to the description in the method embodiment of the present invention, and will not be repeated here.
本发明实施例提供的一种测试服务器的方法及装置,具有如下有益效果:A method and device for testing a server provided by an embodiment of the present invention have the following beneficial effects:
本发明实施例提供的一种测试服务器的方法及装置,通过在待测服务器上设置数据库,对数据库中的模拟数据进行请求,通过待测服务器对这些请求的响应来测试服务器的性能,通过计算出的TPS来反映待测服务器的整体性能,该方法中,通过数据库来模拟服务器的实际处理场景,通过TPS来反映服务器从接收请求到给出响应的处理过程中的整体性能,实现对服务器的整体性能的测试。A method and device for testing a server provided by an embodiment of the present invention, by setting a database on the server to be tested, requesting simulated data in the database, and testing the performance of the server through the response of the server to be tested to these requests, by calculating In this method, the actual processing scene of the server is simulated through the database, and the overall performance of the server in the processing process from receiving the request to giving the response is reflected through the TPS, so as to realize the real-time performance of the server. Overall performance test.
需要说明的是,在本文中,诸如第一和第二之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个······”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同因素。It should be noted that in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is a relationship between these entities or operations. There is no such actual relationship or sequence. Furthermore, the term "comprises", "comprises" or any other variation thereof is intended to cover a non-exclusive inclusion such that a process, method, article, or apparatus comprising a set of elements includes not only those elements, but also includes elements not expressly listed. other elements of or also include elements inherent in such a process, method, article, or device. Without further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional same elements in the process, method, article or apparatus comprising said element.
本领域普通技术人员可以理解:实现上述方法实施例的全部或部分步骤可以通过程序指令相关的硬件来完成,前述的程序可以存储在计算机可读取的存储介质中,该程序在执行时,执行包括上述方法实施例的步骤;而前述的存储介质包括:ROM、RAM、磁碟或者光盘等各种可以存储程序代码的介质中。Those of ordinary skill in the art can understand that all or part of the steps to realize the above method embodiments can be completed by program instructions related hardware, and the aforementioned programs can be stored in a computer-readable storage medium. When the program is executed, the It includes the steps of the above method embodiments; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other various media that can store program codes.
最后需要说明的是:以上所述仅为本发明的较佳实施例,仅用于说明本发明的技术方案,并非用于限定本发明的保护范围。凡在本发明的精神和原则之内所做的任何修改、等同替换、改进等,均包含在本发明的保护范围内。Finally, it should be noted that the above descriptions are only preferred embodiments of the present invention, and are only used to illustrate the technical solution of the present invention, and are not used to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present invention are included in the protection scope of the present invention.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510239625.8A CN104866402A (en) | 2015-05-12 | 2015-05-12 | Server testing method and apparatus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510239625.8A CN104866402A (en) | 2015-05-12 | 2015-05-12 | Server testing method and apparatus |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104866402A true CN104866402A (en) | 2015-08-26 |
Family
ID=53912248
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510239625.8A Pending CN104866402A (en) | 2015-05-12 | 2015-05-12 | Server testing method and apparatus |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104866402A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106021085A (en) * | 2016-05-24 | 2016-10-12 | 北京金山安全软件有限公司 | Performance test method and device and data server |
CN106339289A (en) * | 2016-09-30 | 2017-01-18 | 郑州云海信息技术有限公司 | Method and system for testing UlltraDIMM performance |
CN106850321A (en) * | 2017-04-05 | 2017-06-13 | 无锡华云数据技术服务有限公司 | A kind of simulated testing system of cluster server |
CN107368405A (en) * | 2016-05-11 | 2017-11-21 | 腾讯科技(北京)有限公司 | Test system, method of testing, mock platforms, blocker and client |
CN108334521A (en) * | 2017-01-19 | 2018-07-27 | 阿里巴巴集团控股有限公司 | A kind of database volume prediction technique and device |
CN113051145A (en) * | 2021-04-08 | 2021-06-29 | 武汉极意网络科技有限公司 | Performance detection method of online verification system |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102253874A (en) * | 2011-08-09 | 2011-11-23 | 广东电网公司电力科学研究院 | Server testing method and testing system |
-
2015
- 2015-05-12 CN CN201510239625.8A patent/CN104866402A/en active Pending
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102253874A (en) * | 2011-08-09 | 2011-11-23 | 广东电网公司电力科学研究院 | Server testing method and testing system |
Non-Patent Citations (2)
Title |
---|
牛小彬: "基于OLTP的高端容错服务器性能评测TPC-E基准的研究与设计", 《中国优秀硕士学位论文全文数据库信息科技辑》 * |
魏理豪等: "TPC-C基准测试体系应用研究", 《广东电力》 * |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107368405A (en) * | 2016-05-11 | 2017-11-21 | 腾讯科技(北京)有限公司 | Test system, method of testing, mock platforms, blocker and client |
CN106021085A (en) * | 2016-05-24 | 2016-10-12 | 北京金山安全软件有限公司 | Performance test method and device and data server |
CN106021085B (en) * | 2016-05-24 | 2018-09-04 | 北京金山安全软件有限公司 | Performance test method and device and data server |
CN106339289A (en) * | 2016-09-30 | 2017-01-18 | 郑州云海信息技术有限公司 | Method and system for testing UlltraDIMM performance |
CN108334521A (en) * | 2017-01-19 | 2018-07-27 | 阿里巴巴集团控股有限公司 | A kind of database volume prediction technique and device |
CN108334521B (en) * | 2017-01-19 | 2022-04-19 | 阿里巴巴集团控股有限公司 | Database capacity prediction method and device |
CN106850321A (en) * | 2017-04-05 | 2017-06-13 | 无锡华云数据技术服务有限公司 | A kind of simulated testing system of cluster server |
CN113051145A (en) * | 2021-04-08 | 2021-06-29 | 武汉极意网络科技有限公司 | Performance detection method of online verification system |
CN113051145B (en) * | 2021-04-08 | 2022-06-28 | 武汉极意网络科技有限公司 | Performance detection method of online verification system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104866402A (en) | Server testing method and apparatus | |
KR102158754B1 (en) | Method and apparatus for operating on smart network interface card | |
CN107092541A (en) | A kind of method that utilization virtual machine carries out storage performance test | |
CN107590075A (en) | A kind of method for testing software and device | |
CN101149665B (en) | Method for mapping an iSCSI target name to a storage resource and computation system | |
CN108306959A (en) | A kind of method, apparatus and storage medium of remote upgrade CPLD firmwares | |
CN110136209A (en) | Camera calibration method and device and computer readable storage medium | |
CN107193699A (en) | One kind tests the wide time-delay method of HCA cassette tapes automatically by RDMA modes | |
CN115964093A (en) | System, method and apparatus for accessing a device program on a storage device | |
EP4167095B1 (en) | Systems, methods, and devices for accessing a device operating system over an interconnect | |
CN111526046A (en) | A method, device, device and storage medium for setting BMC time | |
CN103902310B (en) | Scheduling system and method for starting of virtual machines | |
CN105786732A (en) | Data access method and apparatus | |
CN111177053A (en) | A data communication method, apparatus, system and computer-readable storage medium | |
CN114189553A (en) | Flow playback method, system and computing equipment | |
CN111580888A (en) | Method, device and equipment for batch creation of server RAID (redundant array of independent disks) and storage medium | |
CN118132357A (en) | Storage system testing method and device | |
CN117251361A (en) | Method, device, equipment and storage medium for testing system stability | |
JPWO2021016019A5 (en) | ||
CN116089124A (en) | Communication method, device and medium of simulation system | |
CN115604070A (en) | Message transmission method, device, equipment and medium based on MCTP (Multi-function peripheral protocol) | |
CN115269347A (en) | A storage performance testing method, device, medium and electronic equipment | |
CN115454896A (en) | SMBUS-based SSD MCTP control message verification method and device, computer equipment and storage medium | |
CN106897111A (en) | The management system and management method of a kind of virtual platform | |
CN113238863A (en) | Data interaction method, device and system of BMC and BIOS |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
EXSB | Decision made by sipo to initiate substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20150826 |
|
WD01 | Invention patent application deemed withdrawn after publication |