Cluster recovery method, apparatus, device, and storage medium

By reallocating access addresses and establishing communication connections for storage nodes in the database cluster, the problem of node failures caused by non-hardware reasons was solved, achieving efficient cluster recovery and avoiding the need for redeployment.

CN116107957BActive Publication Date: 2025-12-09BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310118698.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-31
Publication Date
2025-12-09
Estimated Expiration
2043-01-31

AI Technical Summary

Technical Problem

When deploying a database cluster, server restarts caused by non-hardware reasons may lead to communication failures between storage nodes, resulting in node failures. Existing technologies are insufficient to effectively recover the cluster.

Method used

Cluster recovery is achieved by reassigning access addresses to different storage nodes in the target cluster from the shared storage area, establishing communication connections between storage nodes, and running storage nodes according to cluster configuration parameters.

Benefits of technology

It improves the convenience and efficiency of cluster recovery, avoids redeployment, and reduces the risk of resource waste and communication failure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116107957B_ABST
    Figure CN116107957B_ABST
Patent Text Reader

Abstract

The disclosure provides a cluster recovery method, device, equipment and storage medium, relates to the technical field of computers, and particularly relates to database cluster technology. A specific implementation scheme is as follows: in response to a cluster restart instruction for a target cluster, an access address re-allocated for different storage nodes in the target cluster is acquired from a shared storage area outside the target cluster; a communication connection between different storage nodes is established according to the access addresses; and the corresponding storage nodes are respectively run according to cluster configuration parameters of the different storage nodes in the target cluster. According to the technology of the disclosure, the convenience and recovery efficiency of cluster recovery are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of computer, in particular, to the technical field of database cluster, and specifically, to a cluster recovery method, device, equipment and storage medium. BACKGROUND

[0002] When deploying a database cluster, each storage node in the cluster is usually deployed on a different server. When the servers on which the storage nodes are deployed are relatively concentrated, or even deployed on the same server due to cost and other problems, when the deployed server is restarted due to non-hardware reasons, there will be a situation that the storage nodes in the cluster cannot effectively communicate with each other, and the nodes fail. SUMMARY

[0003] The present disclosure provides a cluster recovery method, device, equipment and storage medium.

[0004] According to an aspect of the present disclosure, a cluster recovery method is provided, comprising:

[0005] In response to a cluster restart instruction of a target cluster, an access address re-allocated for different storage nodes in the target cluster is obtained from a shared storage area outside the target cluster;

[0006] According to the access addresses, a communication connection between the different storage nodes is established;

[0007] According to the cluster configuration parameters of the different storage nodes in the target cluster, the corresponding storage nodes are respectively run.

[0008] According to another aspect of the present disclosure, an electronic device is also provided, comprising:

[0009] At least one processor; and

[0010] A memory in communication connection with the at least one processor; wherein,

[0011] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute any one of the cluster recovery methods provided by the embodiments of the present disclosure.

[0012] According to still another aspect of the present disclosure, a non-transitory computer readable storage medium storing computer instructions is also provided, wherein the computer instructions are used to enable a computer to execute any one of the cluster recovery methods provided by the embodiments of the present disclosure.

[0013] According to the technology of the present disclosure, the convenience and recovery efficiency of cluster recovery are improved.

[0014] It should be understood that the matters described in this section are not intended to identify key or essential features of the embodiments of the present disclosure, and are used only to limit the scope of the present disclosure. Other features of the present disclosure will become apparent through the following description. BRIEF DESCRIPTION OF DRAWINGS

[0015] The accompanying drawings are used to better understand the present scheme and do not limit the present disclosure. Among them:

[0016] Figure 1 is a flowchart of a cluster recovery method provided by an embodiment of the present disclosure;

[0017] Figure 2 is a structural diagram of a cluster recovery system provided by an embodiment of the present disclosure;

[0018] Figure 3 is a structural diagram of a cluster recovery device provided by an embodiment of the present disclosure;

