Abnormal scene multi-control cluster input and output test method and device, equipment and medium

By obtaining and caching abnormal instructions in the multi-control cluster, establishing a connection between the control node and the target host, and issuing abnormal instructions to form a fault node, the problem of input and output testing of the multi-control cluster in abnormal scenarios is solved, and the business is implemented on the node. Normal operation and efficient testing in the event of failure.

CN118819985APending Publication Date: 2024-10-22INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411030313.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-30
Publication Date
2024-10-22

AI Technical Summary

Technical Problem

In a multi-control cluster, how to effectively conduct input and output testing under abnormal scenarios to ensure that the business can operate normally when a node fails is difficult to effectively simulate and test with existing technology.

Method used

By obtaining and caching abnormal instructions, configure the connection of all control nodes in the storage cluster, establish a connection with the target host, and issue the abnormal instructions to the control node to turn it into a fault node, and perform input and output tests through the target host. , to implement testing under abnormal scenarios.

Benefits of technology

It realizes input and output testing in multi-control cluster abnormal scenarios, separates host connection configuration and test operations, improves the flexibility and automation of testing, and ensures normal business operation when a node fails.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118819985A_ABST
    Figure CN118819985A_ABST
Patent Text Reader

Abstract

The invention discloses an abnormal scene multi-control cluster input and output testing method and device, equipment and a medium, and relates to the technical field of equipment testing. The method comprises the following steps: acquiring and caching an abnormal instruction; performing connection configuration on all the control nodes in the storage cluster so as to establish connection between the control nodes and a target host according to the connection configuration; issuing the abnormal instruction to a target number of control nodes, and enabling the control nodes receiving the abnormal instruction to become fault nodes; and executing an input and output test on the storage cluster through the target host. The input and output test of the multi-control cluster in the abnormal scene can be realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of equipment testing, and in particular to a method, device, equipment and medium for testing input and output of a multi-control cluster in an abnormal scenario. Background Art

[0002] At present, storage servers mostly adopt the form of dual-controller (i.e. two controllers) clusters, which have higher reliability and business performance than single nodes. With the increase in the complexity of business scenarios, clusters have gradually expanded to multi-controller clusters such as four-controller and eight-controller clusters. A multi-controller cluster contains multiple nodes. When one or more nodes fail, whether the cluster can support the normal operation of the business is an issue that must be considered for the reliability of the multi-controller cluster; therefore, the input and output testing of the multi-controller cluster in abnormal scenarios is very important. Summary of the invention

[0003] In view of this, the purpose of the present invention is to provide a method, device, equipment and medium for testing input and output of a multi-control cluster in an abnormal scenario, which can realize input and output testing of a multi-control cluster in an abnormal scenario. The specific scheme is as follows:

[0004] In a first aspect, the present application discloses a method for testing input and output of a multi-control cluster in an abnormal scenario, comprising:

[0005] Get and cache exception instructions;

[0006] Performing connection configuration on all control nodes in the storage cluster to establish a connection between the control node and the target host according to the connection configuration;

[0007] Sending the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes;

[0008] An input and output test of the storage cluster is performed through the target host.

[0009] Optionally, before executing the input and output test on the storage cluster through the target host, the method further includes:

[0010] Configure a fault flag; the fault flag is used to indicate that the node fault is caused by the abnormal instruction issued by the user, or that the node fault is naturally generated;

[0011] Performing an input and output test on the storage cluster through the target host includes:

[0012] Reading the fault flag bit;

[0013] If the current fault flag indicates that the node fault is caused by an abnormal instruction issued by the user, the input and output test of the storage cluster is directly performed through the target host;

[0014] If the current fault flag indicates that the node fault is naturally generated, all control nodes in the storage cluster are connected and configured so that the control nodes are connected to the target host, and then the input and output test of the storage cluster is performed through the target host.

[0015] Optionally, performing an input and output test on the storage cluster through the target host includes:

[0016] Adding the target host to the storage cluster;

[0017] Mapping the storage volume on the storage cluster to the target host;

