Data migration methods, apparatus, devices, storage media, and program products for heterogeneous object storage

By migrating existing data first and incremental data according to log records during the switching of heterogeneous object storage facilities, combined with traffic switching distribution, the problem of long migration time is solved, ensuring uninterrupted and consistent data migration.

CN119620933BActive Publication Date: 2025-10-28CHINA MERCHANTS BANK
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411502122.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-10-28
Estimated Expiration
2044-10-25

AI Technical Summary

Technical Problem

Existing technologies result in long data migration times when switching between heterogeneous object storage facilities, impacting business continuity.

Method used

By migrating existing data before the initial timestamp in the source object storage device to the target object storage device, migrating incremental data according to the data operation records in the source object log, and switching and distributing traffic between the source and target storage devices when the incremental data migration begins, the traffic is finally redirected to the target storage device.

Benefits of technology

It achieves uninterrupted and consistent data migration, reduces migration time, and minimizes the impact on business continuity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119620933B_ABST
    Figure CN119620933B_ABST
Patent Text Reader

Abstract

This application discloses a data migration method, apparatus, device, storage medium, and program product for heterogeneous object storage, relating to the field of data management technology. The method includes: migrating existing data prior to an initial timestamp from a source object storage device to a target object storage device; migrating incremental data from the source object storage device to the target object storage device based on data operation records in the source object log; synchronizing incremental data from the target object storage device to the source object storage device; when the incremental data migration begins, switching and distributing the current traffic containing the incremental data between the source and target object storage devices; and after the current traffic switching and distribution is complete, forwarding subsequent traffic destined for the source object storage device to the target object storage device. The source object log ensures the consistency and integrity of the data migration; and the migration synchronization of existing data, incremental data, and traffic enables uninterrupted data migration.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data management technology, and in particular to data migration methods, apparatus, devices, storage media, and program products for heterogeneous object storage. Background Technology

[0002] With the development of cloud computing and big data technologies, object storage, as an efficient and reliable storage method, has been widely used in various systems. However, different types of object storage facilities (such as FTP, UDS, ECS, S3, etc.) often have different access interfaces, and they have their own advantages and disadvantages in different scenarios. However, user systems often need to change to different types of storage facilities during their development. When a user system needs to switch storage facilities, such as from UDS to ECS, it often faces problems such as complex data migration and high risks.

[0003] Existing technical solutions suffer from long migration times and disruptions to business continuity.

[0004] The above content is only used to help understand the technical solution of this application and does not represent an admission that the above content is prior art. Summary of the Invention

[0005] The main purpose of this application is to provide a data migration method, apparatus, device, storage medium, and program product for heterogeneous object storage, aiming to solve the technical problems of long migration time and impact on business continuity.

[0006] To achieve the above objectives, this application proposes a data migration method for heterogeneous object storage, the method comprising:

[0007] Migrate existing data before the initial timestamp in the source object storage device to the target object storage device;

[0008] Based on the data operation records in the source object log, the incremental data in the source object storage device is migrated to the target object storage device, and the incremental data in the target object storage device is synchronized to the source object storage device.

[0009] When the incremental data begins to migrate, the current traffic containing the incremental data will be switched and distributed between the source object storage device and the target object storage device.

[0010] Once the current traffic has been switched and distributed, subsequent traffic destined for the source object storage device will be forwarded to the target object storage.

[0011] In one embodiment, the step of migrating existing data prior to the initial timestamp in the source object storage device to the target object storage device further includes:

[0012] Source object logs are created based on operations on the source object storage device, and the source object logs include at least one of the following: source level 1 log, source level 2 log, source level 3 log, and source level 4 log.

[0013] In one embodiment, the step of migrating existing data prior to the initial timestamp in the source object storage device to the target object storage device includes:

[0014] Determine the initial timestamp in the source object storage device;

[0015] Migrate existing data prior to the initial timestamp of the source object storage device to the target object storage device;

[0016] Migrate logs before the initial timestamp recorded in the source second-level log to the source third-level log.

[0017] In one embodiment, the step of migrating incremental data from the source object storage device to the target object storage device based on data operation records in the source object log includes:

[0018] Read log records after the initial timestamp from the source secondary log of the source object's log;

[0019] Determine the data operations for incremental data based on the log records after the initial timestamp in the source secondary log;

[0020] Perform corresponding target operations on the incremental data in the target object storage device based on the data operations on the incremental data.

[0021] In one embodiment, before the step of switching and distributing the current traffic containing the incremental data between the source object storage device and the target object storage device when the incremental data migration begins, the method further includes:

[0022] When the target direction of the current traffic switching and distribution is the target object storage device, the current operation status of the current operation object is determined according to the source object log that records the current operation object;

[0023] Based on the current operation state of the current operation object, determine the switching and distribution direction of the traffic writing for the current operation object.

[0024] In one embodiment, the step of determining the current operation state of the current operation object based on the source object log that records the current operation object includes:

[0025] When the log recording of the current operation object is a source level log, the current operation status of the current operation object is to be written to the source object storage device.

[0026] If the log recording of the current operation object is the source level 2 log, then the current operation status of the current operation object is that it has been pre-synchronized from the source object storage device to the target object storage device;

[0027] If the log recording of the current operation object is a source level 4 log, then the current operation status of the current operation object is "failed to synchronize from the source object storage device to the target object storage device".

[0028] If the source object's log does not record the current operation object's log, then the current operation state of the current operation object is no operation state.

[0029] In one embodiment, the step of determining the switching distribution direction of traffic writing for the current operation object based on the current operation state of the current operation object includes:

[0030] When the current operation state of the current operation object is pre-writing to the source object storage, the switching and distribution direction of the current operation object's traffic writing is the source object storage device;

[0031] When the current operation state of the current operation object is pre-synchronized from the source object storage to the target object storage, the switching and distribution direction of the current operation object's traffic write is the source object storage device;

