Component testing method and device, communication equipment and storage medium

By designing component requirement templates and fault simulation tests, the fault problem caused by untested components in the hyper-converged all-in-one machine was solved, and testing efficiency and system stability were improved.

CN118567922APending Publication Date: 2024-08-30JINAN INSPUR DATA TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410684100.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-29
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

The existing technology fails to effectively test the components in the hyper-converged all-in-one machine, resulting in problems that may cause malfunctions and non-normal use in real customer usage scenarios.

Method used

A component testing method is proposed, which includes pre-designing component requirements and introducing standard templates, obtaining requirement information of components to be tested, deploying a fault simulation test environment, generating and executing fault simulation test cases to simulate fault conditions of different components for testing and reporting Adjustment.

Benefits of technology

By conducting fault simulation tests on the components in the hyper-converged all-in-one machine, failures caused by untested devices are avoided, and the efficiency of component testing and the operational stability and reliability of the hyper-converged all-in-one machine are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118567922A
    Figure CN118567922A
Patent Text Reader

Abstract

The embodiment of the invention provides a component testing method and device, communication equipment and a storage medium. The method comprises the steps that a standard template is introduced according to component requirements, and requirement information of a first to-be-tested component is acquired; acquiring a second to-be-tested component combined with the first to-be-tested component according to the demand information of the first to-be-tested component; deploying a fault simulation test environment; generating a fault simulation test case of the first to-be-tested component and a fault simulation test case corresponding to the second to-be-tested component; and performing a fault simulation test on the first to-be-tested component and performing a fault simulation test on the second to-be-tested component. The to-be-tested component to be introduced into the hyper-fusion all-in-one machine is tested according to the fault simulation test case of the to-be-tested component, so that the situation that the hyper-fusion all-in-one machine cannot be normally used due to the fact that testing of the components in the hyper-fusion all-in-one machine is not considered can be avoided; and the test efficiency of the to-be-tested component can be 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 hyper-converged all-in-one machines, and in particular to a component testing method, device, communication equipment and storage medium. Background Art

[0002] As cloud computing and virtualization technologies continue to mature, enterprises and organizations are increasingly inclined to migrate their IT infrastructure to the cloud to achieve greater flexibility, scalability, and cost-effectiveness. As an emerging cloud computing infrastructure solution, hyper-converged appliances can meet these needs, integrating computing, storage, and network resources to provide efficient and reliable cloud services.

[0003] Currently, the test of hyper-converged all-in-one machine is generally aimed at the whole hyper-converged all-in-one machine, that is, the whole hyper-converged all-in-one machine is subjected to performance test, stability test, stress test, etc. If the whole machine performs well in the above tests, the manufacturer will usually determine that the hyper-converged all-in-one machine has passed the test.

[0004] However, in the actual use scenario of customers, if a component in a hyper-converged appliance fails, the customer will replace the failed component for use. However, even if the component is of the same model, there are other differences, such as firmware version, which will cause the hyper-converged appliance to not work properly. Therefore, it is particularly important to test the components in the hyper-converged appliance. Summary of the invention

[0005] In view of this, the present invention aims to propose a component testing method, device, equipment and storage medium to solve the problem that the hyper-converged all-in-one machine cannot be used normally due to failure to consider testing the components in the hyper-converged all-in-one machine.

[0006] According to a first aspect of the present invention, a component testing method is provided, characterized in that it is applied to a hyper-converged all-in-one machine, and the method comprises:

[0007] Pre-design component requirements introduce standard templates;

[0008] Introducing a standard template according to the component requirements to obtain requirement information of a first component to be tested;

[0009] When the requirement information of the first component to be tested is valid, acquiring at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the first component to be tested and the second component to be tested are of different component types;

[0010] Deploying a fault simulation test environment on the hyper-converged all-in-one machine;

[0011] generating a fault simulation test case of the first component to be tested for the first component to be tested, and generating a fault simulation test case corresponding to at least one of the second components to be tested for at least one of the second components to be tested;

[0012] Execute the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and execute the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested.

[0013] Optionally, before the step of deploying a fault simulation test environment on the hyper-converged all-in-one machine, the method includes:

[0014] Performing functional tests on the first component to be tested and at least one of the second components to be tested respectively;

[0015] When the functional test is completed, a fault simulation test environment is deployed on the hyper-converged machine.

[0016] Optionally, deploying a fault simulation test environment on the hyper-converged all-in-one machine includes:

[0017] Arranging the first component to be tested and at least one of the second components to be tested on the hyper-converged machine;

[0018] When the arrangement is completed, the hyper-convergence software is deployed on the hyper-convergence integrated machine.

[0019] Optionally, the generating a fault simulation test case of the first component to be tested for the first component to be tested, and the generating a fault simulation test case corresponding to at least one of the second components to be tested for at least one of the second components to be tested respectively include:

[0020] Design fault simulation test cases for components to be tested;

[0021] Establishing a corresponding relationship between the component to be tested and the fault simulation test case of the component to be tested;

[0022] Acquire a fault simulation test case of the first component to be tested according to the first component to be tested and the correspondence between the component to be tested and the fault simulation test case of the component to be tested;

[0023] According to at least one of the second components to be tested and the correspondence between the component to be tested and the fault simulation test cases of the component to be tested, the fault simulation test cases corresponding to at least one of the second components to be tested are obtained.

[0024] Optionally, after the steps of executing the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and executing the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested, the method includes:

[0025] After completing the fault simulation test on the first component to be tested and at least one of the second components to be tested, obtaining a test case report of the first component to be tested and a test case report corresponding to each of the at least one second component to be tested, wherein the test case report includes test results corresponding to each of the plurality of test cases;

[0026] In the test case report of the first component to be tested or at least one of the second component to be tested, if there is a test case with a test result of failure, detecting the test environment;

[0027] In the event that the test environment is abnormal, the test environment is restored, and the test case with a failed test result is tested again;

[0028] If the test result of the test case is passed, the test result of the test case is adjusted to passed in the test case report of the first component to be tested or at least one of the second components to be tested.

[0029] Optionally, the component to be tested includes an independent redundant disk array card and / or a hard disk, and the fault simulation test case of the component to be tested includes a test case of the independent redundant disk array card and a test case of the hard disk;

[0030] The test case definition of the independent redundant disk array card includes the following aspects:

[0031] Simulate the failure of deploying software-defined storage by simulating power off;

[0032] In the case where it is detected that the deployment of the software defined storage fails, simulating turning on the power supply to verify whether the deployment of the software defined storage is successful;

[0033] If successful, the first test result of the independent redundant disk array card is passed;

[0034] If it fails, the first test result of the independent redundant disk array card is failure;

[0035] Get the initial disk list;

[0036] Simulate the first preset number of disks to be offline;

[0037] Get the current disk list;

[0038] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, the second test result of the independent redundant disk array card is passed;

[0039] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, the second test result of the independent redundant disk array card is failure;

[0040] The test case definition of the hard disk fault simulation test includes:

[0041] Simulate the second preset number of hard disks to be offline;

[0042] Migrating the storage data of the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine;

[0043] When the migration is completed, detecting whether the migration is successfully completed;

[0044] If successful, the test result of the hard disk is passed;

[0045] If it fails, the test result of the hard disk is considered as failed.