[0018] The storage volume is scanned by the target host, and a test tool is called to perform input and output testing.

[0019] Optionally, before configuring the connection of all control nodes in the storage cluster, the following steps are also included:

[0020] Obtaining a host type, and determining a target host for executing the test according to the host type; the type includes a host connected to a cluster based on a network and a host connected to a cluster using a fiber channel;

[0021] If the target host is a host based on a network connection cluster, executing the step of configuring connections for all control nodes in the storage cluster;

[0022] If the target host is a host connected to the cluster by using a light channel, the abnormal instruction is directly sent to the target number of control nodes, and the input and output test of the storage cluster is performed through the target host.

[0023] Optionally, configure the fault flag, including:

[0024] If the target host is a host based on a network connection cluster, a fault flag is configured.

[0025] Optionally, configure connections for all controller nodes in the storage cluster, including:

[0026] Acquire test parameters for input and output testing; the test parameters include port target rate and target communication address;

[0027] Determine whether the target communication address exists on the storage cluster;

[0028] If the target communication address exists, determining whether the rate of the port where the target communication address is located meets the port target rate;

[0029] If the port target rate is met, a prompt is generated indicating that the test requirement is met and no configuration is required, so that the control node establishes a network connection with the target host through the target communication address;

[0030] If the target communication address does not exist, filtering the ports in the storage cluster based on the port target rate;

[0031] If the port target rate is not met, the target communication address is deleted, and the ports in the storage cluster are screened based on the port target rate;

[0032] If a target port that meets the port target rate is screened out, the address of the target port is used as the target communication address, so that the control node establishes a network connection with the target host through the target communication address;

[0033] If the target port that meets the port target rate is not screened out, a prompt that the test condition is not met is generated.

[0034] Optionally, the abnormal scenario multi-control cluster input and output testing method further includes:

[0035] When the failed node resumes normal operation, a communication connection between the restored failed node and the target host is established according to the connection configuration corresponding to the failed node.

[0036] In a second aspect, the present application discloses an abnormal scenario multi-control cluster input and output test device, comprising:

[0037] An instruction cache module, used to obtain and cache abnormal instructions;

[0038] A connection module, used to perform connection configuration on all control nodes in the storage cluster, so as to establish a connection between the control node and the target host according to the connection configuration;

[0039] An instruction issuing module, used for issuing the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes;

[0040] A test module is used to perform input and output tests on the storage cluster through the target host.

[0041] In a third aspect, the present application discloses an electronic device, including:

[0042] Memory, used to store computer programs;

[0043] The processor is used to execute the computer program to implement the aforementioned abnormal scenario multi-control cluster input and output testing method.

[0044] In a fourth aspect, the present application discloses a computer-readable storage medium for storing a computer program; wherein the computer program, when executed by a processor, implements the aforementioned abnormal scenario multi-control cluster input and output testing method.

[0045] In the present application, the abnormal instruction is obtained and cached; the connection configuration is performed on all control nodes in the storage cluster to establish the connection between the control node and the target host according to the connection configuration; the abnormal instruction is sent to the target number of control nodes, so that the control node that receives the abnormal instruction becomes a faulty node; and the input and output test of the storage cluster is performed through the target host. It can be seen that after receiving the abnormal instruction, the pre-test preparation is performed, that is, the connection between the control node and the target host is established, and the abnormal instruction is sent to the control node after the connection is established. After the cluster abnormal state is formed, the input and output test is performed to realize the input and output test of the multi-control cluster in the abnormal scenario; and, by controlling the sending time of the abnormal instruction, the host connection configuration is separated from the host input and output test operation, so that the host connection can be flexibly performed according to the business situation. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] 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 will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.

[0047] FIG1 is a flow chart of a method for testing input and output of a multi-control cluster in an abnormal scenario provided by the present application;

[0048] FIG2 is a flowchart of a specific abnormal scenario multi-control cluster input and output testing method provided by the present application;

[0049] FIG3 is a flowchart of another specific abnormal scenario multi-control cluster input and output testing method provided by the present application;

[0050] FIG4 is a flow chart of a specific control node connection configuration method provided by the present application;