[0032] When the current operation status of the current operation object is "failed to synchronize from source object storage to target object storage", the switching and distribution direction of the traffic write of the current operation object is the source object storage device;

[0033] When the current operation state of the current operation object is no operation state, the switching and distribution direction of the traffic write of the current operation object is the target object storage device.

[0034] Furthermore, to achieve the above objectives, this application also proposes a data migration apparatus for heterogeneous object storage, the data migration apparatus for heterogeneous object storage comprising:

[0035] The existing data migration module is used to migrate existing data before the initial timestamp in the source object storage device to the target object storage device;

[0036] The incremental migration module is used to migrate incremental data from the source object storage device to the target object storage device based on the data operation records in the source object log, and to synchronize incremental data from the target object storage device to the source object storage device.

[0037] The traffic switching module is used to switch and distribute the current traffic containing the incremental data between the source object storage device and the target object storage device when the incremental data begins to migrate.

[0038] The traffic synchronization module is used to forward subsequent traffic destined for the source object storage device to the target object storage device after the current traffic switching and distribution is completed.

[0039] In addition, to achieve the above objectives, this application also proposes a data migration device for heterogeneous object storage, the device comprising: a memory, a processor, and a computer program stored on the memory and executable on the processor, the computer program being configured to implement the steps of the data migration method for heterogeneous object storage as described above.

[0040] In addition, to achieve the above objectives, this application also proposes a storage medium, which is a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, it implements the steps of the data migration method for heterogeneous object storage as described above.

[0041] In addition, to achieve the above objectives, this application also provides a computer program product, which includes a computer program that, when executed by a processor, implements the steps of the data migration method for heterogeneous object storage as described above.

[0042] One or more technical solutions proposed in this application have at least the following technical effects:

[0043] This application proposes a data migration method, apparatus, device, storage medium, and program product for heterogeneous object storage. It migrates existing data prior to the initial timestamp in the source object storage device to the target object storage device. Based on data operation records in the source object storage log, it migrates incremental data from the source object storage device to the target object storage device and synchronizes incremental data from the target object storage device to the source object storage device. When the incremental data migration begins, the current traffic containing the incremental data is switched and distributed between the source and target object storage devices. After the current traffic switching and distribution is complete, subsequent traffic destined for the source object storage device is forwarded to the target object storage device. The source object log ensures the consistency and integrity of the data migration; by synchronizing existing data, incremental data, and traffic during migration, uninterrupted data migration can be achieved. Attached Figure Description

[0044] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0045] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0046] Figure 1 A flowchart illustrating the data migration method for heterogeneous object storage provided in Embodiment 1 of this application;

[0047] Figure 2 A flowchart illustrating the incremental data migration process in the data migration method for heterogeneous object storage in this application;

[0048] Figure 3 A flowchart of traffic migration is provided for an embodiment of the data migration method for heterogeneous object storage in this application;

[0049] Figure 4 This is a schematic diagram of the module structure of a data migration device for heterogeneous object storage according to an embodiment of this application;

[0050] Figure 5 This is a schematic diagram of the device structure of the hardware operating environment involved in the data migration method for heterogeneous object storage in this embodiment of the application.

[0051] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0052] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.

[0053] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.

[0054] The main solution of this application embodiment is as follows: migrate existing data before the initial timestamp in the source object storage device to the target object storage device; migrate incremental data in the source object storage device to the target object storage device according to the data operation records in the source object log, and synchronize the incremental data in the target object storage device to the source object storage device; when the incremental data migration begins, switch and distribute the current traffic where the incremental data is located between the source object storage device and the target object storage device; after the current traffic switching and distribution is completed, forward the subsequent traffic to the source object storage device to the target object storage device.

[0055] In this embodiment, for ease of description, the following description will focus on identifying heterogeneous object storage devices.

[0056] With the development of cloud computing and big data technologies, object storage, as an efficient and reliable storage method, has been widely used in various systems. However, different types of object storage facilities (such as FTP, UDS, ECS, S3, etc.) often have different access interfaces, and they have their own advantages and disadvantages in different scenarios. User systems often need to change storage facilities during their development. When a user system needs to switch storage facilities, such as from UDS to ECS, it often faces problems such as complex data migration and high risks. Existing technical solutions suffer from long migration times and impact on business continuity.

[0057] This application ensures the consistency and integrity of data migration through source object logs; and enables uninterrupted data migration by synchronizing existing data, incremental data, and traffic data during migration.

[0058] It should be noted that the executing entity in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as a tablet computer, personal computer, or mobile phone, or an electronic device or heterogeneous object storage device capable of performing the above functions. The following description uses a heterogeneous object storage device as an example to illustrate this embodiment and the subsequent embodiments.

[0059] Based on this, embodiments of this application provide a data migration method for heterogeneous object storage, referring to... Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the data migration method for heterogeneous object storage in this application.

[0060] In this embodiment, the data migration method for heterogeneous object storage includes steps S10 to S30:

[0061] Step S10: Migrate the existing data before the initial timestamp in the source object storage device to the target object storage device.

[0062] It should be noted that the source object storage device refers to the data storage device from which the migrated data is stored. The source object storage device can be a local database, a cloud storage service, or any other storage system that supports object storage. An object is a general term for various files; a file, an audio file, a video file, or a photograph can all be considered an object.

[0063] Additionally, it should be noted that the target object storage device refers to the data storage device for the migrated data. The target object storage device can be a local database, a cloud storage service, or other storage systems that support object storage mode.

[0064] Additionally, it should be noted that the existing data refers to the data written to and stored in the source object storage device before the initial timestamp.

[0065] Additionally, it should be noted that the initial timestamp is a specific time point determined before the start of the existing data migration. It is used to define existing data and incremental data; that is, data written and stored in the source object storage device before the initial timestamp is existing data, and data written and stored in the source object storage device after the initial timestamp is incremental data. In one embodiment of this application, the initial timestamp is the timestamp corresponding to the start time of data migration. Data stored in the source object storage device before the start time of data migration is existing data, and data generated by the data source and transmitted to the source object storage device after the start time of data migration is incremental data.