[0046] Optionally, the component to be tested includes a network card and / or a server, and the fault simulation test case of the component to be tested includes a test case of the network card and a test case of the server;

[0047] The test case definition of the network card includes the following aspects:

[0048] Performing environment deployment of the hyper-converged all-in-one machine through a predefined first interface;

[0049] When the environment deployment is completed, obtaining network card information through a predefined second interface and obtaining network card information through demand information of the network card, wherein the network card information includes a model of the network card and a firmware version of the network card;

[0050] If the network card information obtained through the second interface is the same as the network card information obtained through the requirement information of the network card, the first test result of the network card is passed;

[0051] If the network card information obtained through the second interface is different from the network card information obtained through the demand information of the network card, the first test result of the network card is failure;

[0052] When the environment deployment is completed, performing a network connectivity test on the network port of the network card;

[0053] If the network connectivity of the network port is normal, the second test result of the network card is passed;

[0054] If the network connectivity of the network port is abnormal, the second test result of the network card is failure;

[0055] When the environment deployment is completed, performing negotiation rate detection on the network port of the network card;

[0056] If the negotiation rate of the network port exceeds the preset threshold, the third test result of the network card is passed;

[0057] If the negotiation rate of the network port is lower than the preset threshold, the third test result of the network card is failure;

[0058] The test case of the server defines the fault simulation test of the server including:

[0059] Import virtual machine pressure templates through a predefined third interface;

[0060] Deploying multiple virtual machines in the server according to the virtual machine pressure template;

[0061] When the deployment of the multiple virtual machines is completed, starting the multiple virtual machines and keeping the multiple virtual machines in a running state within a preset time range;

[0062] During the operation of the multiple virtual machines, monitoring the performance indicators of the server;

[0063] If the performance index of the server is normal, the test result of the server is passed;

[0064] If the performance index of the server is abnormal, the test result of the server is failed.

[0065] According to a second aspect of the present invention, there is provided a component testing device, the device comprising:

[0066] The component requirement introduction standard template design module is used to pre-design the component requirement introduction standard template;

[0067] A component requirement information acquisition module, used to acquire requirement information of a first component to be tested according to the component requirement by introducing a standard template;

[0068] a component combination module, configured to obtain, if the requirement information of the first component to be tested is valid, at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the component types of the first component to be tested and the second component to be tested are different;

[0069] A test environment deployment module, used to deploy a fault simulation test environment on the hyper-converged all-in-one machine;

[0070] A test case generation module, configured to generate a fault simulation test case for the first component to be tested, and to generate a fault simulation test case corresponding to at least one of the second components to be tested;

[0071] A test case execution module is used to execute the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and to execute the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested.

[0072] Optionally, the device comprises:

[0073] A functional testing module, used for performing functional testing on the first component to be tested and at least one of the second components to be tested respectively;

[0074] The fault simulation test environment deployment module is used to deploy the fault simulation test environment on the hyper-converged all-in-one machine when the functional test is completed.

[0075] Optionally, the fault simulation test environment deployment module includes:

[0076] A component-to-be-tested placement submodule, configured to place the first component to be tested and at least one of the second components to be tested on the hyper-converged machine;

[0077] The hyper-convergence software deployment submodule is used to deploy the hyper-convergence software on the hyper-convergence integrated machine when the arrangement is completed.

[0078] Optionally, the test case generation module includes:

[0079] The test case design submodule is used to design fault simulation test cases for the components to be tested;

[0080] A corresponding relationship establishing submodule, used to establish a corresponding relationship between the component to be tested and the fault simulation test case of the component to be tested;

[0081] A first test case acquisition submodule, configured to acquire a fault simulation test case of the first component to be tested according to the first component to be tested and a correspondence between the component to be tested and the fault simulation test case of the component to be tested;

[0082] The second test case acquisition submodule is used to acquire the fault simulation test case corresponding to at least one second component to be tested according to the correspondence between at least one second component to be tested and the component to be tested and the fault simulation test case of the component to be tested.

[0083] Optionally, the device comprises:

[0084] A test case report generating module, used for obtaining a test case report of the first component to be tested and a test case report corresponding to at least one of the second components to be tested respectively after completing the fault simulation test on the first component to be tested and at least one of the second components to be tested, wherein the test case report includes test results corresponding to each of the plurality of test cases;

[0085] A test environment detection module, configured to detect the test environment if a test result of a test case is a failure in a test case report of the first component to be tested or at least one of the second component to be tested;

[0086] A test case retest module, used to restore the test environment when an abnormality occurs in the test environment, and retest the test case with a failed test result;

[0087] The test case report adjustment module is used to adjust the test result of the test case to pass in the test case report of the first component to be tested or at least one of the second components to be tested if the test result of the test case is pass.

[0088] Optionally, the component to be tested includes an independent redundant disk array card and / or a hard disk, and the fault simulation test case of the component to be tested includes a test case of the independent redundant disk array card and a test case of the hard disk;

[0089] The test case definition of the independent redundant disk array card includes the following aspects:

[0090] Simulate the failure of deploying software-defined storage by simulating power off;

[0091] In the case where it is detected that the deployment of the software defined storage fails, simulating turning on the power supply to verify whether the deployment of the software defined storage is successful;

[0092] If successful, the first test result of the independent redundant disk array card is passed;

[0093] If it fails, the first test result of the independent redundant disk array card is failure;

[0094] Get the initial disk list;

[0095] Simulate the first preset number of disks to be offline;

[0096] Get the current disk list;

[0097] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, the second test result of the independent redundant disk array card is passed;

[0098] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, the second test result of the independent redundant disk array card is failure;

[0099] The test case definition of the hard disk fault simulation test includes:

[0100] Simulate the second preset number of hard disks to be offline;

[0101] Migrating the storage data of the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine;

[0102] When the migration is completed, detecting whether the migration is successfully completed;

[0103] If successful, the test result of the hard disk is passed;

[0104] If it fails, the test result of the hard disk is considered as failed.

[0105] Optionally, the component to be tested includes a network card and / or a server, and the fault simulation test case of the component to be tested includes a test case of the network card and a test case of the server;

[0106] The test case definition of the network card includes the following aspects:

[0107] Performing environment deployment of the hyper-converged all-in-one machine through a predefined first interface;

[0108] When the environment deployment is completed, obtaining network card information through a predefined second interface and obtaining network card information through demand information of the network card, wherein the network card information includes a model of the network card and a firmware version of the network card;

[0109] If the network card information obtained through the second interface is the same as the network card information obtained through the requirement information of the network card, the first test result of the network card is passed;

[0110] If the network card information obtained through the second interface is different from the network card information obtained through the demand information of the network card, the first test result of the network card is failure;

[0111] When the environment deployment is completed, performing a network connectivity test on the network port of the network card;

[0112] If the network connectivity of the network port is normal, the second test result of the network card is passed;

[0113] If the network connectivity of the network port is abnormal, the second test result of the network card is failure;

[0114] When the environment deployment is completed, performing negotiation rate detection on the network port of the network card;

[0115] If the negotiation rate of the network port exceeds the preset threshold, the third test result of the network card is passed;

[0116] If the negotiation rate of the network port is lower than the preset threshold, the third test result of the network card is failure;

[0117] The test case of the server defines the fault simulation test of the server including:

[0118] Import virtual machine pressure templates through a predefined third interface;