[0019] Figure 4 is a block diagram of an electronic device for implementing the cluster recovery method of the embodiments of the present disclosure. DETAILED DESCRIPTION

[0020] The exemplary embodiments of the present disclosure are described below in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to help understanding, which should be considered only as exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Also, for the sake of clarity and conciseness, the description below omits the description of well-known functions and structures.

[0021] The cluster recovery method and cluster recovery device provided by the embodiments of the present disclosure are suitable for the scenario of recovering the target cluster in the case of non-hardware reasons causing the target cluster to fail. The cluster recovery method provided by the embodiments of the present disclosure can be executed by the cluster recovery device, which can be implemented by software and / or hardware and specifically configured in an electronic device, and the present disclosure does not make any limitation on this.

[0022] For ease of understanding, the cluster recovery method is first described in detail.

[0023] Referring to Figure 1 The cluster recovery method includes:

[0024] S101, in response to a cluster restart instruction of a target cluster, obtaining, from a shared storage area outside the target cluster, a re-allocated access address for different storage nodes in the target cluster.

[0025] The target cluster refers to a distributed storage database built by at least one storage node and dedicated to storing data. Different storage nodes can be deployed on the same or different servers. The disclosure does not make any limitation on the specific category of the target cluster. For example, the target cluster can be a Redis (Remote Dictionary Server) cluster.

[0026] In the embodiments of the disclosure, the target cluster can be understood as a to-be-restored cluster that fails due to non-hardware reasons, such as power failure, etc. The cluster restart instruction can be an instruction generated by the cluster manager when performing a restart operation on the cluster management interface, and is used to restart the target cluster. The restart operation can be a preset touch operation performed on a preset control in the cluster management interface. The preset control can be set by a technician according to needs or experience, for example, it can be a virtual key, etc. The preset touch operation can be preset or adjusted by a technician or cluster manager according to needs or experience, for example, it can be clicking a preset number of times, etc. The preset number of times can be set or adjusted by a technician or cluster manager according to actual needs or experience.

[0027] The shared storage area can be an entity device or a cloud device, as long as it is set outside the target cluster and can be accessed by each storage node in the target cluster.

[0028] The access addresses of different storage nodes in the target cluster are different, and are used to establish a communication connection with the corresponding storage node. In the case of needing to restart the target cluster, the access address allocation device will allocate new access addresses for each storage node in the target cluster in advance, avoiding confusion with previously allocated access addresses and communication chaos between nodes. In an optional embodiment, the access address allocation device can be a DHCP (Dynamic Host Configuration Protocol) server.

[0029] Alternatively, the access addresses allocated to each storage node can be distributed to the corresponding storage node, and each storage node writes its own access address into the shared storage area for other storage nodes to obtain. It can be understood that, in order to facilitate the distinction of the access addresses of different storage nodes, the node identifier and the access address of each storage node can be associated and stored in the shared storage area. The node identifier is used to uniquely distinguish each storage node.

[0030] S102, according to the access addresses, a communication connection between different storage nodes is established.

[0031] Exemplarily, the communication connection between different cluster nodes in the target cluster is established according to the access address re-allocated for each cluster node in the target cluster, so as to realize the network interconnection between the target cluster, and facilitate the storage and backup of service data between different cluster nodes in the target cluster.

[0032] In an optional embodiment, for any cluster node, the cluster node can determine whether the access to the to-be-accessed storage node is successful by sending a preset instruction to the to-be-accessed storage node corresponding to the acquired access address, so as to represent whether the communication connection between the cluster node and the corresponding to-be-accessed storage node is successful.

[0033] In a specific implementation, for any cluster node, the cluster node can access the to-be-accessed storage node corresponding to the acquired access address by a traceroute command, if the access is successful, it indicates that the communication connection between the storage node and the to-be-accessed storage node is successful, if the access fails, it indicates that the communication connection between the storage node and the to-be-accessed storage node fails.

[0034] S103, respectively running the corresponding storage nodes according to the cluster configuration parameters of different storage nodes in the target cluster.

