Eureka AIR delivers breakthrough ideas for toughest innovation challenges, trusted by R&D personnel around the world.

Database synchronization method and device and readable medium

A database and data technology, applied in the database field, can solve the problems of large delay and low efficiency between the host and the standby machine in database synchronization, and achieves improved writing and reading efficiency, reading efficiency, and writing. The effect of efficiency

Active Publication Date: 2018-06-15
TENCENT CLOUD COMPUTING BEIJING CO LTD
View PDF8 Cites 29 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The embodiment of this application provides a database synchronization method, device and readable medium, which can solve the problem that the host computer writes database transactions into binary log files with relatively low efficiency, thus It will cause a large delay between the synchronization of the database between the main machine and the standby machine

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
  • Database synchronization method and device and readable medium
  • Database synchronization method and device and readable medium
  • Database synchronization method and device and readable medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0030] In order to make the purpose, technical solution and advantages of the present application clearer, the implementation manners of the present application will be further described in detail below in conjunction with the accompanying drawings.

[0031] First of all, the following nouns involved in the embodiments of the application are explained:

[0032] Host: for adjusting the database according to the received database transaction, optionally, the host includes a database and a binary server. Optionally, the host may be a physical host or a virtual host, and when it is a virtual host, the host may also be called a master instance.

[0033] Standby machine: used to back up the database in the host machine. Usually, the standby machine parses the received binary log data to obtain database transactions, and executes the database transactions on the standby machine to ensure that the database of the host machine is consistent with the database of the standby machine. be...

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 application discloses a database synchronization method and device and a readable medium, and relates to the field of databases. The method includes: acquiring a database transaction; generating binlogs according to the database transaction; writing the binlogs into a temporary memory file system, wherein the temporary memory file system is a file system carrying out writing through a manner of memory writing; and synchronizing a standby machine with the binlogs stored in the temporary memory file system, wherein the standby machine is used for synchronizing a database according to the binlogs. Through writing the binlogs into the temporary memory file system in the manner of memory writing, the problem that efficiency of writing the binlogs into a binary log file by a host is lower due to lower file writing speed of the binary log file is avoided, and writing efficiency of the binlogs is improved.

Description

technical field [0001] The embodiment of the present application relates to the database field, and in particular to a database synchronization method, device and readable medium. Background technique [0002] In the field of databases, synchronizing the data in the database from the host to the standby is a major way of disaster recovery. The database data of the standby machine and the main machine are consistent. When the data of the main machine is damaged or the main machine crashes, the work can be continued directly through the database on the standby machine. [0003] Typically, a client modifies data on a database on a host through a database transaction. After the host receives several database transactions submitted by the client, before modifying the data in the database according to the database transactions, it first writes the database transactions into a binary log (English: binlog) file, and writes the binary log The log file is sent to the standby machine...

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): G06F17/30G06F11/34
CPCG06F11/3476G06F16/27
Inventor 祝百万
Owner TENCENT CLOUD COMPUTING BEIJING CO LTD
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
Eureka Blog
Learn More
PatSnap group products