[0066] Specifically, the time point at which the migration of existing data begins is recorded as the initial timestamp. Existing data in the source object storage device is migrated to the target object storage device. After the data migration is completed, all log files corresponding to the existing data in the source secondary log, i.e., logs before the initial timestamp in the source secondary log, are migrated to the source tertiary log.

[0067] Step S20: Based on the data operation records in the source object log, migrate the incremental data in the source object storage device to the target object storage device, and synchronize the incremental data in the target object storage device to the source object storage device.

[0068] It should be noted that the source object log refers to the log recording operations on the source object storage device, including but not limited to read operations, write operations, write requests, and read requests. The source object log includes at least one of the following: source level 1 log, source level 2 log, source level 3 log, and source level 4 log.

[0069] Additionally, it should be noted that the incremental data refers to write operation data distributed from the data source to the source or target object storage device after the initial timestamp. Generally, it refers to write operation data distributed from the data source to the source or target object storage device after the data migration of existing data begins. After the initial timestamp, there may still be data writes, modifications, and deletions on the source or target object storage device. Incremental data migration refers to migrating these newly generated or changed data after the existing data migration begins, to ensure data consistency between the source and target object storage devices.

[0070] Specifically, when incremental data is distributed to the source object storage device, the log records corresponding to timestamps after the initial timestamp in the source secondary log of the source object log are read; the target operation for the incremental data is determined based on the log records corresponding to the next timestamp after the initial timestamp in the source secondary log; and the corresponding target operation is performed on the incremental data in the target object storage device according to the target operation. When incremental data is distributed to the target object storage device, the log records corresponding to timestamps after the initial timestamp in the target secondary log of the target object log are read; the target operation for the incremental data is determined based on the log records corresponding to the next timestamp after the initial timestamp in the target secondary log; and the corresponding target operation is performed on the incremental data in the source object storage device according to the target operation.

[0071] More importantly, after completing the migration of existing and incremental data, a trial read of the target object storage device is performed. The trial read is performed without affecting business applications. When a business application makes a read request to the source object storage device, the read request is copied, and a separate thread is created to simulate the application reading the target object storage device. The source object log will record the status and time of the request in both the source and target object storage devices. The analysis checks whether the read performance of the target object storage device matches that of the source object storage device, thus exposing problems early.

[0072] Step S30: When the incremental data begins to migrate, the current traffic containing the incremental data is switched and distributed between the source object storage device and the target object storage device.

[0073] It should be noted that the data source refers to the data source head that generates the data and writes the data to the source object storage device before the data migration.

[0074] Additionally, it should be noted that the "traffic" mentioned refers to requests; each request constitutes one instance of traffic. For example, uploading, modifying, deleting, or querying a file all count as one instance of traffic. The current traffic related to incremental data refers to all data requests made during the migration process between existing and incremental data.

[0075] Specifically, after the existing data migration and synchronization are completed, when incremental data migration begins, and after a trial read of the data on the target object storage device, the current traffic containing the incremental data is switched and distributed between the source object storage device and the target object storage device. The data source generating the traffic gradually forwards write requests from the data source to the source object storage device to the target object storage device, and the traffic intended for writing to the source object storage device is written to the target object storage device.

[0076] More specifically, during the process of switching and distributing the current traffic containing the incremental data between the source object storage device and the target object storage device, it is necessary to control the switching direction and the traffic distribution ratio.

[0077] In one embodiment of this application, a round-robin strategy is used to control the proportion of traffic distribution. For example, a variable 'a' marks the traffic to the source object storage device, and a variable 'b' marks the traffic to the target object storage device. Both variables are initially set to 0. Assuming the traffic switching step size is 10%, i.e., according to 0%, 10%, 20% up to 100%, if the goal is to achieve 80% traffic in the source object storage and the remaining 20% ​​traffic to the target object storage, the process is as follows:

[0078] When the first request arrives, mark a = a + 1 = 0 + 1 = 1, and distribute the traffic to the source object storage device;

[0079] When the second request arrives, mark a = a + 1 = 1 + 1 = 2, and distribute the traffic to the source object storage device;

[0080] When the third request arrives, mark a = a + 1 = 2 + 1 = 3, and distribute the traffic to the source object storage device;

[0081] When the 4th request arrives, mark a = a + 1 = 3 + 1 = 4, and distribute the traffic to the source object storage device;

[0082] When the 5th request arrives, mark a = a + 1 = 4 + 1 = 5, and distribute the traffic to the source object storage device;

[0083] When the 6th request arrives, mark a = a + 1 = 5 + 1 = 6, and distribute the traffic to the source object storage device;

[0084] When the 7th request arrives, mark a = a + 1 = 6 + 1 = 7, and distribute the traffic to the source object storage device;

[0085] When the 8th request arrives, mark a = a + 1 = 7 + 1 = 8, and distribute the traffic to the source object storage device;

[0086] When the 9th request arrives, it is found that a is already equal to 8, which means that 8 traffic has been distributed to the source object storage device. At this time, the traffic should be distributed to the target object storage device, so b = b + 1 = 0 + 1 = 1 is marked. In order to continue the process, a must be reset to 0.

[0087] When the 10th request arrives, mark b = b + 1 = 1 + 1 = 2, and distribute the traffic to the target object storage device;

[0088] When the 11th request arrives, it is found that b is already equal to 2, which means that two traffic streams have already been distributed to the target object storage device. At this time, the traffic should be distributed to the source object storage device, so a = a + 1 = 0 + 1 = 1. In order to continue the process, b must be reset to 0.

[0089] Step S40: After the current traffic switching and distribution is completed, the subsequent traffic destined for the source object storage device is forwarded to the target object storage.