[0051] FIG5 is a specific input and output test flow chart provided by the present application;

[0052] FIG6 is a schematic diagram of the structure of an abnormal scenario multi-control cluster input and output test device provided by the present application;

[0053] FIG. 7 is a structural diagram of an electronic device provided in the present application. DETAILED DESCRIPTION

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

[0055] In the related technology, storage servers mostly adopt the form of dual-control clusters, which have higher reliability and business performance than single nodes. With the increase in the complexity of business scenarios, clusters have gradually expanded to multi-control clusters such as four-control and eight-control. A multi-control cluster contains multiple nodes. When a single or multiple nodes fail, whether the cluster can support the normal operation of the business is an issue that must be considered for the reliability of the multi-control cluster. In order to overcome the above technical problems, the present application proposes an input and output test method for a multi-control cluster in an abnormal scenario, which can realize input and output testing of a multi-control cluster in an abnormal scenario.

[0056] The present application embodiment discloses a method for testing input and output of a multi-control cluster in an abnormal scenario. Referring to FIG1 , the method may include the following steps:

[0057] Step S11: Acquire and cache abnormal instructions.

[0058] The abnormal scenario multi-control cluster input and output testing method of the present application can be applied to a test client. The user sends an abnormal instruction through the test client. After receiving the abnormal instruction, the client caches it first and does not send it out temporarily.

[0059] Step S12: performing connection configuration on all control nodes in the storage cluster to establish a connection between the control node and the target host according to the connection configuration.

[0060] Remotely configure connections for all control nodes in the storage cluster. The connection configuration includes configuring the service port IP, etc. The network connection between the control node and the target host is achieved through the connection configuration.

[0061] Further, connection configuration of all control nodes in the storage cluster may include the following steps: obtaining test parameters for input and output testing; the test parameters include a port target rate and a target communication address (such as an IP address); determining whether the target communication address exists on the storage cluster; if the target communication address exists, determining whether the rate of the port where the target communication address is located meets the port target rate; if the port target rate is met, generating a prompt that no configuration is required to meet the test requirements, so that the control node can establish a network connection with the target host through the target communication address; if the target communication address does not exist, filtering the ports in the storage cluster based on the port target rate; if the port target rate is not met, deleting the target communication address, and filtering the ports in the storage cluster based on the port target rate; if a target port that meets the port target rate is filtered out, using the address of the target port as the target communication address, so that the control node can establish a network connection with the target host through the target communication address; if a target port that meets the port target rate is not filtered out, generating a prompt that does not meet the test conditions. It is understandable that the user inputs the test parameters according to their own test requirements, such as which service port speed they want to use. The service ports in the same cluster environment may have different speeds due to different connection networks, such as 10Gb / s, 25Gb / s, 40Gb / s, and 100Gb / s; and the actual target IP address of the service IP server service network card that the service port needs to be configured. The target IP and the port target speed (speed) of the port corresponding to the target IP to be configured. First, check whether the target IP already exists in the cluster. If it already exists and the speed of the port where it is located meets the port target speed requirement, no further operation is required, and the existing port IP is directly used; if the target IP does not exist in the cluster, find a port that meets the requirements according to the port target speed, and configure the IP if it is found. If no port that meets the requirements is found, an error is reported; if the target IP exists in the cluster, but its port speed does not meet the port target speed requirement, delete the target IP from the cluster and handle it as if the IP does not exist in the cluster. Through the above operations, it is ensured that the connection between the host and the cluster control node meets the customer requirements during the input and output test, and further improves the real simulation effect of abnormal situations.

[0062] In addition, the above operation of connecting and configuring all control nodes in the storage cluster can be encapsulated into a function in specific implementation, that is, after the user receives the abnormal instruction, the function is called and executed to realize the automatic connection configuration of the control nodes.

