Server batch test method, device, equipment and medium

By automatically receiving and installing the test system in the Pxe environment, and combining information collection and aging test scripts, aging test instructions are generated based on the server type, the problems of traditional manual detection are solved, and efficient and accurate server batch testing is achieved.

CN119902937APending Publication Date: 2025-04-29BEIJING TIANDI CHAOYUN TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411995594.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-04-29

AI Technical Summary

Technical Problem

Traditional server pre-shipment inspection and aging testing rely on manual operations, which have problems such as low efficiency, poor accuracy, and difficulty in scale, and it is difficult to quickly adapt to new hardware architectures and technical standards.

Method used

By receiving network configuration information and test system feedback from the test server in the Pxe environment, the test system will be automatically received and installed after the server parameter configuration of the test server. Deeply integrate information collection, aging tests with automated installation, generate aging test instructions based on the server types in hardware information, run aging test scripts in the test system, and perform different aging tests for different types of servers.

Benefits of technology

It improves the efficiency, accuracy and standardization of server inspection and aging test before shipment, simplifies the process of inspection and aging test, and realizes batch testing of different types of servers, while improving the efficiency and accuracy of inspection and testing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119902937A_ABST
    Figure CN119902937A_ABST
Patent Text Reader

Abstract

The invention provides a server batch test method, device, equipment and medium, and relates to the technical field of computer testing, and the method comprises the steps: in a Pxe environment, sending an address request to a test system server, receiving network configuration information fed back by the test system server, and carrying out server parameter configuration, receiving a test system fed back by the test system server after configuration is completed; running the test system, and collecting hardware information of the to-be-tested server through a complete machine information collection script in the test system; generating an aging test instruction according to the server type in the hardware information; and running an aging test script in the test system according to the aging test instruction to obtain a test report. According to the technical scheme of the embodiment of the invention, different tests can be carried out on different types of servers, information collection, aging test and automatic installation are deeply integrated, and the efficiency, accuracy and standardization degree of detection and aging test before delivery of the servers are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of computer testing, and in particular to a server batch testing method, device, equipment and medium. Background Art

[0002] With the rapid development of information technology, the scale of the server market continues to expand, placing higher demands on server quality and delivery speed.

[0003] Traditional server pre-shipment inspection and aging tests rely on manual operations, which have problems such as low efficiency, poor accuracy, and difficulty in scalability. Information omissions or incorrect records are prone to occur during manual inspections, and it is difficult to ensure consistency and comprehensiveness in the execution of aging tests. At the same time, with the continuous updating of server hardware technology, traditional testing methods are difficult to quickly adapt to new hardware architectures and technical standards. Summary of the invention

[0004] In view of this, the purpose of the present invention is to provide a server batch testing method, device, equipment and medium, which deeply integrates information collection, aging testing and automated installation by performing different tests on different types of servers, thereby improving the efficiency, accuracy and standardization of server pre-shipment inspection and aging testing.

[0005] In a first aspect, an embodiment of the present invention provides a server batch testing method, which is applied to a server to be tested, and the method includes:

[0006] In the Pxe environment, send an address request to the test system server and receive network configuration information fed back by the test system server;

[0007] Configure server parameters according to network configuration information, and receive and install the test system fed back by the test system server after the server parameters are configured;

[0008] Run the test system and collect the hardware information of the server to be tested through the whole machine information collection script in the test system;

[0009] Generate an aging test instruction according to the server type in the hardware information;

[0010] Run the aging test script in the test system according to the aging test instruction to obtain a test report.

[0011] In a preferred embodiment of the present invention, the above-mentioned generating an aging test instruction according to the server type in the hardware information includes:

[0012] According to the server type in the hardware information, at least one test program corresponding to the server type is selected from the aging test script;

[0013] For each test program, an aging test instruction corresponding to the test program is generated.

[0014] In a preferred embodiment of the present invention, the aging test script in the test system is run according to the aging test instruction to obtain a test report, including:

[0015] According to the execution order of each aging test instruction, the test programs corresponding to each aging test instruction are executed in sequence to obtain the test reports corresponding to each test program.

[0016] In a preferred embodiment of the present invention, after the aging test script in the test system is run according to the aging test instruction and a test report is obtained, the following steps are further included:

[0017] The test report and hardware information are sent to the test system server for analysis of the test results of the server to be tested.

[0018] In a preferred embodiment of the present invention, the above-mentioned generating an aging test instruction according to the server type in the hardware information includes:

[0019] Display hardware information on the display device connected to the server to be tested;

[0020] In response to at least one operation instruction initiated by a user for a server type of hardware information, determining a test program corresponding to each operation instruction;

[0021] For each test program, an aging test instruction corresponding to the test program is generated.

[0022] In a second aspect, an embodiment of the present invention provides a server batch testing method, which is applied to a test system server, and the method includes:

[0023] Build the Pxe environment in the test system server;