[0035] It should be noted that the cluster configuration parameters required by the storage nodes of different identity categories in the target cluster are different, and the cluster configuration parameters corresponding to the storage nodes of different identity categories can be set or adjusted by the technical personnel according to the business requirements. The identity category can include at least one of a host node, a slave node, and a backup node. The cluster configuration parameters can be pre-stored in the shared storage area. In order to reduce the access bandwidth of the storage node and improve the running efficiency of the node re-running, the cluster configuration parameters can also be pre-stored in the local storage node.

[0036] The present disclosure stores the access address re-allocated for different storage nodes in the target cluster in the shared storage area for each storage node in the target cluster to acquire and use, and runs each storage node under the condition that the communication connection is established between different storage nodes in the target cluster, so as to realize the restart recovery of the target cluster, so that the target cluster can be recovered without re-deploying the cluster in the case of failure due to non-hardware problems, thereby improving the convenience and recovery efficiency of the cluster recovery.

[0037] On the basis of each of the above technical solutions, the access address allocation device can also directly issue the access addresses re-allocated for the respective storage nodes to the storage nodes, so as to facilitate the storage nodes to communicate with other devices in a timely manner according to their own access addresses. Correspondingly, in response to the cluster restart instruction for the target cluster, the access addresses re-allocated for the different storage nodes in the target cluster are obtained from the shared storage area outside the target cluster. This can be achieved by, in response to the cluster restart instruction for the target cluster, controlling the storage nodes to respectively write the access addresses re-allocated for the local nodes into the shared storage area, and reading the access addresses re-allocated for the non-local nodes in the target cluster from the shared storage area.

[0038] Specifically, the access address allocation device re-allocates the access addresses for the storage nodes in response to the cluster restart instruction, and issues the access addresses to the respective storage nodes. The storage nodes write the access addresses re-allocated for the local nodes (i.e. the single storage node itself) into the shared storage area in response to the cluster restart instruction and according to the access addresses obtained by the storage nodes, so as to achieve data backup and sharing of the access addresses in the shared storage area. The storage nodes obtain the access addresses re-allocated for the non-local nodes (i.e. the other storage nodes except the single storage node) from the shared storage area, so as to achieve sharing of the new access addresses of the different storage nodes among the storage nodes.

[0039] It can be understood that, by using the storage nodes to write and read the re-allocated access addresses into and from the shared storage area, it is not necessary to establish a communication connection between the access address allocation device and the shared storage area, which facilitates management and maintenance. At the same time, it is convenient for the storage nodes to communicate with other devices in a timely manner according to their own access addresses, thereby improving communication efficiency.

[0040] Since the writing time of the re-allocated new access addresses of the different storage nodes in the shared storage area can have certain differences, there is a case that a certain storage node obtains the old access address of another storage node instead of the new access address. Since the old access address no longer exists, communication failure occurs when the communication connection between the storage nodes is established subsequently. In order to effectively deal with the occurrence of communication failure, for any storage node, if the storage node is a lost storage node with communication failure, the access address allocated for the lost storage node is re-obtained from the shared storage area at a preset frequency; and the communication connection between the storage node and the corresponding lost storage node is re-established according to the obtained access address.

[0041] The lost storage node of any storage node is another storage node with communication failure to the storage node. The preset frequency can be set or adjusted by a technician according to needs or experience, or repeatedly determined through a large number of experiments.

[0042] Specifically, if any storage node exists a lost storage node with communication failure, a preset time length is waited, the access address allocated for the lost storage node of the storage node is reacquired from the shared storage area, and the communication connection between the storage node and the corresponding lost storage node is established according to the access address; if the communication connection fails to be established, that is, the lost storage node cannot be accessed, the preset time length is re-waited, and the access address of the lost storage node is continuously reacquired from the shared storage area until the cutoff condition is met. The cutoff condition can be that the communication connection between the storage node and the lost storage node is successfully established, the cumulative waiting time length meets the preset time length threshold, or the cumulative waiting times is greater than the preset times threshold. The preset time length threshold and the preset times threshold can be set by a technician according to needs or experience values, or determined through a large number of experiments. It is worth noting that the cutoff condition is constructed by introducing the preset time length threshold and / or the preset times threshold, which can avoid the situation of continuously acquiring the lost storage node in a long time and causing a dead loop.