[0063] In some embodiments, before connecting and configuring all control nodes in the storage cluster, the following may be included: obtaining the host type, and determining the target host for executing the test according to the host type; the type includes a host based on a network connection cluster and a host connected to the cluster using a fiber channel; if the target host is a host based on a network connection cluster, the step of connecting and configuring all control nodes in the storage cluster is executed; if the target host is a host connected to the cluster using a fiber channel, the abnormal instruction is directly sent to the target number of control nodes, and the input and output test of the storage cluster is executed through the target host. That is, the host type used for the test can be selected by the user, such as a host based on a network connection cluster (iSCSI (Small Computer Systems Interface, Internet Small Computer System Interface) host) and a host connected in a fiber channel (FC (Fiber Channel) host). It can be understood that if a host is connected in a fiber channel, there is no need to perform connection configuration, and the test can be performed directly.

[0064] Step S13: Send the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes.

[0065] After the connection is established, an abnormal cluster scenario is artificially created by sending abnormal instructions to the control node. The target number is a preset value, which must be less than the total number of control nodes in the cluster. The specific value is customized according to the user's test requirements.

[0066] In this embodiment, the above-mentioned abnormal instruction is an instruction for notifying the control node to power off, that is, after receiving the abnormal instruction, the control node in the storage cluster will perform a power-off operation. The abnormal instruction makes the corresponding control node a faulty node, and after becoming a faulty node, it will automatically disconnect from the target host; thus, there is no need to wait for the node to actually be abnormal before testing, and the abnormal scenario of the storage cluster can be created by actively issuing the abnormal instruction.

[0067] Step S14: executing input and output tests on the storage cluster through the target host.

[0068] After the connection is established and the abnormal scenario is formed, the input and output test (IO test) begins. For example, Figure 2 shows a complete input and output test flow chart. According to the input and output test results, the IO indicators in the current abnormal scenario are analyzed to see whether they meet expectations. If they meet expectations, the faulty node is restored and the test ends. Otherwise, further analysis is performed. Users only need to prepare the test environment and issue abnormal instructions to automatically call the automation program to perform IO tests in abnormal scenarios.

[0069] In some embodiments, before the target host performs the input and output test on the storage cluster, it may also include: configuring a fault flag; the fault flag is used to indicate that the node failure is caused by the abnormal instruction issued by the user, or the node failure is naturally generated; performing the input and output test on the storage cluster through the target host includes: reading the fault flag; if the current fault flag indicates that the node failure is caused by the abnormal instruction issued by the user, then directly performing the input and output test on the storage cluster through the target host; if the current fault flag indicates that the node failure is naturally generated, then performing connection configuration on all control nodes in the storage cluster, so that the control node establishes a connection with the target host, and then performing the input and output test on the storage cluster through the target host. In this embodiment, the test of artificially creating an abnormal scenario separates the connection configuration from the test, so it is no longer necessary to perform the connection configuration when performing the test. By setting the fault flag, it is indicated whether the node failure is caused by the abnormal instruction issued by the user, or whether the node failure is naturally generated. When the fault flag indicates that the node failure is caused by the abnormal instruction issued by the user, the test is performed directly, otherwise, it is necessary to establish a connection and then perform the test.

[0070] The above configuration of the fault flag includes: if the target host is a host based on a network connection cluster, configuring the fault flag. Since the host connected by Fibre Channel does not need to be connected, the fault flag is only configured for the host based on the network connection cluster.

[0071] Among them, performing input and output tests on the storage cluster through the target host may include: adding the target host to the storage cluster; mapping the storage volumes on the storage cluster to the target host; scanning the storage volumes through the target host, and calling a test tool to perform input and output tests.

[0072] In the related art, the IP drift function on the service network port is used for the dual-control cluster. After a node fails, the IP of its service network port is symmetrically configured on the opposite node. When the node is restored, the IP will drift from the opposite node to the local node to achieve that after the abnormality is eliminated, the storage server does not need human intervention. It only needs to trigger the connection on the host to restore the full connection between the host and the cluster. However, since the internal communication of multiple controls is more complicated and the number of nodes is large, the opposite node of a node may not be fixed, and the IP drift function cannot be used. In this application, the connection configuration and test separation method are adopted. All nodes are normal before the abnormal instruction is issued. At this time, the connection configuration is performed, and then the abnormal instruction is issued to form an abnormal scenario. When the faulty node resumes normal operation, the communication connection between the restored faulty node and the target host is established according to the connection configuration corresponding to the faulty node. That is, after the abnormal node is restored, the cluster does not need other additional operations. The host triggers the connection to restore the full connection with the cluster, that is, there is a connection with each node in the cluster.