[0024] In response to address requests sent by multiple servers to be tested, corresponding network configuration information is fed back to each server to be tested, where the network configuration information is used for the server to be tested to configure server parameters;

[0025] Based on the network configuration information, the test system is sent to each server to be tested; the test system includes a whole machine information collection script and an aging test script;

[0026] Receive the hardware information obtained after each server to be tested runs the whole machine information collection script;

[0027] After receiving each server to be tested and running the aging test script, a test report is obtained.

[0028] In a third aspect, an embodiment of the present invention further provides a server batch testing device, which is applied to a server to be tested, and the device includes:

[0029] The request sending module is used to send an address request to the test system server in the Pxe environment, and receive the network configuration information and test system fed back by the test system server;

[0030] The information collection module is used to run the whole machine information collection script in the test system to collect the hardware information of the server to be tested;

[0031] A test instruction generation module, used to generate an aging test instruction according to the server type in the hardware information;

[0032] The aging test module is used to run the aging test script in the test system according to the aging test instruction to obtain a test report.

[0033] In a fourth aspect, an embodiment of the present invention further provides a server batch testing device, which is applied to a test system server, and the device includes:

[0034] Environment building module, used to build Pxe environment in the test system server;

[0035] A request receiving module, used to respond to address requests sent by multiple servers to be tested and feed back corresponding network configuration information to each server to be tested;

[0036] The test system sending module is used to send the test system to each server to be tested based on the network configuration information; the test system includes a whole machine information collection script and an aging test script;

[0037] An information receiving module is used to receive the hardware information obtained after each server to be tested runs the whole machine information collection script;

[0038] The test report acquisition module is used to receive the test report obtained after each server to be tested runs the aging test script.

[0039] In a fifth aspect, an embodiment of the present invention further provides an electronic device, comprising a processor and a memory, wherein the memory stores computer executable instructions that can be executed by the processor, and the processor executes the computer executable instructions to implement the server batch testing method of any one of the first and second aspects above.

[0040] In the sixth aspect, an embodiment of the present invention further provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the server batch testing method of any one of the first and second aspects mentioned above.

[0041] The embodiments of the present invention bring the following beneficial effects:

[0042] The embodiment of the present invention provides a server batch testing method, which realizes automatic reception and installation of the test system after the server parameters of the server to be tested are configured by receiving the network configuration information and the test system fed back by the test server in the Pxe environment. The test system includes a positive information collection script and an aging test script, deeply integrates information collection, aging test and automatic installation, simplifies the process of server pre-shipment detection and aging test, generates aging test instructions according to the server type, and runs the aging test script, which can perform different aging tests on different types of servers, and improves the efficiency, accuracy and standardization of server pre-shipment detection and aging test while realizing batch testing of different types of servers.

[0043] Other features and advantages of the present invention will be set forth in the following description, or some features and advantages may be inferred or unambiguously determined from the description, or may be learned by implementing the above-mentioned technology of the present invention.

[0044] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0046] Figure 1 A flow chart of a server batch testing method provided by an embodiment of the present invention;

[0047] Figure 2 A flow chart of another server batch testing method provided by an embodiment of the present invention;

[0048] Figure 3 A flow chart of another server batch testing method provided by an embodiment of the present invention;

[0049] Figure 4 A schematic diagram of the structure of a server batch testing device provided by an embodiment of the present invention;

[0050] Figure 5 A schematic diagram of the structure of another server batch testing device provided by an embodiment of the present invention;

[0051] Figure 6 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0052] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0053] Traditional server pre-shipment inspection and aging tests rely on manual operations, which have problems such as low efficiency, poor accuracy, and difficulty in scalability. Information omissions or incorrect records are prone to occur during manual inspection, and it is difficult to ensure consistency and comprehensiveness in the execution of aging tests. At the same time, with the continuous updating of server hardware technology, traditional testing methods are difficult to quickly adapt to new hardware architectures and technical standards, and an automated, efficient, and flexible inspection and aging test solution is urgently needed.

[0054] Based on this, a server batch testing method provided in an embodiment of the present invention can perform different tests on different types of servers, deeply integrate information collection, aging testing and automated installation, and improve the efficiency, accuracy and standardization of server pre-shipment inspection and aging testing.

[0055] To facilitate understanding of this embodiment, a server batch testing method disclosed in an embodiment of the present invention is first introduced in detail.

[0056] Example 1

[0057] The embodiment of the present invention provides a server batch testing method, which is applied to a server to be tested. Figure 1 A flow chart of a server batch testing method provided by an embodiment of the present invention. Figure 1 As shown, the server batch testing method may include the following steps:

[0058] Step S101, in a Pxe environment, sending an address request to a test system server, and receiving network configuration information fed back by the test system server.

[0059] The server to be tested refers to a server that needs to be tested and aged before shipment. There are multiple servers to be tested, and each server to be tested can simultaneously execute the server batch testing method provided by the embodiment of the present invention.