[0090] It should be noted that subsequent traffic to the source object storage device refers to the traffic that is transmitted after the current traffic containing incremental data has been transmitted.

[0091] Specifically, once the current traffic switching and distribution is complete, and the traffic from the data source can be stably transmitted 100% to the target object storage device, the traffic forwarding direction of the data source is stably set to the target object storage device.

[0092] This embodiment uses the above-described scheme to ensure the consistency and integrity of data migration through source object logs; and enables uninterrupted data migration by synchronizing existing data, incremental data, and traffic data during migration.

[0093] Based on the above implementation scheme, in one feasible implementation, before migrating the existing data before the initial timestamp in the source object storage device to the target object storage device, the method further includes step S70:

[0094] Step S70: Create a source object log based on the operation on the source object storage device. The source object log includes at least one of the following: source level 1 log, source level 2 log, source level 3 log, and source level 4 log.

[0095] It should be noted that the source object log refers to the log recording operations on the source object storage device, including but not limited to read operations, write operations, write requests, and read requests. The source object log includes at least one of the following: source level 1 log, source level 2 log, source level 3 log, and source level 4 log. Furthermore, the source object log also includes source exception write logs and source exception read logs. The source exception write log records instances where a write request from the data source to the source object storage device fails; the source exception read log records instances where a read request from the data source to the source object storage device fails.

[0096] Additionally, it should be noted that the source-level log is used to record write requests (additions, deletions, modifications) to the source object storage device that have not been completed. The log includes the object data ID, the object data's metadata, and the start time of the write request.

[0097] Additionally, it should be noted that the source level 2 log is used to record the request information when data is successfully written to the source object storage device but the write operation has not yet been synchronized to the target object. Once the write operation is synchronized to the target object storage device, the corresponding log will be transferred to the source level 3 log.

[0098] Additionally, it should be noted that the source level 3 log is used to record all write operations to the source object storage device. If the object data is inconsistent with the target object storage device, the log can be used to trace back, thereby investigating the cause of the inconsistency and fixing the problem.

[0099] Additionally, it should be noted that the source level 4 log is used to record exception logs when data synchronization from the source object storage device to the target object storage device fails.

[0100] Specifically, source object logs are created based on operations on the source object storage device. These source object logs include at least one of the following: source level 1 logs, source level 2 logs, source level 3 logs, and source level 4 logs. Furthermore, the source object logs also include source exception write logs and source exception read logs. The source exception write logs record when a write request from the data source to the source object storage device fails; the source exception read logs record when a read request from the application to the source object storage device fails.

[0101] More specifically, relative to the source object log, a target object log is created based on operations on the target object storage device, and this target object log includes at least one of the following: target level 1 log, target level 2 log, target level 3 log, and target level 4 log. Furthermore, the target object log also includes target exception write logs and target exception read logs.

[0102] More specifically, the content of the target object log corresponds to that of the source object log. The target object log records operations performed on the target object storage device, including but not limited to read operations, write operations, write requests, and read requests. The target level 1 log records write requests to the target object storage device (add, delete, modify) that have not yet been completed. It includes the object data ID, object data metadata, and the start time of the write request. The target level 2 log records successful writes to the target object storage device, but requests to synchronize the write operation to the source object have not yet been completed. Once the write operation is synchronized to the source object storage device, the corresponding log will be moved to the target level 3 log. The target level 3 log records all write operations to the target object storage device. If inconsistencies arise between the object data and the source object storage device, this log can be used for backtracking. The target level 4 log records exceptions where data synchronization from the target object storage device to the source object storage device fails. The target exception write log is used to record logs when an exception occurs when writing to the target object storage device; the target exception read log is used to record logs when an application makes an exception when reading from the target object storage device.

[0103] This embodiment, through the above-described scheme, creates source object logs, which include at least one of the following: source level 1 log, source level 2 log, source level 3 log, and source level 4 log. By creating multi-level source object logs, and with different logs recording corresponding log entries, the consistency and integrity of the migrated data can be guaranteed.

[0104] Based on the above implementation scheme, in one feasible implementation, the migration of existing data before the initial timestamp in the source object storage device to the target object storage device includes steps S11 to S13:

[0105] Step S11: Determine the initial timestamp in the source object storage device.

[0106] Specifically, the timestamp at the start of the migration of existing data is recorded as the initial timestamp, and the data stored in the source object storage device before the initial timestamp is the existing data.

[0107] Step S12: Migrate the existing data before the initial timestamp of the source object storage device to the target object storage device.

[0108] Specifically, after determining the initial timestamp, the size of the existing data and the resources required for data migration (such as network bandwidth, storage space, computing resources, etc.) are determined; the data migration tool is determined, which can perform data reading, data transmission, data writing, and data verification; the existing data is migrated from the source object storage device to the target object storage device using the data migration tool. During the transmission process, compression, encryption, and other measures can be taken to improve the efficiency and security of the transmission. The progress and status of the transmission are monitored during the transmission process to ensure that there are no interruptions or errors in the data transmission.

[0109] The transferred data is written to the target object storage device. This process may involve data format conversion and index updates. After writing, the data on the target object storage device is verified to ensure its integrity, consistency, and accuracy. This can be achieved by comparing the source and target data and checking the checksums of the data files. Once the data migration is complete, metadata and index information are updated on the target object storage device to ensure the migrated data can be correctly retrieved and accessed. If an anomaly occurs during the migration synchronization process, the migration process is stopped, and the specific cause of the anomaly is analyzed.

[0110] Step S13: Migrate the logs recorded in the source second-level log before the initial timestamp to the source third-level log.

[0111] Specifically, after the existing data is fully synchronized and migrated to the target object storage device, all logs in the source object log before the initial timestamp in the source second-level log, that is, the logs corresponding to the existing data, are migrated to the source third-level log.

