Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

A method and a device for online migration of a database

A database, data block technology, applied in the field of database online

Active Publication Date: 2019-02-01
ZHENGZHOU YUNHAI INFORMATION TECH CO LTD
View PDF7 Cites 6 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] In order to solve the problem of database online migration in the prior art, the present invention proposes a method and device for online database migration. The source database reads all data blocks in the source database online, and synchronizes them to the target database, and the target database transfers the data Blocks are written to the local data file, and the target database completes the addition, deletion, and modification of these data blocks locally, so as to achieve the same state as the source database, and if it is a cross-operating system platform migration, the target database end database will automatically complete the size byte conversion and write data blocks into data files, if the data file types of the source database and the target database are different, the target database can automatically complete the conversion, not only can realize the online migration of the database, but also can realize the cross-operating system platform and cross-data file of the database Type of online migration, the migration process does not need to stop the business system and database, which reduces the business interruption time, improves the migration efficiency, and reduces the technical requirements for database migration engineers

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
  • A method and a device for online migration of a database
  • A method and a device for online migration of a database
  • A method and a device for online migration of a database

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0028] Such as figure 1 As shown, a method for database online migration in the technical solution of the present invention includes:

[0029] S1, configure database parameters, start key processes and allocate memory for use by the target database;

[0030] S2, the source database sends the data block to the target database. For cross-operating system platform migration, the target database converts the size and bytes and writes the data block into the data file. According to the data file type configured in the target database, the data block is written into the specified data file;

[0031] S3, the target database modifies and changes the data blocks locally after the synchronization of the data blocks of the source database is completed.

[0032]In step S1, the parameters for configuring the source database and the target database specifically include the parameter migrate_block_change_trace for specifying the path and name of the source database data block change record...

Embodiment 2

[0051] Such as figure 2 As shown, in a method for database online migration in the technical solution of the present invention, the target database writes the data block into the data file specifically:

[0052] In step S201, the target database receives the data block;

[0053] In step S202, it is judged whether the operating system of the source database is consistent with the operating system of the target database, if the judgment result is yes, then execute step S203, if the judgment result is no, then execute step S204;

[0054] In step S203, the data block is directly written into the target database data file;

[0055] In step S204, the size byte conversion is performed on the data block, that is, the storage order of the size byte is converted, and after the conversion, the data block is written into the target database data file.

[0056] In steps S201, S202, S203, and S204, before the data block is synchronized, the data block sending process will send the operat...

Embodiment 3

[0059] Such as image 3 As shown, in a method for database online migration in the technical solution of the present invention, writing data blocks into a specified data file according to the data file type configured in the target database is specifically:

[0060] In step S211, the target database receives the data block;

[0061] In step S212, it is judged whether the file type configured in the source database is consistent with the file type configured in the target database, if the judgment result is yes, then step S213 is executed, if the judgment result is no, then step S214 is executed;

[0062] In step S213, directly write the data block into the data file under the file system directory specified by the target database;

[0063] In step S214, the conversion is completed according to the parameters configured in the target database and the file type, and the data file is written into the data file under the specified file system directory of the target database.

...

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 provides a method for on-line migration of a database, The source database reads all the data blocks and all the changed data blocks in the source database on line, synchronizes them tothe target database, writes the data blocks to the local data file by the target database, and adds, deletes and modifies the data blocks locally by the target database, so as to achieve the consistent state with the source database. If across operate system platforms, Migration of file types, A target library-side database complete that conversion and writes the data block into a target databasedata file, Moreover, the invention also provides a device for online migration of a database, which not only can realize online migration of the database, but also can realize online migration of thedatabase across operating system platforms and across data file types, thereby reducing service interruption time, improving migration efficiency and lowering technical requirements for database migration engineers.

Description

technical field [0001] The invention relates to a database migration method and device, in particular to a database online method and device. Background technique [0002] There are many database change requirements during the use of relational databases, such as: server replacement, storage replacement, computer room relocation, etc. These change requirements may require the database to be migrated from one system to a new system. Database migration generally has the following methods: use the logical backup and recovery that comes with the database, the physical backup and recovery that comes with the database, cold copy after the database is closed, and use the storage's built-in replication function to copy data between two storages, etc. These migration methods more or less have some scenario restrictions. For example, the logical backup recovery migration method needs to completely stop the business system, and the database can no longer be added, deleted or modified t...

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): G06F16/21G06F16/27
Inventor 马国良
Owner ZHENGZHOU YUNHAI INFORMATION TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products