[0060] The Pxe (Pre-boot Execution Environment) environment is a technical environment for starting a computer through a network interface. It allows the computer to download and start the operating system or other software from a network server without the operating system boot program in a local storage device (such as a hard disk, USB flash drive, etc.). The Pxe environment includes a DHCP server and a TFTP server. Among them, the DHCP server is used to allocate network configuration information to the server to be tested. The TFTP server is used to store and transmit test software. In an embodiment of the present invention, the test system is a Linux system, which is used to perform pre-shipment detection and aging testing on the server to be tested. The whole machine information collection script and the aging test script are encapsulated in the test system.

[0061] The test system server refers to a network server storing the test system. The test system server is set in the Pxe environment. The network configuration information refers to the information required to configure the network information of the server to be tested. The network configuration information may include information such as IP address, subnet mask, gateway, etc.

[0062] Specifically, after the server to be tested is connected to the Pxe environment, it sends an address request to the test system server to request the test system server to allocate network configuration information to the server to be tested. After receiving the address request, the test system server sends the network configuration information allocated to the server to be tested to the server to be tested.

[0063] Step S102, configuring server parameters according to the network configuration information, and receiving and installing the test system fed back by the test system server after the server parameters are configured.

[0064] The network configuration information is set as the server parameters of the server to be tested. After the server parameters are configured, the test system server sends the test system to the server to be tested. After the server to be tested receives the test system, it installs the test system into the server to be tested. Exemplarily, after the server parameters are configured, the test system server can send the test system to the server to be tested according to the IP address of the server to be tested.

[0065] The Pxe environment may also include a kickstart configuration file. The kickstart configuration file is used to define the parameters for automatically installing the test system on the server to be tested and the order in which the scripts in the test system are run. Specifically, the test system server may send the kickstart configuration file before sending the test system to the server to be tested. After receiving the kickstart configuration file, the server to be tested may automatically install the received test system.

[0066] Step S103: running the test system, and collecting the hardware information of the server to be tested through the whole machine information collection script in the test system.

[0067] The whole machine information collection script is used to collect the hardware information of the server to be tested. The hardware information is used to identify the server to be tested. The hardware information of different servers to be tested is different. The hardware information includes at least one of the server type, SN (Serial Number), CPU model, memory capacity, memory frequency, hard disk type, hard disk capacity, array card configuration, network card model, etc.

[0068] Specifically, the server to be tested runs a whole machine information collection script in the test system, and the whole machine information collection script collects hardware information of the server to be tested.

[0069] Step S104: Generate an aging test instruction according to the server type in the hardware information.

[0070] The server type is used to describe the classification result according to the processor platform to which the server to be tested belongs. Exemplarily, the server type may include Intel, AMD, Feiteng, Haiguang, Loongson, etc.

[0071] It is understandable that in the aging test script, different test programs can be set for different server types. When developing the aging test script, multiple aging test scenarios can also be integrated, such as high temperature test, burning test and stress test.

[0072] Exemplary, for high temperature tests of different processor platforms, corresponding test logic can be written, such as controlling the server to be tested to run for a specific time in a high temperature environment and monitoring system stability. For the burning test, a burning instruction sequence is written according to the burning specifications of different chips. For stress testing, tools (such as cpu (stress-ng / Stressapptest / AMD_SST / unixbench), Memory (lmbench / Stream / Memtester), Hdd (fio / storcli / Sas3flash)) are used to dynamically set test parameters according to the different hardware platform configurations of the server to be tested. For example, the number of concurrent threads is determined according to the number of CPU cores, the memory allocation is determined according to the memory size, and the corresponding CPU stress tools are used for different platforms. Therefore, for each server type, the number of corresponding test programs is at least one. For each test program corresponding to each server type, an aging test instruction can be generated. That is, in the aging test script, multiple test programs are included, and each test program can implement a test function for a server type.

[0073] Exemplarily, for Feiteng server, three test programs can be included, which are respectively used to implement high temperature test, pressure test and burning test for Feiteng server. For the three test programs, an aging test instruction can be generated, and an aging test instruction can also be generated for each test program.

[0074] According to the server type in the hardware information, the test program corresponding to the server type can be automatically selected from the test programs in the aging test script to generate an aging test instruction, or the test program corresponding to the server type can be manually selected to generate an aging test instruction.

[0075] Specifically, the aging test instruction may be generated through steps A1 to A3.

[0076] Step A1: displaying hardware information on a display device connected to the server to be tested.

[0077] Step A2, in response to at least one operation instruction initiated by the user for the server type of the hardware information, determining a test program corresponding to each operation instruction.

[0078] Step A3: for each test program, generate an aging test instruction corresponding to the test program.