[0119] Deploying multiple virtual machines in the server according to the virtual machine pressure template;

[0120] When the deployment of the multiple virtual machines is completed, starting the multiple virtual machines and keeping the multiple virtual machines in a running state within a preset time range;

[0121] During the operation of the multiple virtual machines, monitoring the performance indicators of the server;

[0122] If the performance index of the server is normal, the test result of the server is passed;

[0123] If the performance index of the server is abnormal, the test result of the server is failed.

[0124] According to another aspect of the present invention, there is also provided an electronic device, comprising:

[0125] processor;

[0126] a memory for storing instructions executable by the processor;

[0127] The processor is configured to execute the instructions to implement the component testing method as described above.

[0128] According to another aspect of the present invention, a readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the component testing method described above are implemented.

[0129] The component testing method provided by the embodiment of the present invention is applied to a hyper-converged all-in-one machine, pre-designing a standard template for introducing component requirements; obtaining the requirement information of a first component to be tested according to the standard template for introducing component requirements; obtaining at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested when the requirement information of the first component to be tested is valid, wherein the component types of the first component to be tested and the second component to be tested are different; deploying a fault simulation test environment on the hyper-converged all-in-one machine; generating a fault simulation test case of the first component to be tested for the first component to be tested, and generating at least one fault simulation test case corresponding to each of the second components to be tested for at least one second component to be tested; executing the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and executing the fault simulation test case corresponding to each of the at least one second component to be tested to perform a fault simulation test on each of the at least one second component to be tested. The present invention tests the component to be tested according to the fault simulation test case of the component to be tested for the component to be introduced into the hyper-converged all-in-one machine, which can not only avoid the situation that the hyper-converged all-in-one machine cannot be used normally due to not considering testing the components in the hyper-converged all-in-one machine, but also improve the testing efficiency of the component to be tested. The present invention introduces a standard template by pre-designing component requirements from the demand side, obtains the demand information of the component to be tested according to the component requirements, and only tests the component to be tested when the demand information of the component to be tested is valid, which can effectively evaluate the necessity of testing the component to be tested and reduce the testing pressure of the component to be tested. The present invention improves the testing efficiency of the component to be tested by combining a first component to be tested with at least one second component to be tested and performing a fault simulation test together, without having to perform a fault simulation test on the components to be tested one by one. The present invention can simulate the possible failure of the component to be tested in the actual use scenario by performing a fault simulation test on the component to be tested, reduce the quality risk of the hyper-converged all-in-one machine caused by the failure of the component to be tested, and thus achieve the technical effect of improving the operational stability and reliability of the hyper-converged all-in-one machine.

[0130] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0131] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art are briefly introduced below.

[0132] Figure 1 One of the step flow charts of a component testing method provided by an embodiment of the present invention;

[0133] Figure 2 This is a second step flow chart of a component testing method provided by an embodiment of the present invention;

[0134] Figure 3 This is a flowchart of the steps of a component testing method provided by an embodiment of the present invention;

[0135] Figure 4 This is a fourth step flow chart of a component testing method provided by an embodiment of the present invention;

[0136] Figure 5 This is a step flow chart of a component testing method provided by an embodiment of the present invention;

[0137] Figure 6 is a device block diagram of a component testing device provided by an embodiment of the present invention;

[0138] Figure 7 It is a schematic diagram of a communication device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0139] To make the purpose, technical scheme and advantages of the embodiments of the present invention clearer, the embodiments of the present invention will be described in detail below in conjunction with the accompanying drawings. However, it will be appreciated by those skilled in the art that in the embodiments of the present invention, many technical details are proposed in order to enable the reader to better understand the present application. However, even without these technical details and various changes and modifications based on the following embodiments, the technical scheme claimed in the present application can be implemented. The division of the following embodiments is for the convenience of description, and should not constitute any limitation on the specific implementation of the present invention. The various embodiments can be combined and referenced with each other without contradiction.

[0140] Reference Figure 1 , shows one of the step flow charts of the component testing method provided by an embodiment of the present invention, which is applied to a hyper-converged all-in-one machine. The method may include:

[0141] Step 101, pre-design component requirements and introduce standard templates.

[0142] It should be noted that in the embodiment of the present invention, which component is introduced is more restricted by market factors. At present, the market supply is not stable, and the demand changes more frequently. Therefore, it is necessary to design a standard template for introducing component requirements from the demand side, and give various requirements for component introduction through the standard template for introducing component requirements to clarify the scope of demand. This facilitates the subsequent effective evaluation of the necessity of component testing based on the standard template for introducing component requirements, thereby reducing the testing pressure of components.

[0143] A component requirement introduction template is designed in advance, and the component requirement introduction template is shown in Table 1. The component requirement introduction template may include component model, component firmware version, whether it has been tested for compatibility, priority, inventory and supply status, quality status such as performance, whether it can be combined with other components, combinable components, and conclusions.

[0144] Among them, the component model is a unique identifier of the component, usually provided by the manufacturer; it is used to distinguish different components and ensure accurate identification during procurement, inventory management and maintenance. Component firmware version refers to the firmware version information of the component, which is crucial to ensure that the component is compatible with the existing system and to perform necessary upgrades or maintenance. Whether it has been tested for compatibility records whether the component has passed the compatibility test with the existing system or equipment. The compatibility test ensures that the new component can be seamlessly integrated into the existing environment without causing conflicts or performance issues. Priority refers to the priority of component compatibility testing, reflecting which components should be given priority for compatibility testing when compatibility testing resources are limited. Inventory and supply conditions provide information about the inventory level of components and the supplier's supply capacity, which is very important for ensuring the availability of components and the stability of the supply chain. Quality conditions such as performance record the performance indicators and quality standards of the components, including reliability, durability, efficiency, etc., which help to evaluate whether the components meet the requirements of compatibility testing. Whether it can be combined with other components indicates whether the component can be combined with other components for compatibility testing. Combinable components lists the components that can be combined with components for compatibility testing. Conclusion records the relevant remarks information of the component.

[0145] Table 1 Component requirement introduction template

[0146]

[0147] Step 102: introducing a standard template according to component requirements to obtain requirement information of a first component to be tested.

[0148] Step 103 , if the requirement information of the first component to be tested is valid, obtain at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the component types of the first component to be tested and the second component to be tested are different.

[0149] It should be noted that, in the embodiment of the present invention, the first component to be tested is a component to be introduced into the hyper-converged machine and requires compatibility testing, which may include an independent redundant disk array card, a hard disk, a network card and a server.

[0150] According to the component requirements, a standard template is introduced to collect the requirement information of the first component to be tested. The requirement information of the first component to be tested includes the component model, component firmware version, whether it has passed the compatibility test, priority, inventory and supply status, performance and other quality conditions, whether it can be combined with other components, combinable components and conclusions.

[0151] The requirement information of the first component to be tested is reviewed and evaluated to determine whether the first component to be tested meets the introduction standard. If the first component to be tested meets the introduction standard, it means that the requirement information of the first component to be tested is valid, and then at least one second component to be tested that can be combined with the first component to be tested is obtained from the requirement information of the first component to be tested, and the component types of the first component to be tested and the second component to be tested are different. For example: if the first component to be tested is an independent redundant disk array card, the requirement information of the first component to be tested shows that the components that can be combined are a hard disk and a network card, and the hard disk and the network card are the second component to be tested.