[0043] It can be understood that the access address of the lost storage node is read from the shared storage area by reacquiring in a preset frequency, which avoids the situation that the recovery of the entire target cluster fails due to the fact that the access address of the lost storage node is written into the shared storage area later than the write time of other storage nodes, thereby providing a guarantee for effective recovery of the target cluster.

[0044] On the basis of the above technical solutions, in order to avoid unnecessary resource consumption in the case of target cluster recovery, in an optional embodiment, according to the cluster configuration parameters of different storage nodes in the target cluster, the corresponding storage nodes are respectively run, that is, if the communication between different storage nodes in the target cluster is successful, the corresponding storage nodes are respectively run according to the cluster configuration parameters of different storage nodes. Further, if there is a communication failure between storage nodes in the target cluster, any storage node in the target cluster is prohibited from running.

[0045] It can be understood that only in the case that the communication between different storage nodes in the target cluster is successful, the corresponding storage nodes are respectively run according to the cluster configuration parameters of different storage nodes, so as to realize effective recovery of the target cluster, avoid the situation that some storage nodes do not communicate successfully, and the storage nodes that have communicated successfully run and wait, which is not suitable for the condition of target cluster recovery, reduce the running waiting time of the storage nodes that have communicated successfully, and thereby avoid the waste of node running resources.

[0046] Since there are storage node pairs with master-backup relationship and / or master-slave relationship in the target cluster, the storage node pairs with master-backup relationship and / or master-slave relationship need to frequently transmit business data for backup. In order to improve the transmission efficiency of business data, in an optional embodiment, for any storage node, if the storage node communicates successfully with an associated storage node, the access address of the associated storage node in the storage node is updated for inter-node communication; wherein the associated storage node is a storage node with master-backup relationship and / or master-slave relationship with the storage node in the target cluster, that is, the storage node and the associated storage node constitute a storage node pair with master-backup relationship and / or master-slave relationship.

[0047] Among the two storage nodes with master-backup relationship, one storage node acts as a master for providing read and write services to the outside; the other storage node acts as a backup machine for synchronizing data of the corresponding master and does not provide services to the outside. Among the two storage nodes with master-slave relationship, one storage node acts as a master for providing read and write services to the outside; the other storage node acts as a slave for synchronizing data of the corresponding master and providing read services of data to the outside.

[0048] It can be understood that by storing the access address of the associated storage node in the storage node, after the target cluster is restarted and recovered, the associated storage node can be directly accessed according to the updated access address of the associated storage node in the storage node, without the need to read the access address of the associated storage node from the shared storage area every time the business data transmission is performed, reducing the use of communication bandwidth and saving communication resources, and improving the convenience of business data transmission.

[0049] On the basis of the above technical solutions, the present disclosure further provides an optimal embodiment for implementing cluster recovery.

[0050] Referring to Figure 2 The cluster recovery system shown in the figure includes a target cluster 10 and a shared storage device 20; wherein the target cluster 10 is provided with at least one storage node 11; the executable program and the cluster configuration file are provided in each storage node 11; and the shared storage file is provided in the shared storage device 20.

[0051] In the case that the target cluster is successfully deployed and normally started, the access address of the associated storage node (the other storage node with master-backup relationship and / or master-slave relationship with the storage node) is stored in the cluster configuration file of each storage node, and the corresponding associated storage node is accessed through the access address for business data transmission.

[0052] In the case that the target cluster needs to be restarted, each storage node receives a new access address which is reassigned to the storage node in the target cluster by an access address allocation device (such as a DHCP server); each storage node writes the node identifier of the local node (i.e. the storage node itself) and the new access address into the shared storage file, and reads the access address corresponding to the node identifier of the non-local node (i.e. the storage node other than the storage node itself in the target cluster) from the shared storage file.