[0079] Specifically, a display device can be connected to the server to be tested, and after the server to be tested runs the whole machine information collection script, the collected hardware information can be displayed on the display device. Options for describing test programs for different server types can also be displayed on the display device. The user can select at least one option corresponding to the server type from the multiple options displayed on the display device according to the server type in the hardware information displayed on the display device, and generate at least one operation instruction. One of the options corresponds to an operation instruction. In response to at least one operation instruction initiated by the user for the server type of the hardware information, the test program corresponding to each operation instruction is determined. For the test program corresponding to each operation instruction, an aging test instruction is generated.

[0080] Users can select test programs based on the hardware information of the server to be tested, which improves the flexibility of the aging test. During the aging test, the server to be tested does not need to test all the test programs corresponding to the server type, which can make the aging test applicable to different scenarios, improving the efficiency and practicality of the aging test.

[0081] Step S105, running the aging test script in the test system according to the aging test instruction to obtain a test report.

[0082] Through the aging test instructions, the server to be tested is controlled to execute the test program corresponding to the server type, and a test report is obtained after the test program is executed. The test report includes the test results (such as whether the test passed, whether an abnormality occurred, etc.), key data in the test process (such as the temperature change curve in the high temperature test, the resource utilization chart in the stress test, etc.). In the case of test failure, the cause of failure, the time point when the abnormality occurred, related parameters and other information are recorded in detail. Among them, the cause of failure is used to describe the test program that has an abnormality in the aging test. The time point when the abnormality occurs refers to the time point when the abnormal data is collected. The related parameters refer to the collected abnormal data. For example, in the test report, the test result is that the test failed, the cause of failure is the high temperature test abnormality, the time point when the abnormality occurred is 10s, and the related parameters are that the CPU temperature is 60°C.

[0083] The embodiment of the present invention provides a server batch testing method, which realizes automatic reception and installation of the test system after the server parameters of the server to be tested are configured by receiving the network configuration information fed back by the test server and the test system in the Pxe environment. The test system includes a positive information collection script and an aging test script, deeply integrates information collection, aging test and automatic installation, simplifies the process of server pre-shipment detection and aging test, generates aging test instructions according to the server type, and runs the aging test script, which can perform different aging tests on different types of servers, and improves the efficiency, accuracy and standardization of server pre-shipment detection and aging test while realizing batch testing of different types of servers.

[0084] Example 2

[0085] The embodiment of the present invention also provides another server batch testing method; the method focuses on describing a specific implementation method of generating an aging test instruction according to the server type in the hardware information.

[0086] Figure 2 A flowchart of another server batch testing method provided by an embodiment of the present invention, such as Figure 2 As shown, the server batch testing method may include the following steps:

[0087] Step S201, in a Pxe environment, sending an address request to a test system server, and receiving network configuration information fed back by the test system server.

[0088] Step S202, configuring server parameters according to the network configuration information, and receiving and installing the test system fed back by the test system server after the server parameters are configured.

[0089] Step S203: running the test system, and collecting the hardware information of the server to be tested through the whole machine information collection script in the test system.

[0090] Step S204: According to the server type in the hardware information, at least one test program corresponding to the server type is screened out from the aging test script.

[0091] According to the server type in the hardware information, the test program corresponding to the server type can be queried from the aging test script according to the association between the server type and the test program, and an aging test instruction is generated for the test program corresponding to the server type. The association between the server type and the test program can be preset according to business needs.

[0092] Step S205: for each test program, generate an aging test instruction corresponding to the test program.

[0093] Step S206, running the aging test script in the test system according to the aging test instruction to obtain a test report.

[0094] Furthermore, the aging test script in the test system is run according to the aging test instruction to obtain a test report, including: executing the test programs corresponding to the aging test instructions in sequence according to the execution order of the aging test instructions to obtain the test reports corresponding to the test programs.

[0095] Specifically, the order in which the aging test instructions are generated may be used as the execution order of the aging test instructions. According to the execution order, the test programs corresponding to the aging test instructions are executed in sequence, and the corresponding test report is output after each test program is executed.

[0096] In another embodiment, the arrangement order of all the test programs included in the aging test script can be preset. For the test programs corresponding to each aging test instruction, the order of each test program in the arrangement order is used as the execution order of the aging test instruction, and the test programs corresponding to the aging test instruction are executed in sequence. After each test program is executed, the corresponding test report is output. Exemplarily, the arrangement order of all the test programs included in the aging test script is preset as Feiteng high temperature, Haiguang high temperature, Loongson high temperature, Feiteng burning, Haiguang burning, and Loongson burning. The test programs corresponding to the aging test instruction are Feiteng high temperature and Feiteng burning. According to the order of each test program in the arrangement order, the execution order of the aging test instruction is determined to be Feiteng high temperature and Feiteng burning. Feiteng high temperature and Feiteng burning are executed in sequence to obtain the test report of Feiteng high temperature and the test report corresponding to Feiteng burning.

[0097] Step S207, sending the test report and hardware information to the test system server for analyzing the test result of the server to be tested.