[0152] Step 104: deploy a fault simulation test environment on the hyper-converged machine.

[0153] Step 105 : generating a fault simulation test case of the first component to be tested for the first component to be tested, and generating a fault simulation test case corresponding to at least one second component to be tested for at least one second component to be tested.

[0154] Step 106 , executing the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and executing the fault simulation test case corresponding to at least one second component to be tested to perform a fault simulation test on at least one second component to be tested.

[0155] It should be noted that, in an embodiment of the present invention, after determining the first component to be tested and at least one second component to be tested, it is necessary to deploy a fault simulation test environment on the hyper-converged all-in-one machine to prepare for subsequent fault simulation testing of the first component to be tested and at least one second component to be tested.

[0156] After the fault simulation test environment is deployed, fault simulation test cases for the first component to be tested and fault simulation test cases corresponding to at least one second component to be tested can be generated respectively for the first component to be tested and at least one second component to be tested, so as to facilitate subsequent fault simulation testing of the components to be tested according to the fault simulation test cases.

[0157] After generating the fault simulation test cases, the fault simulation test cases of the first component to be tested can be executed respectively to complete the fault simulation test of the first component to be tested, and the fault simulation test cases corresponding to at least one second component to be tested can be executed respectively to complete the fault simulation test of at least one second component to be tested.

[0158] The present invention tests the components to be tested according to the fault simulation test cases of the components to be tested for the components to be introduced into the hyper-converged all-in-one machine, which can not only avoid the situation that the hyper-converged all-in-one machine cannot be used normally due to the failure to consider testing the components in the hyper-converged all-in-one machine, but also improve the test efficiency of the components to be tested. The present invention pre-designs a standard template for introducing component requirements from the demand side, obtains the demand information of the components to be tested according to the standard template for introducing component requirements, and only tests the components to be tested when the demand information of the components to be tested is valid, which can effectively evaluate the necessity of testing the components to be tested and reduce the test pressure of the components to be tested. The present invention combines a first component to be tested with at least one second component to be tested, and performs a fault simulation test together, without performing a fault simulation test on the components to be tested one by one, thereby improving the test efficiency of the components to be tested. The present invention can simulate the possible failure of the components to be tested in the real use scenario by performing a fault simulation test on the components to be tested, reduce the quality risk of the hyper-converged all-in-one machine caused by the failure of the components to be tested, and thus achieve the technical effect of improving the operational stability and reliability of the hyper-converged all-in-one machine.

[0159] Furthermore, if Figure 2 FIG. 2 shows a second flow chart of the component testing method provided by an embodiment of the present invention. In the embodiment of the present invention, the following steps may be included before step 104:

[0160] Step 201 : Perform functional tests on a first component to be tested and at least one second component to be tested respectively.

[0161] Step 202, when the functional test is completed, execute deployment of a fault simulation test environment on the hyper-converged machine.

[0162] It should be noted that, in the embodiment of the present invention, before deploying the fault simulation test environment on the hyper-converged all-in-one machine, it is necessary to first perform functional tests on the first component to be tested and at least one second component to be tested. After completing the functional tests on the first component to be tested and at least one second component to be tested, the fault simulation test environment is deployed on the hyper-converged all-in-one machine to prepare for further performing fault simulation tests on the first component to be tested and at least one second component to be tested.

[0163] The present invention performs functional tests on a first component to be tested and at least one second component to be tested before deploying a fault simulation test environment. This not only ensures that these components can meet basic functional requirements under normal working conditions, providing a reliable basis for subsequent fault simulation tests, but also ensures that only components with normal functions will enter the fault simulation test stage, thereby helping to reduce test risks caused by functional defects of the components themselves.

[0164] Furthermore, if Figure 3 FIG. 3 shows a flowchart of the steps of the component testing method provided by the embodiment of the present invention. In the embodiment of the present invention, step 104 may also include the following steps:

[0165] Step 301: Arrange a first component to be tested and at least one second component to be tested on a hyper-converged machine.

[0166] It should be noted that, in an embodiment of the present invention, the training sample data set contains multiple sample alarm information, and the target text features and target spatiotemporal features of each sample alarm information in the training sample data set are obtained respectively; at the same time, the test sample data set contains multiple sample alarm information, and the target text features and target spatiotemporal features of each sample alarm information in the test sample data set are obtained respectively.

[0167] Step 302: When the arrangement is completed, the hyper-convergence software is deployed on the hyper-convergence integrated machine.

[0168] It should be noted that, in an embodiment of the present invention, the specific implementation process of deploying a fault simulation test environment on a hyper-converged all-in-one machine is: physically or logically arrange the first component to be tested and at least one second component to be tested at corresponding positions on the hyper-converged all-in-one machine; after completing the arrangement of the first component to be tested and at least one second component to be tested, deploy the hyper-converged software on the hyper-converged all-in-one machine through specific tools to ensure that the subsequent hyper-converged all-in-one machine can operate normally and execute fault simulation test cases of the first component to be tested and at least one second component to be tested.

[0169] The present invention provides a necessary test environment for subsequent fault simulation testing by arranging the components to be tested on a hyper-converged all-in-one machine and deploying the fusion software on the hyper-converged all-in-one machine, ensuring that the test cases can accurately simulate the fault conditions, thereby improving the effectiveness of the fault simulation testing.

[0170] Furthermore, if Figure 4 FIG. 4 shows a flowchart of the steps of the component testing method provided by the embodiment of the present invention. In the embodiment of the present invention, step 105 may also include the following steps:

[0171] Step 401, designing a fault simulation test case for the component to be tested.

[0172] Step 402: Establish a correspondence between the component to be tested and the fault simulation test case of the component to be tested.

[0173] It should be noted that in the embodiments of the present invention, a series of fault simulation test cases of the components to be tested are designed according to the characteristics of the components to be tested and possible failure modes. These test cases should cover various possible failure scenarios, including but not limited to hardware failure, software failure, network failure, etc.

[0174] After completing the design of the fault simulation test cases of the components to be tested, a one-to-one correspondence is established between the components to be tested and the fault test cases of the components to be tested, ensuring that each component to be tested has a corresponding fault simulation test case to evaluate the performance of the component to be tested under fault simulation. For example: create a mapping table or database, which records the correspondence between each component to be tested and its corresponding fault test case. The mapping table or database can be used to quickly and easily find and select the fault simulation test case corresponding to the component to be tested.

[0175] Step 403: acquiring a fault simulation test case of the first component to be tested according to the first component to be tested and the corresponding relationship between the component to be tested and the fault simulation test case of the component to be tested.

[0176] Step 404: acquiring the fault simulation test case corresponding to each of the at least one second component to be tested according to the correspondence between the at least one second component to be tested and the component to be tested and the fault simulation test case of the component to be tested.

[0177] It should be noted that, in an embodiment of the present invention, the fault simulation test case corresponding to the first component to be tested is obtained according to the correspondence between the component to be tested and the fault simulation test case of the component to be tested established in step 402; and the fault simulation test case corresponding to each of at least one second component to be tested is obtained according to the correspondence between the component to be tested and the fault simulation test case of the component to be tested established in step 402.