[0053] For any storage node, the storage node accesses the read access address of the non-local node through a traceroute command; if the access is successful, it indicates that the read access address is the newly reassigned access address, and the new access address of the non-local node having a master-slave relationship and / or a master-backup relationship with the storage node is updated in the cluster configuration file of the local node for obtaining service data transmission; if the access fails, it indicates that the read access address is the old access address before the reassignment, and a preset time length (such as 1 second) is waited, and the access address of the corresponding storage node is read again from the shared storage file, and subsequent access operations are performed until the access is successful, or the accumulated waiting time length is greater than a preset time length threshold, or the accumulated access times is greater than a preset number threshold. The preset time length, the preset time length threshold and the preset number threshold can be set or adjusted by a technician according to needs or experience values.

[0054] For any storage node, if the local node can access all non-local nodes in the target cluster successfully, an executable program is run to read the cluster configuration parameters in the cluster configuration file of the local node, and the local node is run based on the read cluster configuration parameters, thereby realizing effective recovery of the target cluster.

[0055] As an implementation of the above cluster recovery method, the present disclosure further provides an optional embodiment of an execution device for implementing the above cluster recovery method.

[0056] Referring to Figure 3 The cluster recovery device 300 shown in the figure includes an access address acquisition module 301, a communication connection establishment module 302 and a storage node running module 303. Among them,

[0057] The access address acquisition module 301 is configured to, in response to a cluster restart instruction of a target cluster, acquire, from a shared storage area outside the target cluster, a reassigned access address for different storage nodes in the target cluster;

[0058] The communication connection establishment module 302 is configured to establish a communication connection between different storage nodes according to the access addresses;

[0059] The storage node running module 303 is configured to run the respective storage nodes according to the cluster configuration parameters of the different storage nodes in the target cluster.

[0060] The present disclosure introduces a shared storage area, stores the access addresses re-allocated for the different storage nodes in the target cluster, and enables the different storage nodes in the target cluster to acquire and use the access addresses, and runs the different storage nodes in the case that the communication connection is established between the different storage nodes in the target cluster, thereby achieving the restart recovery of the target cluster, enabling the target cluster to be recovered without being re-deployed in the case that the target cluster fails due to non-hardware problems, thereby improving the convenience and recovery efficiency of the cluster recovery.

[0061] In an optional embodiment, the access address acquisition module 301 comprises:

[0062] The shared storage area writing unit is configured to, in response to a cluster restart instruction of the target cluster, control the different storage nodes to write the access addresses re-allocated for the respective storage nodes into the shared storage area; and

[0063] The shared storage area reading unit is configured to read the access addresses re-allocated for the non-local storage nodes in the target cluster from the shared storage area.

[0064] In an optional embodiment, the apparatus further comprises:

[0065] The access address re-acquisition module is configured to, for any storage node, if the storage node has a communication-failed lost storage node, re-acquire the access address allocated for the lost storage node of the storage node from the shared storage area according to a preset frequency.

[0066] The communication connection re-establishment module is configured to re-establish the communication connection between the storage node and the respective lost storage node according to the acquired access address.

[0067] In an optional embodiment, the storage node running module 303 is specifically configured to:

[0068] If the communication between the different storage nodes in the target cluster is successful, the respective storage nodes are run according to the cluster configuration parameters of the different storage nodes.

[0069] In an optional embodiment, the apparatus further comprises:

[0070] The access address updating module is configured to, for any storage node, if the communication between the storage node and an associated storage node is successful, update the access address corresponding to the associated storage node in the storage node for the inter-node communication.

[0071] The associated storage node is a storage node in the target cluster that has a master-slave relationship and / or a master-backup relationship with the storage node.

[0072] The cluster recovery apparatus can execute the cluster recovery method provided by any embodiment of the present disclosure, and has the corresponding function modules and beneficial effects of executing the cluster recovery method.