[0098] Specifically, for each server to be tested, the test report and hardware information are transmitted to the test system server for centralized storage and management. Users can directly view the test report and hardware information of each server to be tested on the test system server, use the test report and hardware information as test results, and analyze the test results according to business needs. Exemplarily, check whether the test results meet the preset quality standards, such as whether the server runs stably within the specified time in the high temperature test, whether the resource utilization rate in the stress test is within a reasonable range, etc. For servers that do not meet the quality standards, quickly locate the problem through data analysis, and take corresponding measures (such as repairing hardware problems, adjusting software configuration, retesting, etc.). For servers that meet the quality standards, mark and record them and prepare to enter the shipping process. At the same time, all test reports are classified and archived, and indexes are established according to dimensions such as the batch of servers to be tested, test time, and test type, which facilitates subsequent inquiries and tracing the quality of the servers to be tested, and realizes effective control of the quality of large quantities of servers before shipment.

[0099] The server batch testing method provided by the embodiment of the present invention can automatically screen the test programs corresponding to the server types, realize the automation of the aging test, and improve the efficiency of the aging test and the convenience of using the test system.

[0100] Example 3

[0101] The embodiment of the present invention also provides another server batch testing method; the method is applied to testing system servers.

[0102] Figure 3 A flowchart of another server batch testing method provided by an embodiment of the present invention, such as Figure 3 As shown, the server batch testing method may include the following steps:

[0103] Step S301, building a Pxe environment in the test system server.

[0104] Specifically, first configure the DHCP server in the Pxe environment, and according to the expected number of large-scale servers to be tested, reasonably plan the range of the IP address pool to ensure that each server to be tested can obtain a unique IP address. At the same time, optimize the configuration parameters of the DHCP server, such as lease time, renewal strategy, etc., to adapt to the dynamic network requirements of large-scale servers to be tested during installation and testing. Then configure the TFTP server, set the storage directory structure of the startup file (such as Linux kernel file, initial ramdisk file, etc.) and script file, and set an efficient file transfer mode. By optimizing the performance parameters of the TFTP server (such as the size of the transmission buffer, the number of concurrent connections, etc.), the file transfer speed is improved, the waiting time for server startup and file acquisition is reduced, and it is ensured that a large number of servers can quickly and accurately download the test system from the TFTP server and smoothly start the installation and testing process. The script files include the whole machine information collection script and the aging test script.

[0105] Furthermore, a kickstart configuration file may be written to define test system installation parameters, such as partition settings, software package selection, etc., and to specify the execution order and parameters of the whole machine information collection script and the aging test script.

[0106] Step S302: in response to the address requests sent by the multiple servers to be tested, feeding back corresponding network configuration information to each server to be tested.

[0107] The network configuration information is used for the server to be tested to configure server parameters.

[0108] Specifically, all servers to be tested are powered on and started, and the BIOS of each server to be tested is uniformly set to Pxe network boot priority. Each server to be tested sends an address request to the DHCP server at the same time. The DHCP server allocates a unique IP address, subnet mask, gateway and other network configuration information to each server to be tested based on the pre-configured address pool, realizing the rapid distribution of network configurations for large quantities of servers.

[0109] Step S303: sending the test system to each server to be tested based on the network configuration information.

[0110] The test system includes a whole machine information collection script and an aging test script. The test system is developed based on the Linux system, and the whole machine information collection script and the aging test script are encapsulated into the developed Linux system. In the process of developing the test system, first, select a suitable Linux distribution (such as CentOS, Ubuntu, etc.), and install the necessary software packages and dependent libraries according to the running requirements of the whole machine information collection script and the aging test script. For example, in order to support network transmission functions, install and optimize services such as FTP and SCP; for hardware information collection, ensure the normal operation environment of related system command tools (such as dmidecode, lscpu, etc.). Then configure the test system environment, including setting system permissions to ensure that the whole machine information collection script and the aging test script can access hardware resources and networks under appropriate permissions. Then optimize the startup items of the test system, reduce unnecessary service startup, and increase the system startup speed to meet the needs of rapid detection and testing of large-scale servers to be tested. Finally, the Linux system is deeply optimized, the kernel parameters of the test system are adjusted, and unnecessary background services and processes are closed to improve the startup speed and operating efficiency of the test system, optimize the file system, and reasonably allocate disk space to ensure the stability and read and write performance of the test system when processing large amounts of data (such as hardware information storage, test report generation, etc.). At the same time, the system security policy is set to ensure data security during the test of the server to be tested.

[0111] Specifically, after the DHCP server sends the network configuration information, the TFTP server sends the test system to the server to be tested, that is, the server to be tested downloads the test system from the TFTP server. While downloading the test system, it can also download the startup file to start the test system installation program.

[0112] Furthermore, during the test system installation process, the whole machine information collection script can be automatically executed according to the settings of the kickstart configuration file.