[0112] Based on the above implementation scheme, in one feasible implementation, the step of migrating incremental data from the source object storage device to the target object storage device according to the data operation records in the source object log includes steps S21 to S23:

[0113] Step S21: Read the log records after the initial timestamp in the source secondary log of the source object log.

[0114] Specifically, existing data prior to the initial timestamp has been migrated from the source object storage device to the target object storage device. After the migration of existing data begins, new data is written or modified. The source secondary log is used to record requests for successful writes to the source object storage device, but for which the write operation has not yet been synchronized to the target object. The log records after the initial timestamp in the source secondary log of the source object log are read; these are the log records for incremental data. These log records include, but are not limited to, timestamps (the time of sending), operation type (indicating the type of operation, such as add, modify, or delete), and operation object (the identifier ID of the data object being operated on).

[0115] Step S22: Determine the data operation for incremental data based on the log records after the initial timestamp in the source secondary log.

[0116] It should be noted that data operations on incremental data include, but are not limited to, data modification, addition, and deletion.

[0117] Specifically, based on the operation type recorded in the log, the data operations on the incremental data in the source object storage device are determined. These data operations may include modification, addition, deletion, etc.

[0118] Step S23: Perform corresponding target operations on the incremental data in the target object storage device based on the data operations of the incremental data.

[0119] Specifically, when the incremental data operation is a delete operation, the incremental data and corresponding data operation are determined based on the incremental data's data identifier ID, and the incremental data in the target object storage device is deleted. When the incremental data operation is a modify / add operation, the incremental data in the target object storage device is stored. When the target operation is successfully completed, the corresponding log record of the incremental data in the source second-level log is transferred to the source third-level log. If the target operation synchronization fails, the target operation is retried several times. If it still fails after several attempts, the log is transferred from the source second-level log to the source fourth-level log. The number of attempts can be one, two, three, etc., and can be set by the user.

[0120] Please refer to [link / reference] for easier understanding. Figure 2 , Figure 2 The flowchart for incremental data migration first reads the log records after the initial timestamp in the source secondary log to determine the data operation type of the incremental data. If the data operation is deletion, the incremental data is deleted from the target object storage device. If the data operation type is addition or modification, the incremental data after the operation is synchronously stored in the target object storage device. If the operation is successful, the record in the source secondary log is transferred to the source tertiary log. If it fails, the record in the source secondary log is transferred to the source quaternary log.

[0121] The steps for migrating incremental data from the source object storage device to the target object storage device based on data operation records in the source object log can synchronize write operations in the source object storage device to the target object storage device. More importantly, it's also necessary to synchronize write operations on the incremental data in the target object storage device to the source object storage device. The specific steps are: reading log records after the initial timestamp in the target secondary log of the target object log; determining the data operations on the incremental data based on the log records after the initial timestamp in the target secondary log; and performing corresponding target operations on the incremental data in the source object storage device based on the data operations on the incremental data. By synchronizing the write operations on the incremental data in both the source and target object storage devices, the integrity of the data in both devices can be guaranteed, and traffic can be switched back at any time in case of anomalies.

[0122] This embodiment, through the above-described scheme, determines the data operations of incremental data based on log records, and then performs corresponding target operations on the incremental data synchronized to the target object storage device based on the data operations. This allows for corresponding update operations on the incremental data, ensuring data integrity and consistency, which is a key aspect of achieving uninterrupted migration.

[0123] Based on the above implementation scheme, in one feasible implementation, before forwarding the traffic write request instruction from the data source to the source object storage device to the target object storage device, and before writing the traffic to the source object storage device to the target object storage device, the method further includes steps S50 to S60:

[0124] Step S50: When the target direction of the current traffic switching and distribution is the target object storage device, the current operation status of the current operation object is determined according to the source object log of the current operation object.

[0125] It should be noted that the "current operation object" refers to the object to be operated on by the current request instruction. During the data migration process of heterogeneous object storage, after the existing data migration and synchronization are completed, during the traffic switching process, there may be situations where both the source and target object storage devices simultaneously perform read and write operations on the same object. Without proper control, this can easily lead to dirty reads or dirty writes. The "current operation object" is the object that both the source and target object storage devices are simultaneously reading and writing. Therefore, to solve the dirty read or dirty write problem, if the traffic read / write request instruction is forwarded to the target object storage device at the beginning of the traffic switching, before the target object storage executes the instruction, it is necessary to check whether there are any instructions in the source object storage that operate on the same object and have not yet been synchronized to the target object storage. If so, the current read / write instruction is forwarded to the source object storage for execution.

[0126] Dirty writes are a problem that easily occurs during data transmission, leading to data inconsistency. For example, consider a current object Q whose stored data is consistent in both the source and target object storage. If a write request A arrives at the source object storage to modify Q, changing the object type of Q's metadata to PDF, and then a write request B arrives at the target object storage, changing the object type of Q's metadata to Word, without proper control, after bidirectional data synchronization, the final type of Q might be PDF. However, since write request B arrived later than write request A, the final type of Q should actually be Word.

[0127] It should be noted that when the target direction of the current traffic switching and distribution is the target object storage device, the current operation status refers to the current state of the current operation object. The current operation status of the current operation object recorded in the source object log includes pre-writing to the source object storage device, pre-synchronization from the source object storage device to the target object storage device, failure to synchronize from the source object storage device to the target object storage device, and newly generated pre-writing.

[0128] Specifically, when the target direction of the current traffic switching and distribution is the target object storage device, if the log recording the current operation object is a source level 1 log, then the current operation status of the current operation object is pre-writing to the source object storage device; if the log recording the current operation object is a source level 2 log, then the current operation status of the current operation object is pre-synchronization from the source object storage device to the target object storage device; if the log recording the current operation object is a source level 4 log, then the current operation status of the current operation object is failure to synchronize from the source object storage device to the target object storage device; when there is no log recording for the current operation object in the source log module, then the current operation status of the current operation object is newly generated pre-writing.