[0073] In the technical solutions of the present disclosure, the collection, storage, use, processing, transmission, provision and disclosure of the access addresses and cluster configuration parameters and the like are in line with relevant legal regulations and do not violate public order and good customs.

[0074] According to embodiments of the present disclosure, the present disclosure further provides an electronic device, a readable storage medium and a computer program product.

[0075] Figure 4 A schematic block diagram of an example electronic device 400 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptops, desktops, tablets, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown here, their connections and relationships, and their functions, are meant to be examples only, and are not intended to limit the implementations of the present disclosure described and / or claimed in this document.

[0076] As shown in Figure 4 The device 400 includes a computing unit 401 that can perform various appropriate actions and processes in accordance with a computer program stored in a read-only memory (ROM) 402 or a computer program loaded from a storage unit 408 into a random access memory (RAM) 403. Various programs and data required for the operation of the device 400 can also be stored in the RAM 403. The computing unit 401, the ROM 402, and the RAM 403 are connected to each other through a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.

[0077] Various components in the device 400 are connected to the I / O interface 405, including an input unit 406, such as a keyboard, a mouse, etc., an output unit 407, such as various types of displays, speakers, etc., the storage unit 408, such as a magnetic disk, an optical disk, etc., and a communication unit 409, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 409 allows the device 400 to exchange information / data with other devices through a computer network, such as the Internet, and / or various telecommunications networks.

[0078] The computing unit 401 can be various general and / or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various specialized artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The computing unit 401 performs various methods and processes described above, such as the cluster recovery method. For example, in some embodiments, the cluster recovery method can be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 408. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 400 via the ROM 402 and / or the communication unit 409. When the computer program is loaded onto the RAM 403 and executed by the computing unit 401, one or more steps of the cluster recovery method described above can be performed. Alternatively, in other embodiments, the computing unit 401 can be configured to perform the cluster recovery method by any other appropriate means, such as by means of firmware.

[0079] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a complex programmable logic device (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0080] Program code for carrying out methods of the present disclosure can be written in any combination of one or more programming languages. The program code can be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the program code, when executed by the processor or controller, produces the functions / operations specified in the flowcharts and / or the block diagrams. The program code can be executed entirely on a machine, partially on a machine, partially on a machine and partially on a remote machine or entirely on a remote machine or server.

[0081] In the context of this disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include but is not limited to an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium will include one or more lines of electrical connections, portable computer disks, hard disk drives, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or Flash memory), optical fibers, portable compact disc read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0082] To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0083] The systems and techniques described here can be implemented in a computing system that includes a back end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front end component (e.g., a user computer having a graphical user interface or a Web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0084] The computer system can include clients and servers. This relationship can be. The servers are generally remote from the users and can be accessed via the Internet using a communication network. The relationship can be a client-server relationship over a communications network, and as such both the client and the server are typically computers, or other client and server computers. In a client-server relationship, the server is often providing functionality and data to the client. For example, the server can provide data, or functionality, to the client using any one of a number of protocols that are well known to those of ordinary skill in the art.

[0085] Artificial intelligence is a discipline that studies enabling computers to simulate some human thinking processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.), both hardware and software technologies. Artificial intelligence hardware technology generally includes technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing, etc.; artificial intelligence software technology mainly includes computer vision technology, speech recognition technology, natural language processing technology, machine learning / deep learning technology, big data processing technology, knowledge graph technology, etc.

[0086] Cloud computing refers to accessing elastic and scalable shared physical or virtual resource pools through a network, which can include servers, operating systems, networks, software, applications, and storage devices, and can deploy and manage resources in a self-service manner as needed. Through cloud computing technology, powerful data processing capabilities can be provided for artificial intelligence, blockchain, and other technology applications and model training.

[0087] It should be understood that various forms of the flow shown above can be used to reorder, add or delete steps. For example, each step described in the present disclosure can be executed in parallel, sequentially or in a different order, as long as the desired results of the technical solutions provided by the present disclosure can be achieved, which is not limited herein.