[0113] Step S304, receiving the hardware information obtained after each server to be tested runs the whole machine information collection script.

[0114] The whole machine information collection script is started and run on each server to be tested at the same time. Through efficient system command calls and data collection algorithms, the server hardware is quickly scanned to obtain hardware information. For example, multi-threading technology is used to simultaneously execute commands such as dmidecode, lscpu, free, and lsblk to speed up information collection. The collected hardware information is sorted and formatted in real time to ensure the standardization and readability of the information. Then, through optimized network transmission protocols (such as multi-threaded FTP or SCP transmission), the hardware information is transmitted in parallel to the specified IP address and path, that is, to the test system server. During the transmission process, high-intensity data encryption and multiple verification mechanisms are used to ensure the security and accuracy of information transmission. In the designated storage location of the test system server, the SN or other unique identifier of the server to be tested is used as the file name, and the hardware information is saved in an efficient storage format (such as binary format or compressed text format) to facilitate subsequent rapid query and management, and to achieve rapid and accurate collection and storage of hardware information of a large number of servers to be tested.

[0115] Step S305, receiving the hardware information obtained after each server to be tested runs the whole machine information collection script.

[0116] The user selects the corresponding test program and generates aging test instructions based on the server type (such as Feiteng server, Haiguang server, Loongson server, etc.) and specific test requirements. After receiving the aging test instructions, the aging test script uses a distributed task management framework (such as a distributed task queue based on Redis or a self-developed distributed task scheduling system) to decompose the aging test task into multiple subtasks. In other words, a test program is used as a subtask.

[0117] Specifically, for each server to be tested, after receiving the aging test instruction, the test program corresponding to the aging test instruction is started synchronously to realize the concurrent execution of aging tests on a large number of servers to be tested. During the execution of the test program, the test system continuously monitors the status of the server to be tested, including hardware status (such as temperature, fan speed, power supply voltage, etc.) and software status (such as system processes, service operation status, log records, etc.). The status data is collected once at regular time intervals (such as 5 minutes) and recorded in a local file or remote database. After the test program is executed, the aging test script generates a detailed test report in parallel on each server based on the data recorded during the test.

[0118] Exemplarily, the server type is Feiteng. When performing a high temperature test, the test program is Feiteng high temperature test. The test program controls the server to be tested to enter a high temperature environment (can be through an external temperature control device or using the server's own temperature control function), and runs a specific high temperature test program for 12 hours. During the test, the temperature changes of key parts such as the CPU temperature, motherboard temperature, and memory temperature of the server are monitored in real time by sensors, and the system log of the server is monitored at the same time to check whether there are errors or abnormal information caused by high temperature. If the temperature exceeds the preset threshold or the system is abnormal, the relevant information is recorded in time and an alarm is issued. The server type is Feiteng. When performing a burning test, the test program is Feiteng burning. The test program calls the corresponding burning tool and instruction to burn the specified firmware or software program into the chip or storage device of the server to be tested. During the burning process, the burning progress and status are monitored in real time to ensure the integrity and accuracy of the burning. After the burning is completed, the burning result is verified, such as by calculating the checksum of the burning data and comparing it with the checksum of the original data. When performing stress testing, the test program is a stress test, and the test parameters are dynamically set according to the hardware information of the server to be tested, such as the number of CPU cores, memory size, etc. Use the stress-ng tool to start multiple concurrent threads to perform high-load stress tests on resources such as CPU, memory, and disk. For example, for a server with a multi-core CPU, start a CPU stress test thread equivalent to the number of cores, allocate a large amount of memory for read and write operations, and make continuous read and write requests to the disk. During the stress test, monitor the server's resource utilization (such as CPU usage, memory usage, disk I / O rate, etc.), system response time, process status and other indicators in real time, and record the test data in the form of charts or logs.

[0119] The embodiment of the present invention provides a server batch testing method, which realizes automatic reception and installation of the test system after the server parameters of the server to be tested are configured by receiving the network configuration information fed back by the test server and the test system in the Pxe environment. The test system includes a positive information collection script and an aging test script, deeply integrates information collection, aging test and automatic installation, simplifies the process of server pre-shipment detection and aging test, generates aging test instructions according to the server type, and runs the aging test script, which can perform different aging tests on different types of servers, and improves the efficiency, accuracy and standardization of server pre-shipment detection and aging test while realizing batch testing of different types of servers.

[0120] Example 4

[0121] Corresponding to the above method embodiment, an embodiment of the present invention provides a server batch testing device, which is applied to a server to be tested. Figure 4A schematic diagram of the structure of a server batch testing device provided by an embodiment of the present invention, such as Figure 4 As shown, the server batch testing device may include:

[0122] The request sending module 401 is used to send an address request to the test system server in the Pxe environment and receive network configuration information fed back by the test system server;

[0123] The system download module 402 is used to configure the server parameters according to the network configuration information, and receive and install the test system fed back by the test system server after the server parameters are configured;

[0124] The information collection module 403 is used to run the test system and collect the hardware information of the server to be tested through the whole machine information collection script in the test system;

[0125] A test instruction generating module 404, used to generate an aging test instruction according to the server type in the hardware information;

[0126] The aging test module 405 is used to run the aging test script in the test system according to the aging test instruction to obtain a test report.

[0127] The embodiment of the present invention provides a server batch testing device, which realizes automatic reception and installation of the test system after the server parameters of the server to be tested are configured by receiving the network configuration information and the test system fed back by the test server in the Pxe environment. The test system includes a positive information collection script and an aging test script, which deeply integrates information collection, aging test and automatic installation, simplifies the process of server pre-shipment detection and aging test, generates aging test instructions according to the server type, and runs the aging test script, which can perform different aging tests on different types of servers, and improves the efficiency, accuracy and standardization of server pre-shipment detection and aging test while realizing batch testing of different types of servers.

[0128] In some embodiments, the test instruction generation module 404 is further configured to:

[0129] According to the server type in the hardware information, at least one test program corresponding to the server type is selected from the aging test script;

[0130] For each test program, an aging test instruction corresponding to the test program is generated.

[0131] In some embodiments, the aging test script in the test system is run according to the aging test instruction to obtain a test report, including:

[0132] According to the execution order of each aging test instruction, the test programs corresponding to each aging test instruction are executed in sequence to obtain the test reports corresponding to each test program.

[0133] In some embodiments, the apparatus further comprises:

[0134] The feedback module is used to send the test report and hardware information to the test system server for analyzing the test results of the server to be tested.

[0135] In some embodiments, the test instruction generation module 404 is further configured to:

[0136] Display hardware information on the display device connected to the server to be tested;

[0137] In response to at least one operation instruction initiated by a user for a server type of hardware information, determining a test program corresponding to each operation instruction;

[0138] For each test program, an aging test instruction corresponding to the test program is generated.

[0139] The device provided in the embodiment of the present invention has the same implementation principle and technical effects as those of the aforementioned method embodiment. For the sake of brief description, for matters not mentioned in the device embodiment, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0140] Example 5