[0178] The present invention can effectively improve the coverage and efficiency of fault simulation testing by designing fault simulation test cases and establishing a corresponding relationship between components to be tested and fault simulation test cases. The present invention obtains fault simulation test cases of components to be tested according to the established corresponding relationship between components to be tested and fault simulation test cases, which can ensure that each component to be tested has a targeted fault simulation test case, which helps to improve the pertinence and effectiveness of fault simulation testing.

[0179] Furthermore, if Figure 5 FIG. 5 shows a flowchart of the step of the component testing method provided by the embodiment of the present invention. In the embodiment of the present invention, after step 106, the following steps may also be included:

[0180] Step 501, after completing the fault simulation test on the first component to be tested and at least one second component to be tested, obtain the test case report of the first component to be tested and the test case report corresponding to each of the at least one second component to be tested, wherein the test case report includes test results corresponding to each of the multiple test cases.

[0181] It should be noted that, in the embodiment of the present application, in the process of executing the fault simulation test case of the first component to be tested or in the process of executing the fault simulation test case of at least one second component to be tested, the test result of each fault simulation test case is recorded. After completing the fault simulation test of the first component to be tested and the at least one second component to be tested, the test result of each fault simulation test case of the first component to be tested is summarized to obtain a test case report of the first component to be tested, and the test result of each fault simulation test case of each second component to be tested is summarized to obtain a test case report corresponding to each of the at least one second component to be tested.

[0182] Step 502: If there is a test case in the test case report of the first component to be tested or at least one second component to be tested whose test result is failed, the test environment is detected.

[0183] Step 503: If there is an abnormality in the test environment, the test environment is restored, and the test cases with failed test results are tested again.

[0184] Step 504: If the test result of the test case is passed, the test result of the test case is adjusted to passed in the test case report of the first component to be tested or at least one second component to be tested.

[0185] It should be noted that, in the embodiment of the present invention, in the test case report corresponding to the first component to be tested or at least one second component to be tested, if there is a fault simulation test case with a test result of failure, the test environment is first detected. In the case where there is an abnormality in the test environment, it means that the test environment has affected the execution of the fault simulation test case, for example: network fluctuations in the computer room, old machinery and equipment, etc., so for the test case with a test result of failure, the abnormality in the test environment must first be eliminated and the test environment must be restored. In the case where there is no abnormality in the test environment, it means that the test environment has not affected the execution of the test case with a test result of failure, and there is no need to test the test case with a test result of failure again.

[0186] After the test environment is restored, the test case with a failed test result is executed again, and the test result of the test case is recorded again. If the test result of the test case is passed, it means that the previous test result of the test case was affected by the test environment, and the test result of this test case should be used as the basis, and the test result of this test case should replace the previous test result of the test case in the test case report, that is, change "failed" to "passed".

[0187] The present invention helps to improve the stability of the fault simulation test environment by timely recovery when an abnormality is found in the test environment, ensuring that the fault simulation test results are not affected by external factors. The present invention can improve the reliability of the fault simulation test results by re-executing the test case after the test environment is restored and updating the test results, ensuring that the final test report reflects the real test results in a stable test environment.

[0188] Further, in an embodiment of the present invention, the components to be tested include independent redundant disk array cards and / or hard disks, and the fault simulation test cases of the components to be tested include test cases of the independent redundant disk array cards and test cases of the hard disks; wherein, the test case definition of the independent redundant disk array card includes: simulating the failure of deploying software-defined storage by simulating power off; in the case of detecting the failure of deploying software-defined storage, simulating turning on the power to verify whether the deployment of software-defined storage is successful; if successful, the first test result of the independent redundant disk array card is passed; if failed, the first test result of the independent redundant disk array card is failed.

[0189] It should be noted that, in an embodiment of the present invention, the component to be tested includes an independent redundant disk array card, and the fault simulation test case of the component to be tested includes a test case of the independent redundant disk array card. Among them, the test case definition of the independent redundant disk array card The fault simulation test of the independent redundant disk array card includes: simulating the failure of deploying software-defined storage by simulating turning off the power of the server host; in the case of detecting the failure of deploying software-defined storage, simulating turning on the power of the server host to verify whether the deployment of software-defined storage is successful; if successful, the first test result of the independent redundant disk array card is passed; if failed, the first test result of the independent redundant disk array card is failed.

[0190] Among them, the test case definition of the independent redundant disk array card The fault simulation test of the independent redundant disk array card also includes: obtaining an initial disk list; simulating a first preset number of disks to be offline; obtaining a current disk list; if the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, then the second test result of the independent redundant disk array card is passed; if the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, then the second test result of the independent redundant disk array card is failed.

[0191] It should be noted that, in the embodiment of the present invention, the test case definition of the independent redundant disk array card The fault simulation test of the independent redundant disk array card also includes: obtaining the initial disk list; simulating the first preset number of disks to be offline, specifically, simulating the disk offline by using the echo "offline" > sys / block / sdx / device / state command; after completing the simulation of the disk offline, obtaining the current disk list; if the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, the second test result of the independent redundant disk array card is passed; if the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, the second test result of the independent redundant disk array card is failed. It should be noted that after the test is completed, the "running" > sys / block / sdx / device / state command is used to restore the online status of all disks.

[0192] In addition, if there is only one disk of the same type left, simulating the offline of the disk is prohibited.

[0193] Among them, the test case definition of the hard disk fault simulation test includes: simulating the second preset number of hard disks to be offline; migrating the storage data of the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine; when the migration is completed, detecting whether the migration is successfully completed; if successful, the test result of the hard disk is passed; if failed, the test result of the hard disk is failed.

[0194] It should be noted that, in an embodiment of the present invention, the component to be tested includes a hard disk, and the fault simulation test case of the component to be tested includes a test case of a hard disk. Among them, the test case of the hard disk defines that the fault simulation test of the hard disk includes: simulating the second preset number of hard disks to be offline, that is, stop working or cannot be accessed, by using a tool or script; migrating the storage data in the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine; when the migration is completed, using the jet cluster tasks-did command to detect whether the migration is successfully completed; if successful, the test result of the hard disk is passed; if failed, the test result of the hard disk is failed.

[0195] By performing fault simulation tests on independent redundant disk array cards and hard disks, the present invention can comprehensively evaluate the performance of these key components in the hyper-converged all-in-one machine under various fault simulation scenarios, thereby avoiding the situation where the hyper-converged all-in-one machine cannot be used normally due to independent redundant disk array cards or hard disks, and can effectively improve the stability and reliability of the hyper-converged all-in-one machine and enhance customer confidence in product quality.

[0196] Further, in an embodiment of the present invention, the components to be tested include a network card and / or a server, and the fault simulation test cases of the components to be tested include test cases of the network card and test cases of the server; wherein, the test case definition of the network card fault simulation test includes: performing an environment deployment of a hyper-converged all-in-one machine through a predefined first interface; when the environment deployment is completed, obtaining network card information through a predefined second interface and obtaining network card information through demand information of the network card, wherein the network card information includes the model of the network card and the firmware version of the network card; if the network card information obtained through the second interface is the same as the network card information obtained through the demand information of the network card, the first test result of the network card is passed; if the network card information obtained through the second interface is different from the network card information obtained through the demand information of the network card, the first test result of the network card is failed.