[0073] The above-mentioned automated input and output testing method for multi-control clusters in abnormal scenarios no longer bundles the host connection pre-configuration with IO issuance according to the conventional traditional process, but uses the user's abnormal instructions to separate the host connection pre-configuration from the host's IO operation, and caches the received abnormal operation instructions at the same time, and only issues them when the judgment conditions are met. This ensures that when there are abnormal nodes in the cluster, the host can be connected normally and IO can be tested normally; and after the abnormal node is restored, the host and the storage server are fully connected, achieving the purpose of IO testing in abnormal scenarios of multi-control clusters; and the user only needs to prepare the test environment and decide the time to perform abnormal operations, and the rest can be completed by relying on automated programs.

[0074] As can be seen from the above, in this embodiment, the abnormal instruction is obtained and cached; the connection configuration is performed on all control nodes in the storage cluster to establish the connection between the control node and the target host according to the connection configuration; the abnormal instruction is sent to the target number of control nodes, so that the control node that receives the abnormal instruction becomes a faulty node; and the input and output test of the storage cluster is performed through the target host. It can be seen that after receiving the abnormal instruction, the pre-test preparation is performed, that is, the connection between the control node and the target host is established, and the abnormal instruction is sent to the control node after the connection is established. After the cluster abnormal state is formed, the input and output test is performed to realize the input and output test of the multi-control cluster in the abnormal scenario; and by controlling the sending time of the abnormal instruction, the host connection configuration is separated from the host input and output test operation, so that the host connection can be flexibly performed according to the business situation.

[0075] For example, FIG3 shows a specific method for testing the input and output of a multi-control cluster in an abnormal scenario. After receiving the abnormal instruction for the cluster issued by the user, cache it first and do not issue it temporarily; then, determine the host type parameter passed in by the user. If the parameter is an FC host, issue the cached abnormal instruction to the corresponding node of the cluster. After the cluster is executed, call the FC host to run the IO test program to perform the FC host IO test in the abnormal scenario; since the internal implementation logic of the FC host running IO has nothing to do with whether the cluster is abnormal, the existing automation method can be used directly, and this embodiment will not be repeated; if the host type parameter is iscsi, pre-configure the cluster before the iscsi connection, including configuring the service port IP, etc., and establish a connection with each node of the cluster on the host side. After the configuration is completed, issue the cached abnormal instruction, and set the flag bit (fault_nodes) indicating whether the fault has been artificially created to yes, and finally call the iscsi host to run the IO program.

[0076] The specific connection configuration method flow for all control nodes in the storage cluster is shown in Figure 4. After receiving the service IP (i.e., the target IP address) to be configured by the user and the speed (speed) of the port to which the service IP is to be configured, first check whether the service IP already exists in the cluster. If it already exists and the speed of the port where it is located meets the speed requirement, no further operation is required, and the existing port IP is directly used; if the service IP does not exist in the cluster, then search for a port that meets the requirements according to the speed, and configure the IP if it is found. If no port that meets the requirements is found, an error is reported; if the service IP exists in the cluster, but its port speed does not meet the speed requirement, then delete the service IP from the cluster and handle it as if the IP does not exist in the cluster.

[0077] The specific input and output test process is shown in Figure 5. First, the artificial fault flag fault_nodes is obtained (the default value is no). When the value is yes, it means that an artificial fault has been created on the cluster before the program is called, and the business IP and host connection have been pre-configured before the fault. In this case, you only need to continue to perform subsequent operations according to business needs: add the host to the cluster for subsequent mapping of volumes to run IO; map storage volumes to hosts, and the hosts scan volumes and start test tools to perform IO tests; if the iscsi host is called to run IO on a cluster without faults, other pre-configurations need to be added.