[0088] The above detailed description does not constitute a limitation on the protection scope of the present disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modifications, equivalent replacements and improvements within the spirit and principles of the present disclosure should be included in the protection scope of the present disclosure.

Claims

1. A cluster recovery method, comprising: in response to a cluster restart instruction for a target cluster, controlling each storage node to write a re-allocated access address for a local node into a shared storage area outside the target cluster, and read a re-allocated access address for a non-local node in the target cluster from the shared storage area; establishing a communication connection between different storage nodes according to each of the access addresses; running a corresponding storage node according to a cluster configuration parameter of a different storage node in the target cluster.

2. The method of claim 1, wherein, The method further comprises: for any storage node, if the storage node has a communication-failed unconnected storage node, re-acquiring the access address allocated for the unconnected storage node of the storage node from the shared storage area at a preset frequency; re-establishing the communication connection between the storage node and the corresponding unconnected storage node according to the acquired access address.

3. The method of claim 1, wherein, The running of the corresponding storage node according to the cluster configuration parameter of the different storage node in the target cluster comprises: if the communication between the different storage nodes in the target cluster is successful, running the corresponding storage node according to the cluster configuration parameter of the different storage node.

4. The method according to any one of claims 1 to 3, wherein, The method further comprises: for any storage node, if the storage node and an associated storage node successfully communicate, updating the access address corresponding to the associated storage node in the storage node for inter-node communication; wherein the associated storage node is a storage node in the target cluster that has a master-slave relationship and / or a master-backup relationship with the storage node. 5.A cluster recovery apparatus, comprising: an access address acquisition module, configured to acquire, in response to a cluster restart instruction for a target cluster, a re-allocated access address for a different storage node in the target cluster from a shared storage area outside the target cluster; a communication connection establishment module, configured to establish a communication connection between different storage nodes according to each of the access addresses; a storage node running module, configured to run a corresponding storage node according to a cluster configuration parameter of a different storage node in the target cluster; wherein the access address acquisition module comprises: a shared storage area writing unit, configured to control each of the storage nodes to write a re-allocated access address for a local node into the shared storage area in response to the cluster restart instruction for the target cluster; and a shared storage area reading unit, configured to read a re-allocated access address for a non-local node in the target cluster from the shared storage area.

6. The apparatus of claim 5, wherein, The apparatus further comprises: an access address re-acquisition module, configured to, for any storage node, if the storage node has a communication-failed unconnected storage node, re-acquire the access address allocated for the unconnected storage node of the storage node from the shared storage area at a preset frequency; a communication connection re-establishment module, configured to re-establish the communication connection between the storage node and the corresponding unconnected storage node according to the acquired access address.

7. The apparatus of claim 5, wherein, The storage node running module is specifically configured to: if the communication between the different storage nodes in the target cluster is successful, run the corresponding storage node according to the cluster configuration parameter of the different storage node.

8. The apparatus of any one of claims 5-7, wherein, The device also comprises: an access address updating module, configured to, for any storage node, if the storage node communicates successfully with an associated storage node, update the access address corresponding to the associated storage node in the storage node, for inter-node communication; wherein the associated storage node is a storage node in the target cluster that has a master-slave relationship and / or a master-backup relationship with the storage node. 9.An electronic device, comprising: at least one processor; and a memory connected to the at least one processor in communication;wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the cluster recovery method of any one of claims 1-4.

10. A non-transitory computer readable storage medium having stored thereon computer instructions, wherein, The computer instructions are used to make the computer execute the cluster recovery method according to any one of claims 1-4. 11.A computer program product comprising computer programs / instructions, which, when executed by a processor, implement the steps of the cluster recovery method of any one of claims 1-4.

Citation Information

Patent Citations

  • Data storage, reading, transmission method and management server and network node

    CN101047610A

  • Shared file management and access method for elastic storage system and related equipment

    CN110247937A