[0129] Step S60: Determine the switching and distribution direction of traffic writing for the current operation object based on the current operation state of the current operation object.

[0130] Specifically, for a better understanding, please refer to Figure 3 , Figure 3 This is a flowchart of traffic migration. When the target direction of the current traffic switching and distribution is the target object storage device, and the current operation status of the current operation object is pre-writing to the source object storage, the forwarding direction of the data write request instruction of the current operation object is the source object storage device; when the current operation status of the current operation object is pre-synchronization from the source object storage to the target object storage, the forwarding direction of the data write request instruction of the current operation object is the source object storage device; when the current operation status of the current operation object is failure to synchronize from the source object storage to the target object storage, the forwarding direction of the data write request instruction of the current operation object is the source object storage device; when the current operation status of the current operation object is newly generated pre-writing, the forwarding direction of the data write request instruction of the current operation object is the target object storage device.

[0131] Furthermore, when the target direction of the current traffic switching and distribution is the source object storage device, if the log recording the current operation object is a target level 1 log, then the current operation status of the current operation object is pre-writing to the target object storage device, and the switching and distribution direction of the current operation object traffic writing is the target object storage device; if the log recording the current operation object is a target level 2 log, then the current operation status of the current operation object is pre-synchronization from the target object storage device to the source object storage device, and the switching and distribution direction of the current operation object traffic writing is the target object storage device; if the log recording the current operation object is a target level 4 log, then the current operation status of the current operation object is failed synchronization from the target object storage device to the source object storage device, and the switching and distribution direction of the current operation object traffic writing is the target object storage device; if the target object log does not record the current operation object's log, then the current operation status of the current operation object is no operation, and the switching and distribution direction of the current operation object traffic writing is the source object storage device.

[0132] This embodiment, through the above-described scheme, determines the current operation status of the current operation object based on the log recording the current operation object; and determines the forwarding direction of the data write request instruction of the current operation object based on the current operation status, thereby avoiding dirty writes and ensuring the consistency and integrity of the migrated data.

[0133] Based on the above implementation scheme, in one feasible implementation, the step of determining the current operation state of the current operation object according to the source object log recording the current operation object includes S51 to S54:

[0134] Step S51: When the log of the current operation object is recorded as the source level log, the current operation status of the current operation object is to be pre-written to the source object storage device.

[0135] Specifically, when the log recording the current operation object is the source level log, the source level log is used to record the request to write data to the source object storage device, indicating that the data of the current operation object may not have been actually written to the source object storage device yet. Therefore, the current operation status of the current operation object is pre-written to the source object storage device.

[0136] Step S52: When the log recording of the current operation object is the source level 2 log, the current operation status of the current operation object is pre-synchronized from the source object storage device to the target object storage device.

[0137] Specifically, when the log recording the current operation object is the source level 2 log, the source level 2 log is used to record the request information that the data writing operation to the source object storage device was successful, but the data writing operation of the object has not yet been synchronized to the target object. This indicates that the data of the current operation object has been actually written to the source object storage device, but has not yet been migrated to the target object storage device. Therefore, the current operation status of the current operation object is pre-synchronized from the source object storage device to the target object storage device.

[0138] Step S53: If the log of the current operation object is recorded as a source level 4 log, then the current operation status of the current operation object is "failed to synchronize from the source object storage device to the target object storage device".

[0139] Specifically, when the log recording the current operation object is a source level 4 log, the source level 4 log is used to record the exception log when the incremental data synchronization from the source object storage device to the target object storage fails, indicating that the data synchronization from the source object storage device to the target object storage device has failed.

[0140] Step S54: If the source object log does not record the current operation object's log, then the current operation state of the current operation object is no operation state.

[0141] Specifically, if the source object log does not record the log of the currently operated object, then it can be assumed that the state of the currently operated object is consistent between the source object storage device and the target object storage device, and there are no known conflicts or synchronization issues.

[0142] Based on the above implementation scheme, in one feasible implementation, determining the switching and distribution direction of traffic writing for the current operation object according to the current operation state of the current operation object includes steps S61 to S64:

[0143] Step S61: When the current operation state of the current operation object is pre-writing to the source object storage, the switching distribution direction of the current operation object traffic writing is the source object storage device.

[0144] Specifically, the log recording the current operation object is the source-level log. The source-level log records requests to write data to the source object storage device, indicating that the data for the current operation object may not have been actually written yet. Therefore, the current operation state of the current operation object is "pre-writing to the source object storage device." If write requests were allowed to directly reach the target object storage device at this time, and this write request conflicts with the request being processed for the current operation object in the source object storage device (recorded in the source-level log), it could lead to data inconsistency. Therefore, data write requests are forwarded to the source object storage device to ensure that all write operations are executed in the source object storage device in the order they are received. This maintains the consistency of data in the source object storage device, and when the data is synchronized to the target object storage device, it ensures that the data in the target object storage device is consistent with the data in the source object storage device.

[0145] Step S62: When the current operation status of the current operation object is pre-synchronized from the source object storage to the target object storage, the switching and distribution direction of the current operation object traffic write is the source object storage device.

[0146] Specifically, when the log recording the current operation object is the source secondary log, which records requests for successful writes to the source object storage device but not yet synchronized to the target object, it indicates that the current operation object's status is pre-synchronization from the source object storage to the target object storage. If a new write request is allowed to directly reach the target object storage device at this time, and this new write request conflicts with the most recently completed write operation in the source object storage (recorded in the source secondary log), it could lead to data inconsistency. Therefore, the new write request is forwarded to the source object storage device to ensure that all write operations are executed in the order they were processed in the source object storage device. This maintains data consistency in the source object storage device and ensures that the data in the target object storage device remains consistent with the data in the source object storage device when the data is synchronized to the target object storage device.