[0197] It should be noted that, in the embodiment of the present invention, the component to be tested includes a network card, and the fault simulation test case of the component to be tested includes a test case of the network card. Among them, the test case definition of the network card fault simulation test includes: performing the environment deployment of the hyper-converged all-in-one machine through a pre-defined first interface, including installing the operating system, configuring network settings, deploying necessary software and services, etc., wherein the first interface is the product interface on the hyper-converged all-in-one machine; when the environment deployment is completed, obtaining the network card information through a pre-defined second interface and obtaining the network card information through the network card demand information, wherein the second interface is the product interface on the hyper-converged all-in-one machine, and the network card information includes the model of the network card and the firmware version of the network card; obtaining the network card information through the second interface and obtaining the network card information according to the network card demand information, wherein the network card demand information includes the network card information corresponding to the network card; comparing the network card information obtained through the second interface with the network card information obtained according to the network card demand information; if the network card information obtained through the second interface is the same as the network card information obtained through the network card demand information, the first test result of the network card is passed; if the network card information obtained through the second interface is different from the network card information obtained through the network card demand information, the first test result of the network card is failed.

[0198] Among them, the test case definition of the network card fault simulation test also includes: when the environment deployment is completed, the network connectivity of the network port of the network card is detected; if the network connectivity of the network port is normal, the second test result of the network card is passed; if the network connectivity of the network port is abnormal, the second test result of the network card is failed.

[0199] It should be noted that, in an embodiment of the present invention, the test case definition of the network card fault simulation test also includes: performing an environment deployment of the hyper-converged all-in-one machine through a pre-defined first interface, including installing an operating system, configuring network settings, deploying necessary software and services, etc., wherein the first interface is the product interface on the hyper-converged all-in-one machine; when the environment deployment is completed, performing a network connectivity check on the network port of the network card, specifically, by using a network diagnostic tool to detect each network port of the network card, these tools can help determine whether the network port can communicate with other devices on the network; if the network connectivity of the network port is normal, indicating that the network port can successfully send and receive data packets, the second test result of the network card is passed; if the network connectivity of the network port is abnormal, indicating that the network port cannot successfully send and receive data packets, the second test result of the network card is failed.

[0200] Among them, the test case definition of the network card fault simulation test also includes: when the environment deployment is completed, the network port of the network card is subject to negotiation rate detection; if the negotiation rate of the network port exceeds the preset threshold, the third test result of the network card is passed; if the negotiation rate of the network port is lower than the preset threshold, the third test result of the network card is failed.

[0201] It should be noted that, in an embodiment of the present invention, the test case definition of the network card fault simulation test also includes: performing environmental deployment of the hyper-converged all-in-one machine through a pre-defined first interface, including installing an operating system, configuring network settings, deploying necessary software and services, etc., wherein the first interface is the product interface on the hyper-converged all-in-one machine; when the environmental deployment is completed, performing a negotiation rate detection on the network port of the network card, wherein the negotiation rate refers to the transmission rate automatically negotiated and determined between the network port and the connected network device (such as a switch), usually in Mbps or Gbps, and can be specifically queried by using network diagnostic tools or commands. These tools can help determine the current negotiation rate of the network port; if the negotiation rate of the network port exceeds a preset threshold, it means that the current negotiation rate of the network port meets or exceeds the expected performance requirements, and the third test result of the network card is passed; if the negotiation rate of the network port is lower than the preset threshold, it means that the current negotiation rate of the network port fails to meet the expected performance requirements, and the third test result of the network card is failed.

[0202] Among them, the test case definition of the server fault simulation test includes: importing a virtual machine stress template through a pre-defined third interface; deploying multiple virtual machines in the server according to the virtual machine stress template; when multiple virtual machines are deployed, starting multiple virtual machines and keeping multiple virtual machines in operation within a preset time range; during the operation of multiple virtual machines, monitoring the performance indicators of the server; if the performance indicators of the server are normal, the test result of the server is passed; if the performance indicators of the server are abnormal, the test result of the server is failed.

[0203] It should be noted that, in the embodiment of the present invention, the hyper-converged all-in-one machine is composed of at least 3 servers.

[0204] The components to be tested include servers, and the fault simulation test cases of the components to be tested include test cases of servers. The test case definition of the server includes: importing a virtual machine stress template through a predefined third interface, wherein the third interface is an interface of the server product, and the virtual machine stress template defines the configuration of the virtual machine, including the requirements of CPU, memory, disk and network resources; deploying multiple virtual machines in the server according to the virtual machine stress template, and these virtual machines will be configured to simulate different workloads to test the performance and stability of the server; when multiple virtual machines are deployed, start the multiple virtual machines and keep the multiple virtual machines in operation within a preset time range, which may be one hour, one day or longer, depending on the purpose and requirements of the test; during the operation of multiple virtual machines, use monitoring tools to monitor the performance indicators of the server, which may include CPU usage, memory usage, disk I / O, network throughput, etc.; if the performance indicators of the server are normal, it means that the server can handle the workload of the virtual machine without performance bottlenecks or failures, and the test result of the server is passed; if the performance indicators of the server are abnormal, it means that the server has performance problems or failures when processing the workload of the virtual machine, and the test result of the server is failed.

[0205] By performing fault simulation tests on network cards and servers, the present invention can comprehensively evaluate the performance of these key components in the hyper-converged all-in-one machine under various fault simulation scenarios, thereby avoiding the situation where the hyper-converged all-in-one machine cannot be used normally due to network cards or servers, and can effectively improve the stability and reliability of the hyper-converged all-in-one machine and enhance customer confidence in product quality.

[0206] Further, in an embodiment of the present invention, the following steps may be included after step 501: determining the compatibility test result of the first component to be tested based on the test case report of the first component to be tested, and determining the compatibility test result corresponding to at least one second component to be tested based on the test case report corresponding to each of the at least one second component to be tested; determining whether to introduce the first component to be tested or at least one second component to be tested based on the compatibility test result of the first component to be tested or the compatibility test result corresponding to each of the at least one second component to be tested.

[0207] It should be noted that, in the embodiment of the present application, the test case report of the first component to be tested includes the test results of all test cases. If there is at least one test case whose test result is failed and the compatibility test result of the first component to be tested is incompatible, then it is prohibited to introduce the first component to be tested and it is prohibited to use it as a component in the hyper-converged all-in-one machine; if the test results of all test cases are passed and the compatibility test result of the first component to be tested is compatible, then it is allowed to introduce the first component to be tested and it is allowed to use it as a component in the hyper-converged all-in-one machine.

[0208] The specific implementation process of determining the compatibility test result corresponding to at least one second component to be tested according to the test case report corresponding to at least one second component to be tested and determining whether to introduce at least one second component to be tested according to the compatibility test result corresponding to at least one second component to be tested is the same as that of the first component to be tested, and will not be repeated here.

[0209] The present invention determines the compatibility test results of the components to be tested according to the test reports of the components to be tested, and then determines whether to introduce the components to be tested according to the compatibility test results of the components to be tested. This can not only ensure that only components with good compatibility are introduced into the hyper-converged all-in-one machine, thereby improving the overall compatibility and stability of the hyper-converged all-in-one machine, but also avoid hyper-converged all-in-one machine failure or performance degradation caused by incompatibility of the components to be tested, thereby improving product quality and user satisfaction.

[0210] According to an embodiment of the present invention, a component testing device is also provided. Figure 6 , Figure 6 : is a device block diagram of a component testing device provided by an embodiment of the present invention, the component testing device comprising:

[0211] A component requirement introduction standard template design module 601 is used to pre-design a component requirement introduction standard template;

[0212] A component requirement information acquisition module 602 is used to acquire requirement information of a first component to be tested according to component requirement introduction of a standard template;

[0213] A component combination module 603 is used for acquiring at least one second component to be tested to be combined with the first component to be tested according to the requirement information of the first component to be tested if the requirement information of the first component to be tested is valid, wherein the component types of the first component to be tested and the second component to be tested are different;

[0214] The test environment deployment module 604 is used to deploy a fault simulation test environment on the hyper-converged machine;

[0215] The test case generation module 605 is used to generate a fault simulation test case of the first component to be tested for the first component to be tested, and to generate a fault simulation test case corresponding to at least one second component to be tested for at least one second component to be tested;

[0216] The test case execution module 606 is used to execute the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and to execute the fault simulation test case corresponding to at least one second component to be tested to perform a fault simulation test on at least one second component to be tested.

[0217] Optionally, the device comprises:

[0218] A functional testing module, used to perform functional tests on the first component to be tested and at least one second component to be tested respectively;

[0219] The fault simulation test environment deployment module is used to deploy the fault simulation test environment on the hyper-converged machine after the functional test is completed.

[0220] Optionally, the fault simulation test environment deployment module includes:

[0221] A component-to-be-tested arrangement submodule, configured to arrange a first component to be tested and at least one second component to be tested on the hyper-converged integrated machine;

[0222] The hyper-converged software deployment submodule is used to deploy the hyper-converged software on the hyper-converged integrated machine after the deployment is completed.

[0223] Optionally, the test case generation module includes:

[0224] The test case design submodule is used to design fault simulation test cases for the components to be tested;

[0225] A corresponding relationship establishing submodule is used to establish a corresponding relationship between the component to be tested and the fault simulation test case of the component to be tested;

[0226] A first test case acquisition submodule, configured to acquire a fault simulation test case of the first component to be tested according to the first component to be tested and the correspondence between the component to be tested and the fault simulation test case of the component to be tested;

[0227] The second test case acquisition submodule is used to acquire the fault simulation test case corresponding to at least one second component to be tested according to the correspondence between the component to be tested and the fault simulation test case of the component to be tested.

[0228] Optionally, the device comprises:

[0229] A test case report generating module, used for obtaining a test case report of the first component to be tested and a test case report corresponding to each of the at least one second component to be tested after completing the fault simulation test on the first component to be tested and the at least one second component to be tested, wherein the test case report includes test results corresponding to each of the multiple test cases;

[0230] A test environment detection module, configured to detect the test environment if a test result of a test case is a failure in a test case report of the first component to be tested or at least one second component to be tested;

[0231] The test case retest module is used to restore the test environment when there is an abnormality in the test environment, and retest the test cases with failed test results;

[0232] The test case report adjustment module is used to adjust the test result of the test case to pass in the test case report of the first component to be tested or at least one second component to be tested if the test result of the test case is pass.

[0233] Optionally, the component to be tested includes an independent redundant disk array card and / or a hard disk, and the fault simulation test case of the component to be tested includes a test case of the independent redundant disk array card and a test case of the hard disk;

[0234] Among them, the test case definition of the independent redundant disk array card The failure simulation test of the independent redundant disk array card includes:

[0235] Simulate the failure of deploying software-defined storage by simulating power off;

[0236] When a failure in deploying software-defined storage is detected, simulate turning on the power to verify whether the deployment of software-defined storage is successful.

[0237] If successful, the first test result of the independent redundant disk array card is passed;

[0238] If it fails, the first test result of the independent redundant disk array card is failed;

[0239] Get the initial disk list;

[0240] Simulate the first preset number of disks to be offline;

[0241] Get the current disk list;

[0242] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, the second test result of the independent redundant disk array card is passed;

[0243] If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, the second test result of the independent redundant disk array card is failure;

[0244] The hard disk test case defines the hard disk fault simulation test including:

[0245] Simulate the second preset number of hard disks to be offline;

[0246] Migrating the storage data of the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine;

[0247] When the migration is completed, check whether the migration is completed successfully;

[0248] If successful, the hard disk test result is passed;

[0249] If it fails, the hard drive test result is Failed.

[0250] Optionally, the component to be tested includes a network card and / or a server, and the fault simulation test case of the component to be tested includes a test case of the network card and a test case of the server;

[0251] Among them, the test case definition of the network card fault simulation test includes:

[0252] The environment deployment of the hyper-converged machine is performed through a pre-defined first interface;

[0253] When the environment deployment is completed, the network card information is obtained through a predefined second interface and the network card information is obtained through the network card requirement information, wherein the network card information includes the model of the network card and the firmware version of the network card;

[0254] If the network card information obtained through the second interface is the same as the network card information obtained through the network card requirement information, the first test result of the network card is passed;

[0255] If the network card information obtained through the second interface is different from the network card information obtained through the network card requirement information, the first test result of the network card is failure;

[0256] After the environment deployment is complete, perform a network connectivity test on the network port of the network card;

[0257] If the network connectivity of the network port is normal, the second test result of the network card is passed;

[0258] If the network connectivity of the network port is abnormal, the second test result of the network card is failed;

[0259] After the environment deployment is complete, the negotiation rate of the network port of the network card is detected;

[0260] If the negotiation rate of the network port exceeds the preset threshold, the third test result of the network card is passed;

[0261] If the negotiation rate of the network port is lower than the preset threshold, the third test result of the network card is failed;

[0262] Among them, the server test case defines the server fault simulation test including:

[0263] Import virtual machine pressure templates through a predefined third interface;

[0264] Deploy multiple virtual machines on the server based on the virtual machine stress template;

[0265] When multiple virtual machines are deployed, start the multiple virtual machines and keep the multiple virtual machines in a running state within a preset time range;

[0266] Monitor server performance indicators while multiple virtual machines are running;

[0267] If the server's performance indicators are normal, the server's test result is passed;

[0268] If the performance indicators of the server are abnormal, the test result of the server will be considered as failed.

[0269] The embodiment of the present invention further provides an electronic device, such as Figure 7 As shown, it includes a processor 701, a communication interface 702, a memory 703 and a communication bus 704, wherein the processor 701, the communication interface 702, and the memory 703 communicate with each other through the communication bus 704.

[0270] Memory 703, used for storing computer programs;

[0271] The processor 701 is used to execute the program stored in the memory 703 to implement the following steps:

[0272] Pre-design component requirements introduce standard templates;

[0273] Introducing a standard template according to component requirements to obtain requirement information of a first component to be tested;

[0274] When the requirement information of the first component to be tested is valid, obtaining at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the component types of the first component to be tested and the second component to be tested are different;

[0275] Deploy a fault simulation test environment on a hyper-converged machine;

[0276] Generate a fault simulation test case of the first component to be tested for the first component to be tested, and generate a fault simulation test case corresponding to at least one second component to be tested for at least one second component to be tested;

[0277] A fault simulation test case of a first component to be tested is executed to perform a fault simulation test on the first component to be tested, and a fault simulation test case corresponding to at least one second component to be tested is executed to perform a fault simulation test on at least one second component to be tested.