[0141] Corresponding to the above method embodiment, an embodiment of the present invention provides another server batch testing device, which is applied to test system servers. Figure 5 A schematic diagram of the structure of a server batch testing device provided by an embodiment of the present invention, such as Figure 5 As shown, the server batch testing device may include:

[0142] The environment building module 501 is used to build the Pxe environment in the test system server;

[0143] The request receiving module 502 is used to respond to the address requests sent by the multiple servers to be tested and to feed back corresponding network configuration information to each server to be tested, where the network configuration information is used for the server to be tested to configure server parameters;

[0144] The test system sending module 503 is used to send the test system to each server to be tested based on the network configuration information; the test system includes a whole machine information collection script and an aging test script;

[0145] The information receiving module 504 is used to receive the hardware information obtained after each server to be tested runs the whole machine information collection script;

[0146] The test report acquisition module 505 is used to receive the test report obtained after each server to be tested runs the aging test script.

[0147] The embodiment of the present invention provides a server batch testing device, which realizes automatic reception and installation of the test system after the server parameters of the server to be tested are configured by receiving the network configuration information and the test system fed back by the test server in the Pxe environment. The test system includes a positive information collection script and an aging test script, which deeply integrates information collection, aging test and automatic installation, simplifies the process of server pre-shipment detection and aging test, generates aging test instructions according to the server type, and runs the aging test script, which can perform different aging tests on different types of servers, and improves the efficiency, accuracy and standardization of server pre-shipment detection and aging test while realizing batch testing of different types of servers.

[0148] The device provided in the embodiment of the present invention has the same implementation principle and technical effects as those of the aforementioned method embodiment. For the sake of brief description, for matters not mentioned in the device embodiment, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0149] Example 6

[0150] The embodiment of the present invention also provides an electronic device for running the above-mentioned server batch testing method; see Figure 6 A structural schematic diagram of an electronic device is shown, which includes a memory 600 and a processor 601, wherein the memory 600 is used to store one or more computer instructions, and the one or more computer instructions are executed by the processor 601 to implement the above-mentioned server batch testing method.

[0151] Further, Figure 6 The electronic device shown further includes a bus 602 and a communication interface 603 , and the processor 601 , the communication interface 603 and the memory 600 are connected via the bus 602 .

[0152] The memory 600 may include a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk storage. The communication connection between the system network element and at least one other network element is realized through at least one communication interface 603 (which may be wired or wireless), and the Internet, wide area network, local area network, metropolitan area network, etc. may be used. The bus 602 may be an ISA bus, a PCI bus, or an EISA bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 6Only one bidirectional arrow is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0153] The processor 601 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 601. The above processor 601 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present invention can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present invention can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution. The software module may be located in a storage medium mature in the art, such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 600, and the processor 601 reads the information in the memory 600 and completes the steps of the method of the above embodiment in combination with its hardware.