[0147] Step S63: When the current operation status of the current operation object is that the synchronization from the source object storage to the target object storage has failed, the switching distribution direction of the traffic write of the current operation object is the source object storage device.

[0148] Specifically, when the log recording the current operation object is a source level 4 log, which records exceptions where incremental data synchronization from the source object storage device to the target object storage device fails, indicating a failure in data synchronization from the source object storage device to the target object storage device, allowing new data write requests to directly reach the target object storage device without considering the failure records in the source level 4 log could lead to data inconsistency between the source and target object storage devices. Therefore, data write requests are forwarded to the source object storage device to ensure that all write operations are executed first in the source object storage device, and these changes are only replicated to the target object storage device after successful synchronization. This ensures that the consistency and integrity of data in the source and target object storage devices are maintained even in the event of synchronization failure.

[0149] Step S64: When the current operation state of the current operation object is no operation state, the switching distribution direction of the current operation object traffic write is the target object storage device.

[0150] Specifically, if the source object log does not record the current operation object's log, then it can be assumed that the state of the current operation object is consistent between the source object storage device and the target object storage device, and there are no known conflicts or synchronization issues. The data write request instruction is forwarded to the target object storage device, and the request is recorded in the target's first-level log. If the write operation is successful, the log of the write operation is moved to the target's second-level log; if the write operation fails, the log of the write operation is moved to the target's exception write log.

[0151] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the data migration method for heterogeneous object storage in this application. Any simple transformations based on this technical concept are within the protection scope of this application.

[0152] This application also provides a data migration device for heterogeneous object storage; please refer to... Figure 3 The data migration device for the heterogeneous object storage includes:

[0153] The existing data migration module 401 is used to migrate existing data before the initial timestamp in the source object storage device to the target object storage device.

[0154] The incremental migration module 402 is used to migrate incremental data from the source object storage device to the target object storage device according to the data operation records in the source object log, and to synchronize incremental data from the target object storage device to the source object storage device.

[0155] The traffic switching module 403 is used to switch and distribute the current traffic where the incremental data is located between the source object storage device and the target object storage device when the incremental data begins to migrate.

[0156] The traffic synchronization module 404 is used to forward subsequent traffic destined for the source object storage device to the target object storage device after the current traffic switching and distribution is completed.

[0157] The heterogeneous object storage data migration apparatus provided in this application, employing the heterogeneous object storage data migration method in the above embodiments, can solve the technical problems of long migration time and impact on business continuity. Compared with the prior art, the beneficial effects of the heterogeneous object storage data migration apparatus provided in this application are the same as those of the heterogeneous object storage data migration method provided in the above embodiments, and other technical features in the heterogeneous object storage data migration apparatus are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.

[0158] This application provides a data migration device for heterogeneous object storage, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, which are executed by the at least one processor to enable the at least one processor to perform the data migration method for heterogeneous object storage in the first embodiment described above.

[0159] The following is for reference. Figure 5 This document illustrates a structural schematic diagram of a data migration device suitable for implementing heterogeneous object storage in the embodiments of this application. The data migration device for heterogeneous object storage in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Description), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 5 The data migration device for heterogeneous object storage shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.

[0160] like Figure 5As shown, the data migration device for heterogeneous object storage may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.) that can perform various appropriate actions and processes based on a program stored in read-only memory (ROM) 1002 or a program loaded from storage device 1003 into random access memory (RAM) 1004. The RAM 1004 also stores various programs and data required for the operation of the data migration device for heterogeneous object storage. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the heterogeneous object storage data migration device to wirelessly or wiredly communicate with other devices to exchange data. Although a heterogeneous object storage data migration device with various systems is shown in the figure, it should be understood that it is not required to implement or possess all the systems shown. More or fewer systems can be implemented alternatively.

[0161] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.

[0162] The heterogeneous object storage data migration device provided in this application, employing the heterogeneous object storage data migration method in the above embodiments, can solve the technical problems of long migration time and impact on business continuity. Compared with the prior art, the beneficial effects of the heterogeneous object storage data migration device provided in this application are the same as those of the heterogeneous object storage data migration method provided in the above embodiments, and other technical features in this heterogeneous object storage data migration device are the same as those disclosed in the previous embodiment method, and will not be repeated here.

[0163] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.

[0164] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

[0165] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, the computer-readable program instructions being used to execute the data migration method for heterogeneous object storage in the above embodiments.

[0166] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.

[0167] The aforementioned computer-readable storage medium may be included in a data migration device for heterogeneous object storage; or it may exist independently and not be assembled into a data migration device for heterogeneous object storage.

[0168] The aforementioned computer-readable storage medium carries one or more programs. When these programs are executed by a data migration device for heterogeneous object storage, the data migration device for heterogeneous object storage causes the following: it migrates existing data prior to the initial timestamp in the source object storage device to the target object storage device; based on data operation records in the source object log, it migrates incremental data in the source object storage device to the target object storage device, and synchronizes incremental data in the target object storage device to the source object storage device; when the incremental data migration begins, it switches and distributes the current traffic containing the incremental data between the source and target object storage devices; and after the current traffic switching and distribution is complete, it forwards subsequent traffic destined for the source object storage device to the target object storage device.

[0169] Computer program code for performing the operations of this application can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, and conventional procedural programming languages ​​such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0170] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0171] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.

[0172] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the above-described data migration method for heterogeneous object storage. This solves the technical problems of long migration times and impact on business continuity. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the data migration method for heterogeneous object storage provided in the above embodiments, and will not be elaborated upon here.

[0173] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the data migration method for heterogeneous object storage as described above.

[0174] The computer program product provided in this application can solve the technical problems of long migration time and impact on business continuity. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as those of the data migration method for heterogeneous object storage provided in the above embodiments, and will not be repeated here.

[0175] The above description is only a part of the embodiments of this application and does not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.

Claims