[0278] The communication bus mentioned in the above terminal can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0279] The communication interface is used for communication between the above terminal and other devices.

[0280] The memory may include a random access memory (RAM) or a non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0281] The above-mentioned processor 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 gate or transistor logic devices, discrete hardware components.

[0282] In another embodiment of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium stores instructions. When the instructions are executed on a computer, the computer executes the component testing method described in any one of the above embodiments.

[0283] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present invention is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk Sol logo State Disk (SSD)), etc.

[0284] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0285] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0286] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.

Claims

1. A component testing method, characterized in that: Applied to a hyper-converged all-in-one machine, the method includes: Pre-design component requirements introduce standard templates; Introducing a standard template according to the component requirements to obtain requirement information of a first component to be tested; When the requirement information of the first component to be tested is valid, acquiring at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the first component to be tested and the second component to be tested are of different component types; Deploying a fault simulation test environment on the hyper-converged all-in-one machine; generating a fault simulation test case of the first component to be tested for the first component to be tested, and generating a fault simulation test case corresponding to at least one of the second components to be tested for at least one of the second components to be tested; Execute the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and execute the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested.

2. The method according to claim 1, characterized in that Before the step of deploying a fault simulation test environment on the hyper-converged all-in-one machine, the method includes: Performing functional tests on the first component to be tested and at least one of the second components to be tested respectively; When the functional test is completed, a fault simulation test environment is deployed on the hyper-converged machine.

3. The method according to claim 1, characterized in that Deploying a fault simulation test environment on the hyper-converged integrated machine includes: Arranging the first component to be tested and at least one of the second components to be tested on the hyper-converged machine; When the arrangement is completed, the hyper-convergence software is deployed on the hyper-convergence integrated machine.

4. The method according to claim 3, characterized in that Generating a fault simulation test case of the first component to be tested for the first component to be tested, and generating a fault simulation test case corresponding to at least one of the second components to be tested for at least one of the second components to be tested respectively, comprises: Design fault simulation test cases for components to be tested; Establishing a corresponding relationship between the component to be tested and the fault simulation test case of the component to be tested; Acquire a fault simulation test case of the first component to be tested according to the first component to be tested and the correspondence between the component to be tested and the fault simulation test case of the component to be tested; According to at least one of the second components to be tested and the correspondence between the component to be tested and the fault simulation test cases of the component to be tested, the fault simulation test cases corresponding to at least one of the second components to be tested are obtained.

5. The method according to claim 1, characterized in that After the steps of executing the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and executing the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested, the method includes: After completing the fault simulation test on the first component to be tested and at least one of the second components to be tested, obtaining a test case report of the first component to be tested and a test case report corresponding to each of the at least one second component to be tested, wherein the test case report includes test results corresponding to each of the plurality of test cases; In the test case report of the first component to be tested or at least one of the second component to be tested, if there is a test case with a test result of failure, detecting the test environment; In the event that the test environment is abnormal, the test environment is restored, and the test case with a failed test result is tested again; If the test result of the test case is passed, the test result of the test case is adjusted to passed in the test case report of the first component to be tested or at least one of the second components to be tested.

6. The method according to claim 4, characterized in that The component to be tested includes an independent redundant disk array card and / or a hard disk, and the fault simulation test case of the component to be tested includes a test case of the independent redundant disk array card and a test case of the hard disk; The test case definition of the independent redundant disk array card includes the following aspects: Simulate the failure of deploying software-defined storage by simulating power off; In the case where it is detected that the deployment of the software defined storage fails, simulating turning on the power supply to verify whether the deployment of the software defined storage is successful; If successful, the first test result of the independent redundant disk array card is passed; If it fails, the first test result of the independent redundant disk array card is failure; Get the initial disk list; Simulate the first preset number of disks to be offline; Get the current disk list; If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is equal to the first preset number, the second test result of the independent redundant disk array card is passed; If the difference between the number of disks in the current disk list and the number of disks in the initial disk list is not equal to the first preset number, the second test result of the independent redundant disk array card is failure; The test case definition of the hard disk fault simulation test includes: Simulate the second preset number of hard disks to be offline; Migrating the storage data of the second preset number of hard disks to hard disks other than the second preset number of hard disks in the hyper-converged all-in-one machine; When the migration is completed, detecting whether the migration is successfully completed; If successful, the test result of the hard disk is passed; If it fails, the test result of the hard disk is considered as failed.

7. The method according to claim 4, characterized in that The component to be tested includes a network card and / or a server, and the fault simulation test case of the component to be tested includes a test case of the network card and a test case of the server; The test case definition of the network card includes the following aspects: Performing environment deployment of the hyper-converged all-in-one machine through a predefined first interface; When the environment deployment is completed, obtaining network card information through a predefined second interface and obtaining network card information through demand information of the network card, wherein the network card information includes a model of the network card and a firmware version of the network card; If the network card information obtained through the second interface is the same as the network card information obtained through the requirement information of the network card, the first test result of the network card is passed; If the network card information obtained through the second interface is different from the network card information obtained through the demand information of the network card, the first test result of the network card is failure; When the environment deployment is completed, performing a network connectivity test on the network port of the network card; If the network connectivity of the network port is normal, the second test result of the network card is passed; If the network connectivity of the network port is abnormal, the second test result of the network card is failure; When the environment deployment is completed, performing negotiation rate detection on the network port of the network card; If the negotiation rate of the network port exceeds the preset threshold, the third test result of the network card is passed; If the negotiation rate of the network port is lower than the preset threshold, the third test result of the network card is failure; The test case of the server defines the fault simulation test of the server including: Import virtual machine pressure templates through a predefined third interface; Deploying multiple virtual machines in the server according to the virtual machine pressure template; When the deployment of the multiple virtual machines is completed, starting the multiple virtual machines and keeping the multiple virtual machines in a running state within a preset time range; During the operation of the multiple virtual machines, monitoring the performance indicators of the server; If the performance index of the server is normal, the test result of the server is passed; If the performance index of the server is abnormal, the test result of the server is failed.

8. A component testing device, characterized in that: The component testing device comprises: The component requirement introduction standard template design module is used to pre-design the component requirement introduction standard template; A component requirement information acquisition module, used to acquire requirement information of a first component to be tested according to the component requirement by introducing a standard template; a component combination module, configured to obtain, if the requirement information of the first component to be tested is valid, at least one second component to be tested combined with the first component to be tested according to the requirement information of the first component to be tested, wherein the component types of the first component to be tested and the second component to be tested are different; A test environment deployment module, used to deploy a fault simulation test environment on the hyper-converged all-in-one machine; A test case generation module, configured to generate a fault simulation test case for the first component to be tested, and to generate a fault simulation test case corresponding to at least one of the second components to be tested; A test case execution module is used to execute the fault simulation test case of the first component to be tested to perform a fault simulation test on the first component to be tested, and to execute the fault simulation test case corresponding to at least one of the second components to be tested to perform a fault simulation test on at least one of the second components to be tested.

9. An electronic device, characterized in that: include: a memory for storing processor-executable instructions; The processor is configured to execute the instructions to implement the component testing method according to any one of claims 1 to 7.

10. A readable storage medium, characterized in that: The readable storage medium stores a computer program, and when the computer program is executed by a processor, the component testing method according to any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Automatic test method, device and equipment of intelligent mattress, medium and product

    CN121595239A