Unlock instant, AI-driven research and patent intelligence for your innovation.

Data recovery method, device and equipment and storage medium

A recovery method and data technology, applied in the database field, can solve the performance bottleneck, can not guarantee the continuous increase of LSN and other problems, and achieve the effect of improving system performance

Active Publication Date: 2020-06-16
SHANGHAI DAMENG DATABASE
View PDF6 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Since the LSN is globally unique, the REDO logs in each log buffer cannot guarantee that the LSN is continuously increasing. Before writing the online log, the logs in all the log buffers must be sorted according to the size of the LSN. In the system In scenarios where the pressure is relatively high and a large number of REDO logs are generated, this sorting action will become a performance bottleneck

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
  • Data recovery method, device and equipment and storage medium
  • Data recovery method, device and equipment and storage medium
  • Data recovery method, device and equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0051] figure 1 It is a flow chart of a data recovery method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation of data recovery. The method can be executed by the data recovery device in the embodiment of the present invention. The device can use software and / or or hardware implementation, such as figure 1 As shown, the method specifically includes the following steps:

[0052] S110, when the database restarts after troubleshooting, read the parallel log packets from the online log file.

[0053]Wherein, the online log file is generally created and recycled when the database is initialized, and the online log file is used to store log packets generated during normal operation of the system.

[0054] Wherein, at least two parallel logs are stored in the parallel log package, and the parallel log package is a complete parallel log package. It should be noted that due to a failure, the last parallel log package may not be complete...

Embodiment 2

[0077] Figure 2A It is a flowchart of a data recovery method in Embodiment 2 of the present invention. This embodiment is optimized based on the above embodiments. In this embodiment, obtaining the self-description information of the parallel log package includes: obtaining the self-description information stored in The self-describing information of the header of the parallel log packet. When the database is restarted after troubleshooting, before reading the parallel log package from the online log file, it also includes: when any log package buffer is full, create a parallel log package, and allocate for the parallel log package Parallel log package sequence number; copy the database log in the log package buffer area to the parallel log package in turn; count and record the self-description information of the parallel log package; write the self-description information into the parallel log package header and write parallel log packets to the online log file.

[0078] S...

Embodiment 3

[0098] image 3 It is a schematic structural diagram of a data recovery device provided in Embodiment 3 of the present invention. This embodiment is applicable to the situation of data recovery, and the device can be implemented in the form of software and / or hardware, and the device can be integrated in any device that provides the function of data recovery, such as image 3 As shown, the data recovery device specifically includes: a reading module 310 , an acquisition module 320 and a recovery module 330 .

[0099] Wherein, the reading module 310 is used to read the parallel log package from the online log file when the database is restarted after troubleshooting;

[0100] The acquisition module 320 is configured to acquire the self-description information of the parallel log package, wherein the self-description information includes: the writing start position of each parallel log in the parallel log package, the parallel log stored in the parallel log package number, the...

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 data recovery method, device and equipment and a storage medium. The method comprises the steps of reading a parallel log packet from an online log file when a database is restarted after a fault is eliminated; obtaining self-description information of the parallel log packet, the self-description information comprising a writing start position of each path of parallel log in the parallel log packet, the number of parallel logs stored in the parallel log packet, a minimum log sequence value and a maximum log sequence value in the parallel log packet, a parallel log packet serial number and the length of the parallel log packet; sorting the parallel logs according to the self-description information; and performing data recovery in sequence according to the sortedparallel logs. According to the technical scheme, the parallel log sorting action during normal operation of the system can be completely avoided, the parallel logs in the parallel log packets are sorted only through the self-description information during fault restart of the database, and the system performance can be effectively improved in a high-concurrency and high-pressure operation scene.

Description

technical field [0001] The embodiment of the present invention relates to the database field, and in particular to a data recovery method, device, equipment and storage medium. Background technique [0002] During the operation of the database system, various failures may occur, such as operating system failure or hardware failure. After the failure is eliminated, when the database restarts, the system can be restored to the moment before the failure by relying on the REDO log. [0003] The REDO log is used to record the modification operations performed by the database on the data. Each time the data is modified to generate a REDO log, a new LSN (Log Sequence Number, log sequence value) will be used to identify it. Every time a REDO log is written, the LSN value will be automatically increased. 1. An LSN value represents a database modification operation. The size relationship of the LSN can represent the modification sequence of the database. When replaying the REDO log, i...

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/1438G06F11/1471
Inventor 王海龙王蒙蒙韩朱忠
Owner SHANGHAI DAMENG DATABASE