1. A data migration method for heterogeneous object storage, characterized in that, The method includes: Migrate existing data prior to the initial timestamp in the source object storage device to the target object storage device. The initial timestamp is used to distinguish between existing data and incremental data. The existing data refers to the data written to the source object storage device before the initial timestamp. Based on the data operation records in the source object log, the incremental data in the source object storage device is migrated to the target object storage device, and the incremental data in the target object storage device is synchronized to the source object storage device. Here, the source object log refers to the log that records the operation of the source object storage device, and the incremental data refers to the data written to the source object storage device after the initial timestamp. When the incremental data migration begins, the current traffic containing the incremental data is switched and distributed between the source object storage device and the target object storage device. The current traffic refers to the data requests during the migration process of the existing data and the incremental data. Once the current traffic has been switched and distributed, subsequent traffic destined for the source object storage device will be forwarded to the target object storage. The step of migrating existing data before the initial timestamp in the source object storage device to the target object storage device also includes: Source object logs are created based on operations on source object storage devices, and the source object logs include at least one of the following: source level 1 logs, source level 2 logs, source level 3 logs, and source level 4 logs. The step of switching and distributing the current traffic containing the incremental data between the source object storage device and the target object storage device when the incremental data begins to migrate further includes: When the target direction of the current traffic switching and distribution is the target object storage device, the current operation status of the current operation object is determined according to the source object log that records the current operation object; Based on the current operation state of the current operation object, determine the switching and distribution direction of the traffic writing for the current operation object; The step of determining the current operation state of the current operation object based on the source object log of the current operation object includes: When the log recording of the current operation object is a source level log, the current operation status of the current operation object is to be written to the source object storage device. If the log recording of the current operation object is the source level 2 log, then the current operation status of the current operation object is that it has been pre-synchronized from the source object storage device to the target object storage device; If the log recording of the current operation object is a source level 4 log, then the current operation status of the current operation object is "failed to synchronize from the source object storage device to the target object storage device". If the source object's log does not record the current operation object's log, then the current operation state of the current operation object is no operation state.

2. The method as described in claim 1, characterized in that, The step of migrating existing data before the initial timestamp in the source object storage device to the target object storage device includes: Determine the initial timestamp in the source object storage device; Migrate existing data prior to the initial timestamp of the source object storage device to the target object storage device; Migrate logs before the initial timestamp recorded in the source second-level log to the source third-level log.

3. The method as described in claim 1, characterized in that, The step of migrating incremental data from the source object storage device to the target object storage device based on data operation records in the source object log includes: Read log records after the initial timestamp from the source secondary log of the source object's log; Determine the data operations for incremental data based on the log records after the initial timestamp in the source secondary log; Perform corresponding target operations on the incremental data in the target object storage device based on the data operations on the incremental data.

4. The method as described in claim 1, characterized in that, The step of determining the switching and distribution direction of traffic writing for the current operation object based on the current operation state of the current operation object includes: When the current operation state of the current operation object is pre-writing to the source object storage, the switching and distribution direction of the current operation object's traffic writing is the source object storage device; When the current operation state of the current operation object is pre-synchronized from the source object storage to the target object storage, the switching and distribution direction of the current operation object's traffic write is the source object storage device; When the current operation status of the current operation object is "failed to synchronize from source object storage to target object storage", the switching and distribution direction of the traffic write of the current operation object is the source object storage device; When the current operation state of the current operation object is no operation state, the switching and distribution direction of the traffic write of the current operation object is the target object storage device.

5. A data migration device for heterogeneous object storage, characterized in that, The device includes: The existing data migration module is used to migrate existing data before the initial timestamp in the source object storage device to the target object storage device. The initial timestamp is used to distinguish between existing data and incremental data. The existing data refers to the data written to the source object storage device before the initial timestamp. The incremental migration module is used to migrate incremental data from the source object storage device to the target object storage device and synchronize incremental data from the target object storage device to the source object storage device based on the data operation records in the source object log. The source object log refers to the log that records the operation of the source object storage device, and the incremental data refers to the data written to the source object storage device after the initial timestamp. The traffic switching module is used to switch and distribute the current traffic where the incremental data is located between the source object storage device and the target object storage device when the incremental data migration begins. The current traffic refers to the data request during the migration process of the existing data and the incremental data. The traffic synchronization module is used to forward subsequent traffic destined for the source object storage device to the target object storage device after the current traffic switching and distribution is completed. The device further includes a log creation module for creating source object logs based on operations on the source object storage device. The source object logs include at least one of the following: source level 1 logs, source level 2 logs, source level 3 logs, and source level 4 logs. The device further includes a direction determination module, which is used to determine the current operation status of the current operation object based on the source object log of the current operation object when the target direction of the current traffic switching and distribution is the target object storage device. Based on the current operation state of the current operation object, determine the switching and distribution direction of the traffic writing for the current operation object; The direction determination module is further configured to, when the log recording the current operation object is a source level log, pre-write the current operation state of the current operation object to the source object storage device. If the log recording of the current operation object is the source level 2 log, then the current operation status of the current operation object is that it has been pre-synchronized from the source object storage device to the target object storage device; If the log recording of the current operation object is a source level 4 log, then the current operation status of the current operation object is "failed to synchronize from the source object storage device to the target object storage device". If the source object's log does not record the current operation object's log, then the current operation state of the current operation object is no operation state.

6. A data migration device for heterogeneous object storage, characterized in that, The device includes: a memory, a processor, and a computer program stored on the memory and executable on the processor, the computer program being configured to implement the steps of the data migration method for heterogeneous object storage as described in any one of claims 1 to 4.

7. A storage medium, characterized in that, The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, it implements the steps of the data migration method for heterogeneous object storage as described in any one of claims 1 to 4.

8. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, implements the steps of the data migration method for heterogeneous object storage as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Database migration method and system

    CN105868343A

  • Database migration method, system and equipment and storage medium

    CN117609188A