Storage node recovery method, device and equipment and storage medium

A technology of storage nodes and recovery methods, applied in the field of database storage, can solve problems such as taking a long time and taking a long time, and achieve the effects of improving robustness, realizing fault recovery, and reducing data search time

Pending Publication Date: 2020-11-03
SHANGHAI DAMENG DATABASE
View PDF0 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0002] In a distributed database system based on redo logs, each storage node needs to redo according to the redo logs generated by the distributed database system to achieve the purpose of distributed storage. However, during the operation of the distributed system, a certain storage node appears After a failure, in order to quickly restore the failed storage node, data is usually re-migrated from the normal storage node to the failed storage node, so that the storage node can provide services again, but this method usually takes a long time
Another method can restore the storage node through the service log, but this method needs to analyze and identify the service log, find the missing data in the service log of the faulty storage node, and repackage the service log into a storage node that can The identified playback log also takes a lot of time

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Storage node recovery method, device and equipment and storage medium
  • Storage node recovery method, device and equipment and storage medium
  • Storage node recovery method, device and equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0025] figure 1 It is a flow chart of a storage node recovery method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation of recovering data stored in a faulty storage node in a distributed database. This method can be executed by a storage node recovery device. The device can be realized by hardware and / or software, and generally can be integrated in the log server, see figure 1 , the method provided by the embodiment of the present invention includes the following steps:

[0026] Step 110, cache at least one redo log of the storage node as a replay log.

[0027] Wherein, the storage node may be a node storing data in the distributed database, and the distributed database includes at least one storage node, and the data stored in each storage node may be the same or different. Among them, the redo log can be composed of two or more pre-allocated files, and all changes in the distributed database can be stored in these files. The...

Embodiment 2

[0041] figure 2 It is a flow chart of a storage node recovery method provided by Embodiment 2 of the present invention. The embodiment of the present invention is based on the embodiment of the above invention, and the space occupation is reduced by periodically clearing and replaying logs. See figure 2 , the storage node recovery method provided by the embodiment of the present invention includes the following steps:

[0042] Step 200, initialize the global control information of the storage node, the global control information includes at least one of the following: playback log buffer space, playback log control items, number of valid control items, starting position of valid control items, starting position of cache space, The end position of the cache space, the size of the used cache space, the size of the free cache space, and the sequence number of the processed log.

[0043] Step 210: Encapsulate the obtained redo log into a replay log, and send the replay log to t...

Embodiment 3

[0079] Figure 4 is a schematic structural diagram of a storage node recovery device provided in Embodiment 3 of the present invention, Figure 4 The illustrated apparatus can execute the method for restoring a storage node provided by any embodiment of the present invention, and has corresponding function modules and / or beneficial effects for executing the method. The apparatus may be implemented by software and / or hardware, and specifically includes: a log cache module 301 , an archive log module 302 and a recovery execution module 303 .

[0080] The log caching module 301 is configured to cache at least one redo log of the storage node as a replay log.

[0081] The archiving log module 302 is configured to determine at least one archiving task according to the replay log when it is determined that the storage node is faulty.

[0082] The restoration execution module 303 is configured to send each of the archiving tasks to the storage node if the communication of the stora...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a storage node recovery method and device, equipment and a storage medium, and the method comprises the steps: caching at least one redo log of a storage node as a playback log; when it is determined that the storage node fails, determining at least one archiving task according to the playback log; and if the communication of the storage node is recovered, sending each archiving task to the storage node to enable the storage node to execute an operation corresponding to the archiving task to achieve data recovery. According to the embodiment of the invention, the archiving task is determined through the cached playback log when the storage node fails, so that the redo log searching time in the data recovery process of the storage node is shortened, the recovery efficiency of the storage node is improved, and the robustness of the distributed database based on the storage node can be improved.

Description

technical field [0001] The embodiments of the present invention relate to the technical field of database storage, and in particular, to a storage node recovery method, device, device, and storage medium. Background technique [0002] In a distributed database system based on redo logs, each storage node needs to redo according to the redo logs generated by the distributed database system to achieve the purpose of distributed storage. However, during the operation of the distributed system, a certain storage node appears After a failure, in order to quickly restore the failed storage node, data is usually re-migrated from the normal storage node to the failed storage node, so that the storage node can provide services again, but this method usually takes a long time. Another method can restore the storage node through the service log, but this method needs to analyze and identify the service log, find the missing data in the service log of the faulty storage node, and repack...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/14
CPCG06F11/1448
Inventor 王家贤郭琰韩朱忠
Owner SHANGHAI DAMENG DATABASE
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products