[0154] An embodiment of the present invention also provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the above-mentioned server batch testing method. The specific implementation can be found in the method embodiment, which will not be repeated here.

[0155] The computer program product for performing a server batch testing method provided in an embodiment of the present invention includes a computer-readable storage medium storing a non-volatile program code executable by a processor. The instructions included in the program code can be used to execute the method described in the previous method embodiment. The specific implementation can be found in the method embodiment and will not be repeated here.

[0156] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0157] In the several embodiments provided by the present invention, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.

[0158] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0159] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0160] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium that is executable by a processor. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0161] Finally, it should be noted that the above-described embodiments are only specific implementations of the present invention, which are used to illustrate the technical solutions of the present invention, rather than to limit them. The protection scope of the present invention is not limited thereto. Although the present invention is described in detail with reference to the above-mentioned embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-mentioned embodiments within the technical scope disclosed by the present invention, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.

Claims

1. A server batch testing method, characterized in that: Applied to the server to be tested, the method includes: In the Pxe environment, an address request is sent to a test system server, and network configuration information fed back by the test system server is received; configuring server parameters according to the network configuration information, and receiving and installing the test system fed back by the test system server after the server parameters are configured; Running the test system, and collecting hardware information of the server to be tested through a whole machine information collection script in the test system; Generate an aging test instruction according to the server type in the hardware information; The aging test script in the test system is run according to the aging test instruction to obtain a test report.

2. The method according to claim 1, characterized in that The step of generating an aging test instruction according to the server type in the hardware information includes: According to the server type in the hardware information, at least one test program corresponding to the server type is screened out from the aging test script; For each of the test programs, an aging test instruction corresponding to the test program is generated.

3. The method according to claim 2, characterized in that The step of running the aging test script in the test system according to the aging test instruction to obtain a test report includes: According to the execution order of each of the aging test instructions, the test programs corresponding to each of the aging test instructions are executed in sequence to obtain the test reports corresponding to each of the test programs.

4. The method according to claim 1, characterized in that: After the aging test script in the test system is run according to the aging test instruction and a test report is obtained, the method further includes: The test report and hardware information are sent to the test system server for analyzing the test result of the server to be tested.

5. The method according to claim 1, characterized in that The step of generating an aging test instruction according to the server type in the hardware information includes: Displaying the hardware information on a display device connected to the server to be tested; In response to at least one operation instruction initiated by a user for the server type of the hardware information, determining a test program corresponding to each of the operation instructions; For each of the test programs, an aging test instruction corresponding to the test program is generated.

6. A server batch testing method, characterized in that: Applied to a test system server, the method comprises: Build the Pxe environment in the test system server; In response to address requests sent by multiple servers to be tested, feeding back corresponding network configuration information to each of the servers to be tested, wherein the network configuration information is used for the servers to be tested to perform server parameter configuration; Based on the network configuration information, the test system is sent to each of the servers to be tested; the test system includes a whole machine information collection script and an aging test script; Receiving hardware information obtained after each of the servers to be tested runs the whole machine information collection script; After receiving each of the servers to be tested and running the aging test script, a test report is obtained.

7. A server batch testing device, characterized in that: Applied to the server to be tested, the device includes: A request sending module, used to send an address request to a test system server in a Pxe environment, and receive network configuration information fed back by the test system server; A system download module, used to configure server parameters according to the network configuration information, and to receive and install the test system fed back by the test system server after the server parameters are configured; An information collection module, used to run the test system and collect hardware information of the server to be tested through a whole machine information collection script in the test system; A test instruction generating module, used for generating an aging test instruction according to the server type in the hardware information; The aging test module is used to run the aging test script in the test system according to the aging test instruction to obtain a test report.

8. A server batch testing device, characterized in that: Applied to the test system server, the device includes: Environment building module, used to build Pxe environment in the test system server; A request receiving module, used for responding to address requests sent by multiple servers to be tested, feeding back corresponding network configuration information to each of the servers to be tested, wherein the network configuration information is used for the servers to be tested to configure server parameters; A test system sending module, used to send the test system to each of the servers to be tested based on the network configuration information; the test system includes a whole machine information collection script and an aging test script; An information receiving module, used to receive the hardware information obtained after each server to be tested runs the whole machine information collection script; The test report acquisition module is used to receive the test report obtained after each server to be tested runs the aging test script.

9. An electronic device, characterized in that: It comprises a processor and a memory, wherein the memory stores computer executable instructions that can be executed by the processor, and the processor executes the computer executable instructions to implement the server batch testing method according to any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and when the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the server batch testing method described in any one of claims 1 to 6.

Citation Information

Cited By

  • Chip test configuration file generation method and device, equipment, medium and program

    CN122387765A