[0078] As can be seen from the above, the tedious work of sending abnormal instructions and connecting the host to multiple nodes is automatically encapsulated, reducing manual input; when receiving the abnormal instructions sent by the user, it is first cached for standby; at the same time, the timing of sending the abnormal instructions is determined according to the host type selected by the user. If it is an FC host, the abnormal instructions in the cache are immediately sent down. If it is an iscsi host, a series of pre-configuration operations are performed first to ensure that the host can successfully connect to each node of the storage server before sending the abnormal instructions in the cache. When there is an abnormal node in the cluster, the connection between the iscsi host and the node will be disconnected, and only the connection with the normal node will be maintained; however, when the abnormal node is restored, the host only needs to trigger the connection instruction to restore the full connection with the cluster; the cluster can directly carry out other subsequent tests without additional operations, which provides convenience for subsequent testing work and saves testing time. In this way, the purpose of performing IO testing under abnormal conditions of a multi-control cluster is achieved, and the internal implementation logic is completely encapsulated, simplifying the user operation and usage process; the user only needs to prepare the test environment and decide which node or nodes to issue abnormal instructions to, without having to be familiar with or manually intervene in subsequent test details, saving test time; at the same time, after the abnormality is recovered, the host and the cluster can be fully connected, and other subsequent tests can be carried out directly, which provides convenience for subsequent testing work.

[0079] Correspondingly, the embodiment of the present application also discloses an abnormal scenario multi-control cluster input and output test device, as shown in FIG6 , the device includes:

[0080] An instruction cache module 11, used to obtain and cache abnormal instructions;

[0081] A connection module 12, used to perform connection configuration on all control nodes in the storage cluster, so as to establish a connection between the control node and the target host according to the connection configuration;

[0082] An instruction issuing module 13, configured to issue the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes;

[0083] The testing module 14 is used to perform input and output testing on the storage cluster through the target host.

[0084] As can be seen from the above, in this embodiment, the abnormal instruction is obtained and cached; the connection configuration is performed on all control nodes in the storage cluster to establish the connection between the control node and the target host according to the connection configuration; the abnormal instruction is sent to the target number of control nodes, so that the control node that receives the abnormal instruction becomes a faulty node; and the input and output test of the storage cluster is performed through the target host. It can be seen that after receiving the abnormal instruction, the pre-test preparation is performed, that is, the connection between the control node and the target host is established, and the abnormal instruction is sent to the control node after the connection is established. After the cluster abnormal state is formed, the input and output test is performed to realize the input and output test of the multi-control cluster in the abnormal scenario; and by controlling the sending time of the abnormal instruction, the host connection configuration is separated from the host input and output test operation, so that the host connection can be flexibly performed according to the business situation.

[0085] In some specific embodiments, the abnormal scenario multi-control cluster input and output test device may specifically include:

[0086] A fault flag configuration unit is used to configure a fault flag before executing an input and output test on the storage cluster through the target host; the fault flag is used to indicate that the node failure is caused by the abnormal instruction issued by the user, or that the node failure is naturally generated;

[0087] The testing module 14 may specifically include:

[0088] A flag reading unit, used for reading the fault flag;

[0089] A test execution unit, configured to directly execute an input and output test on the storage cluster through the target host if the current fault flag indicates that the node fault is caused by an abnormal instruction issued by a user;

[0090] The connection configuration execution unit is used to perform connection configuration on all control nodes in the storage cluster if the current fault flag indicates that the node fault is naturally generated, so that the control node establishes a connection with the target host, and then performs input and output tests on the storage cluster through the target host.

[0091] In some specific embodiments, the testing module 14 may specifically include:

[0092] An adding unit, configured to add the target host to the storage cluster;

[0093] A storage volume mapping unit, used to map the storage volume on the storage cluster to the target host;

[0094] The testing unit is used to scan the storage volume through the target host and call a testing tool to perform input and output testing.

[0095] In some specific embodiments, the abnormal scenario multi-control cluster input and output test device may specifically include:

[0096] A target host determination unit is used to obtain a host type before configuring the connection of all control nodes in the storage cluster, and determine a target host for executing the test according to the host type; the type includes a host connected to the cluster based on a network and a host connected to the cluster using a fiber channel;

[0097] A connection configuration execution unit, configured to execute a step of connection configuration for all control nodes in the storage cluster if the target host is a host based on a network connection cluster;

[0098] The test execution unit is used for directly sending the abnormal instruction to a target number of control nodes if the target host is a host connected to the cluster by using a light channel, and executing an input and output test on the storage cluster through the target host.

[0099] In some specific embodiments, the fault flag configuration unit may be specifically used to configure a fault flag if the target host is a host based on a network connection cluster.

[0100] In some specific embodiments, the connection module 12 may specifically include:

[0101] A test parameter acquisition unit, used to acquire test parameters for input and output tests; the test parameters include a port target rate and a target communication address;

[0102] A target communication address determination unit, used to determine whether the target communication address exists on the storage cluster;

[0103] A rate determination unit, configured to determine whether the rate of the port where the target communication address is located satisfies the port target rate if the target communication address exists;

[0104] A first prompt unit, configured to generate a prompt that satisfies the test requirement without configuration if the port target rate is met, so that the control node establishes a network connection with the target host through the target communication address;

[0105] a screening unit, configured to screen the ports in the storage cluster based on the port target rate if the target communication address does not exist;

[0106] An address deleting unit, configured to delete the target communication address if the port target rate is not met, and filter the ports in the storage cluster based on the port target rate;

[0107] an address determining unit, configured to, if a target port that meets the port target rate is screened out, use the address of the target port as the target communication address, so that the control node establishes a network connection with the target host through the target communication address;

[0108] The second prompt unit is used to generate a prompt that the test condition is not met if the target port that meets the port target rate is not screened out.

[0109] In some specific embodiments, the abnormal scenario multi-control cluster input and output test device may specifically include:

[0110] The communication connection establishing unit is used to establish a communication connection between the restored faulty node and the target host according to the connection configuration corresponding to the faulty node after the faulty node recovers normal operation.

[0111] Furthermore, an embodiment of the present application also discloses an electronic device, as shown in FIG7 . The content in the figure cannot be regarded as any limitation on the scope of use of the present application.

[0112] FIG7 is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 is used to store a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the abnormal scenario multi-control cluster input / output test method disclosed in any of the aforementioned embodiments.

[0113] In this embodiment, the power supply 23 is used to provide working voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and the external device, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface 25 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.

[0114] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, a random access memory, a disk or an optical disk, etc. The resources stored thereon include an operating system 221, a computer program 222, and data 223 including abnormal instructions, etc. The storage method can be temporary storage or permanent storage.

[0115] Among them, the operating system 221 is used to manage and control the hardware devices and computer programs 222 on the electronic device 20 to realize the operation and processing of the massive data 223 in the memory 22 by the processor 21, which can be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program that can be used to complete the abnormal scenario multi-control cluster input and output test method performed by the electronic device 20 disclosed in any of the aforementioned embodiments, the computer program 222 can further include a computer program that can be used to complete other specific tasks.

[0116] Furthermore, an embodiment of the present application also discloses a computer program product, including a computer program / instruction, which, when executed by a processor, implements the steps of the abnormal scenario multi-control cluster input and output testing method disclosed in any of the aforementioned embodiments.

[0117] Furthermore, an embodiment of the present application also discloses a computer storage medium, in which computer executable instructions are stored. When the computer executable instructions are loaded and executed by a processor, the steps of the abnormal scenario multi-control cluster input and output testing method disclosed in any of the aforementioned embodiments are implemented.

[0118] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.

[0119] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0120] Finally, 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 presence of other identical elements in the process, method, article or device including the elements.

[0121] The above is a detailed introduction to the abnormal scenario multi-control cluster input and output testing method, device, equipment and medium provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for general technical personnel in this field, according to the idea of ​​the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims

1. A method for testing input and output of a multi-control cluster in an abnormal scenario, characterized in that: include: Get and cache exception instructions; Performing connection configuration on all control nodes in the storage cluster to establish a connection between the control node and the target host according to the connection configuration; Sending the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes; An input and output test of the storage cluster is performed through the target host.

2. The abnormal scenario multi-control cluster input and output testing method according to claim 1 is characterized in that: Before executing the input and output test on the storage cluster through the target host, the method further includes: Configure a fault flag; the fault flag is used to indicate that the node fault is caused by the abnormal instruction issued by the user, or that the node fault is naturally generated; Performing an input and output test on the storage cluster through the target host includes: Reading the fault flag bit; If the current fault flag indicates that the node fault is caused by an abnormal instruction issued by the user, the input and output test of the storage cluster is directly performed through the target host; If the current fault flag indicates that the node fault is naturally generated, all control nodes in the storage cluster are connected and configured so that the control nodes are connected to the target host, and then the input and output test of the storage cluster is performed through the target host.

3. The abnormal scenario multi-control cluster input and output testing method according to claim 2 is characterized in that: Performing an input and output test on the storage cluster through the target host includes: Adding the target host to the storage cluster; Mapping the storage volume on the storage cluster to the target host; The storage volume is scanned by the target host, and a test tool is called to perform input and output testing.

4. The abnormal scenario multi-control cluster input and output testing method according to claim 2 is characterized in that: Before connecting and configuring all control nodes in the storage cluster, the following steps are also required: Obtaining a host type, and determining a target host for executing the test according to the host type; the type includes a host connected to a cluster based on a network and a host connected to a cluster using a fiber channel; If the target host is a host based on a network connection cluster, executing the step of configuring connections for all control nodes in the storage cluster; If the target host is a host connected to the cluster by using a light channel, the abnormal instruction is directly sent to the target number of control nodes, and the input and output test of the storage cluster is performed through the target host.

5. The abnormal scenario multi-control cluster input and output testing method according to claim 4 is characterized in that: Configure the fault flag, including: If the target host is a host based on a network connection cluster, a fault flag is configured.

6. The abnormal scenario multi-control cluster input and output testing method according to claim 1 is characterized in that: Configure connections for all control nodes in the storage cluster, including: Acquire test parameters for input and output testing; the test parameters include port target rate and target communication address; Determine whether the target communication address exists on the storage cluster; If the target communication address exists, determining whether the rate of the port where the target communication address is located meets the port target rate; If the port target rate is met, a prompt is generated indicating that the test requirement is met and no configuration is required, so that the control node establishes a network connection with the target host through the target communication address; If the target communication address does not exist, filtering the ports in the storage cluster based on the port target rate; If the port target rate is not met, the target communication address is deleted, and the ports in the storage cluster are screened based on the port target rate; If a target port that meets the port target rate is screened out, the address of the target port is used as the target communication address, so that the control node establishes a network connection with the target host through the target communication address; If the target port that meets the port target rate is not screened out, a prompt that the test condition is not met is generated.

7. The abnormal scenario multi-control cluster input and output testing method according to any one of claims 1 to 6, characterized in that: Also includes: When the failed node resumes normal operation, a communication connection between the restored failed node and the target host is established according to the connection configuration corresponding to the failed node.

8. An abnormal scenario multi-control cluster input and output test device, characterized in that: include: An instruction cache module, used to obtain and cache abnormal instructions; A connection module, used to perform connection configuration on all control nodes in the storage cluster, so as to establish a connection between the control node and the target host according to the connection configuration; An instruction issuing module, used for issuing the abnormal instruction to a target number of control nodes, so that the control nodes receiving the abnormal instruction become faulty nodes; A test module is used to perform input and output tests on the storage cluster through the target host.

9. An electronic device, characterized in that: include: Memory, used to store computer programs; A processor is used to execute the computer program to implement the abnormal scenario multi-control cluster input and output testing method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: Used to store computer programs; wherein when the computer program is executed by a processor, the abnormal scenario multi-control cluster input and output testing method as described in any one of claims 1 to 7 is implemented.