Dynamic data protection system and method for distributed storage
Through data view synchronization and migration between the storage engine cluster management module and the client, the protection mode of distributed storage is dynamically switched, which solves the seamless problem of switching from 3 copies to EC protection mode in the existing technology and improves capacity expansion. The final cluster reliability and performance.
Patent Information
- Application Number
- PCT/CN2023/143144
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-12-12
- Filing Date
- 2023-12-29
- Publication Date
- 2024-10-31
AI Technical Summary
When existing distributed storage technology switches from 3-copy protection mode to EC protection mode, it is difficult to switch seamlessly, resulting in business cutover risks and resource waste, and the reliability of the three copies after expansion is insufficient.
Publish the data view through the storage engine cluster management module, determine the protection mode and read and write methods, and synchronize between the storage engine client and the stand-alone engine module to realize the migration and view switching of data views, dynamically switch the protection mode, and avoid business cutover .
It realizes business-insensitive protection mode switching, reduces cutover risks and resource waste, and improves cluster reliability and performance after capacity expansion.
Smart Images

Figure CN2023143144_31102024_PF_FP_ABST
Abstract
Description
A distributed storage dynamic data protection system and method Technical Field
[0001] The present invention belongs to the technical field of computer storage, and in particular relates to a distributed storage dynamic data protection system and method. Background Art
[0002] Distributed storage is also known as software-defined storage in the storage industry. The Storage Networking Industry Association defines software-defined storage (SDS) as virtualized storage with a service management interface. SDS includes storage pooling capabilities and uses the service management interface to define the data service characteristics of the storage pool. SNIA also proposes that software-defined storage (SDS) should have the following characteristics:
[0003] A high degree of automation reduces the operational overhead of storage infrastructure by simplifying management; standard interfaces support API management, publishing, and operation of storage devices and services; virtualized data paths support multiple standard protocols, allowing applications to write data through block storage, file storage, or object storage interfaces; scalability means the storage architecture has the ability to seamlessly expand in scale without affecting availability or causing performance degradation during the expansion process; transparency means storage should provide users with the ability to manage and monitor available storage resources and overhead.
[0004] The most important aspect of virtualized storage is the virtualization of storage hardware. Compared to traditional storage, distributed storage no longer relies on proprietary hardware (such as storage controllers) or proprietary networks (such as Fibre Channel). Instead, it can provide specialized storage services using general-purpose hardware and networks.
[0005] Distributed storage technology is now widely used in traditional data centers, public and private cloud data centers, and hyperconverged workstations, and its importance is growing. The distributed storage engine, a core component of distributed storage, provides high-performance, high-reliability, and efficient data access. Distributed block, file, object, and database services are all built on top of the distributed storage engine.
[0006] The storage engines used in currently well-known distributed storage products do not support switching from a three-replica protection mode to an EC (erasure coding) protection mode, or from a small-ratio, non-folded EC to a large-ratio EC protection mode. Consequently, if a three-replica solution is adopted when a distributed storage cluster is first built, subsequent business changes (such as an increase in high-bandwidth business, where a large-ratio EC performs better) or cluster expansion (for large clusters with hundreds or thousands of nodes, where three-replica reliability is clearly insufficient) will require significant manpower, time, and resources to cut over, which can also pose significant risks.
[0007] Summary of the Invention
[0008] The purpose of the present invention is to provide a distributed storage dynamic data protection system that can switch without service perception and avoid cutover due to this situation, so as to solve the problems raised in the above background technology.
[0009] To achieve the above-mentioned objectives, the present invention adopts the following technical solutions: a distributed storage dynamic data protection system, comprising a storage engine client, a storage stand-alone engine module, and a storage engine cluster management module, wherein: the storage engine cluster management module is used to publish a data view, determine the protection mode and read / write mode of the data view, and diffuse the data view to the storage engine client and the storage stand-alone engine module; the storage engine client accesses the data view in the storage engine cluster management module through the protection mode, and synchronizes the data view to the storage stand-alone engine module; the storage engine client writes the data view through the read / write mode, and migrates the migratable data view through the protection mode; the storage engine cluster management module performs view switching on the migrated data view, and diffuses it to the storage engine client and the storage stand-alone engine module.
[0010] Preferably, the storage stand-alone engine module is used to provide local data persistence and persistent data access for the storage engine client.
[0011] Preferably, the read-write mode is used to divide the data view into read-only data and read-write data.
[0012] Preferably, the migrated data in the data view is read-only data; and the non-migrated data in the data view is readable and writable data.
[0013] Preferably, the protection mode is used to authoritatively shard the data view.
[0014] Preferably, the authoritative shard includes an authoritative node disk and a non-authoritative set.
[0015] Preferably, the view switching includes: selecting the data view to be switched and switching the protection mode; selecting the nodes that intersect with the authoritative node disk in the switched data view to construct a non-authoritative set; publishing the non-authoritative set as the first new view; starting the migration command, marking the authoritative shards participating in the migration in the first new view as read-only, reading the data of the authoritative shards, and writing them to the non-authoritative set in an EC manner; performing a consistency check on the first new view after migration and then forming a new authoritative shard set; re-transforming the data view to writable data, publishing a second new view, and diffusing the second new view to the cluster through the cluster view diffusion solution.
[0016] Preferably, the data view is generated by the storage engine cluster management module.
[0017] Preferably, the first new view is read-only during migration, and no new data is written during the migration process.
[0018] Preferably, the cluster includes: the storage engine cluster management module deploys the storage stand-alone engine on a general server through a paxos or raft protocol.
[0019] In another aspect, the present invention provides a distributed storage dynamic data protection method, comprising:
[0020] Publish data views, determine their protection mode and read / write methods, and propagate them to storage engine clients and standalone storage engine modules.
[0021] Access the data view in the storage engine cluster management module in protection mode and synchronize the data view to the storage standalone engine module;
[0022] Write data views in read-write mode and migrate migratable data views in protected mode;
[0023] Switch the migrated data view and spread it to the storage engine client and storage stand-alone engine module
[0024] Technical effects and advantages of the present invention: Compared with the existing technology, the distributed storage dynamic data protection system proposed by the present invention has the following advantages:
[0025] The storage engine cluster management module of the present invention is used to publish data views, determine the protection mode and read-write mode of the data views, and diffuse the data views to the storage engine client and the storage stand-alone engine module. The storage engine client accesses the data views in the storage engine cluster management module through the protection mode and synchronizes the data views to the storage stand-alone engine module. The storage engine client writes the data views through the read-write mode and migrates the migratable data views through the protection mode. The storage engine cluster management module switches the views of the migrated data views and diffuses them to the storage engine client and the storage stand-alone engine module. The switching can be performed without business perception, avoiding cutover due to this situation. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] FIG1 is a schematic diagram of a distributed storage dynamic data protection system according to the present invention;
[0027] FIG2 is a schematic diagram of the initial stage of copy protection switching EC of the present invention;
[0028] FIG3 is a schematic diagram of the final stage of copy protection switching EC according to the present invention;
[0029] FIG4 is a schematic diagram of switching from a small-scale EC to a large-scale EC according to the present invention. DETAILED DESCRIPTION
[0030] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the embodiments described are only part of the embodiments of the present invention, not all of the embodiments. The specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0031] A storage engine generally consists of three components: the storage engine client, the standalone storage engine module, and the storage engine cluster management module.
[0032] Storage engine clients access data in a single-node engine according to the data protection mode specified by the storage engine cluster manager or the storage engine designer. For example, a storage user may specify EC4+2, collapsed EC20+4:1, or replication protection mode in the cluster management GUI. The cluster manager generates a view and synchronizes this protection information to the engine client through view diffusion. The engine client then determines the data protection mode based on the view.
[0033] The storage stand-alone engine provides local data persistence and persistent data access capabilities.
[0034] The storage engine cluster management determines the data protection mode and data read and write methods, ensuring data consistency and high-performance data access within the cluster, providing efficient data storage. The storage cluster management provides a GUI and allows customers to select a protection mode. For example, if a customer chooses a folded EC20+4:1 configuration with a rack as the failure domain, the storage cluster management will select disks based on the protection mode and generate a view. The three major components within the storage determine which disks in which rack to read and write based on the PGs configured in the view.
[0035] An embodiment of the present invention provides a distributed storage dynamic data protection system, which includes a storage engine client, a storage stand-alone engine module, and a storage engine cluster management module.
[0036] Exemplarily, the storage engine cluster management module is used to publish data views, determine the protection mode and read / write mode of the data views, and spread the data views to the storage engine clients and the storage stand-alone engine modules.
[0037] Specifically, the read-write mode is used to divide the data view into read-only data and read-write data. Migrated data in the data view is read-only data; non-migrated data in the data view is read-write data. The protection mode is used to authoritatively shard the data view. The authoritative shards include authoritative node disks and non-authoritative sets.
[0038] In addition, data views are generated by the storage engine cluster management module.
[0039] Exemplarily, the storage engine client accesses the data view in the storage engine cluster management module through the protection mode, and synchronizes the data view to the storage stand-alone engine module.
[0040] Exemplarily, the storage engine client writes data views in a read-write manner, and migrates migratable data views in a protection mode.
[0041] Exemplarily, the storage engine cluster management module switches the view of the migrated data and spreads it to the storage engine client and the storage stand-alone engine module.
[0042] Specifically, when switching views, the following steps are included: selecting the data view to be switched and switching the protection mode; selecting the nodes that intersect with the authoritative node disk in the switched data view to build a non-authoritative set; publishing the non-authoritative set as the first new view; starting the migration command, marking the authoritative shards participating in the migration in the first new view as read-only, reading the data of the authoritative shards, and writing them to the non-authoritative set in accordance with the EC method; performing a consistency check on the first new view after migration, and then forming a new authoritative shard set; re-converting the data view to writable data, publishing the second new view, and spreading the second new view to the cluster through the cluster view diffusion solution.
[0043] In addition, the first new view is read-only during the migration, and no new data is written during the migration process.
[0044] Furthermore, standalone storage engines are deployed on general-purpose servers. Storage engine cluster management is deployed as a cluster using the Paxos or Raft protocols. The storage engine client is integrated into the product as an SDK for services (such as block, file, and object). Standalone storage engines and storage engine clients are guaranteed to have access to the storage cluster management, and the storage engine cluster management can manage all standalone storage engines.
[0045] Exemplarily, the storage stand-alone engine module is used to provide local data persistence and persistent data access for the storage engine client.
[0046] On the other hand, an embodiment of the present invention provides a distributed storage dynamic data protection method, including:
[0047] Publish data views, determine their protection mode and read / write methods, and propagate them to storage engine clients and standalone storage engine modules.
[0048] Access the data view in the storage engine cluster management module in protection mode and synchronize the data view to the storage standalone engine module;
[0049] Write data views in read-write mode and migrate migratable data views in protected mode;
[0050] Switch the migrated data view and propagate it to the storage engine client and the storage stand-alone engine module.
[0051] The specific embodiments of the above distributed storage dynamic data protection method are as follows:
[0052] Take the storage engine that uses views as the sole basis, star write, and append write as an example:
[0053] PG: Data Protection Group;
[0054] Authoritative shard: The shard cluster management determines that the data in the PG is consistent and the disk is kept online with the cluster management.
[0055] (1) The storage engine cluster management module publishes the view, which is quickly propagated to the storage engine client and the storage engine module. A. PGs that need to be migrated are read-only; B. PGs not involved are read-write.
[0056] (2) The storage engine cluster management ensures that the shards designed for the PG being migrated are read-only and that the views have been synchronized to the corresponding storage stand-alone engines. Since it is controlled by views, the generation of views is uniformly generated by the cluster management. When the migration is started, it is ensured that the views have been synchronized to the relevant stand-alone engines (which can be achieved through logical clocks). Therefore, during the migration process, no matter what version the client obtains, no new data can be written to the PG.
[0057] (3) When the storage engine client writes new data, it uses a writable PG.
[0058] (4) When the storage engine client needs to read data from the PG being migrated, it uses the protection mode corresponding to the authoritative shard. Referring to the explanation of authoritative shards above, the authoritative shard set in the PG corresponds to replicas. In some protection modes of EC, replicas are read through replicas, while EC calculates the data's location in the shard and performs repair reads in case of hardware failures.
[0059] (5) After the migration is completed, the storage engine cluster manages the view switch and spreads it to the storage engine client and the storage stand-alone engine.
[0060] The entire view change process is as follows: Taking the node failure domain and 3 replicas switching to EC4+2 as an example:
[0061] 1. Currently all PGs have 3 copies;
[0062] 2. Select a configured number of PGs (for example, 2) at a time to switch the protection mode;
[0063] 3. The selected PG selects 6 disks from another node based on EC4+2 (which have no intersection with the disks of the current authoritative node), forming a non-authoritative set of EC4+2;
[0064] 4. Publish new views;
[0065] 5. Start the migration command, requiring the authoritative shards involved in the migration to be read-only. After reading the data from the authoritative shards, write it to the non-authoritative collection in the EC manner;
[0066] 6. After the migration is complete and the PG consistency check is done, the EC4+2 set replaces the 3-replica set to form the new authoritative shard set;
[0067] 7. The PG becomes writable again, a new view is published, and the view is propagated to the cluster through the cluster view propagation solution, thus implementing the change to the PG.
[0068] 8. Repeat steps 1 to 7 to complete the switchover of the entire cluster.
[0069] Since writes are redirected and a new PG is immediately used to write after a write failure, the read and write of upper-layer services is not affected. Some PGs write large amounts of data, while others write small amounts of data. Cluster balancing issues are considered separately from the perspective of cluster balance.
[0070] By setting the PG being migrated to read-only, no new data is written during the PG migration process, making the migration simple and reliable, and allowing migration to large-scale erasure coding. The storage engine dynamically switches from three-replica protection mode to EC (Erasure Code) protection mode. The storage engine dynamically switches from small-scale EC (Erasure Code) protection mode to EC (Erasure Code) protection mode. During this dynamic switch, the storage engine remains unaware of the business.
[0071] In addition, this embodiment also provides a terminal device of the present invention. The distributed storage dynamic data protection method involved in this embodiment is mainly applied to the terminal device, which can be a PC, portable computer, mobile terminal, etc. with display and processing functions.
[0072] Specifically, a terminal device may include a processor (e.g., a CPU), a communication bus, a user interface, a network interface, and a memory. The communication bus is used to enable communication between these components; the user interface may include a display and an input unit such as a keyboard; the network interface may optionally include a standard wired interface or a wireless interface (e.g., a Wi-Fi interface); and the memory may be high-speed RAM or non-volatile memory, such as a disk drive. The memory may also be a storage device independent of the processor.
[0073] Among them, the memory stores a readable storage medium, and the readable storage medium stores a distributed dynamic data protection program. The processor can call the dynamic data protection program stored in the memory and execute the distributed storage dynamic data protection method provided by the embodiment of the present invention.
[0074] It is understood that a computer-readable storage medium can be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium can be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. More specific examples (a non-exhaustive list) of computer-readable storage media include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disc read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination thereof. As used herein, a computer-readable storage medium is not to be construed as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through an electrical wire.
[0075] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions to be stored in the computer-readable storage medium in each computing / processing device.
[0076] The computer program instructions for performing the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages such as Smalltalk, C++, and conventional procedural programming languages such as "C" language or similar programming languages. Computer-readable program instructions may be executed entirely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may 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 may be connected to an external computer (e.g., utilizing an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be personalized by utilizing the state information of the computer-readable program instructions. The electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0077] Finally, it should be noted that the above are only preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or make equivalent replacements for some of the technical features therein. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A distributed storage dynamic data protection system, characterized in that: It includes the storage engine client, the storage stand-alone engine module, and the storage engine cluster management module, including: The storage engine cluster management module is used to publish the data view, determine the protection mode and read / write mode of the data view, and spread the data view to the storage engine client and the storage stand-alone engine module; The storage engine client accesses the data view in the storage engine cluster management module through the protection mode, and synchronizes the data view to the storage stand-alone engine module; The storage engine client writes the data view in the read-write mode, and migrates the migratable data view in the protection mode; The storage engine cluster management module switches the view of the migrated data and spreads it to the storage engine client and the storage stand-alone engine module.
2. A distributed storage dynamic data protection system according to claim 1, characterized in that: The storage stand-alone engine module is used to provide local data persistence and persistent data access for the storage engine client.
3. A distributed storage dynamic data protection system according to claim 1, characterized in that: The read-write mode is used to divide the data view into read-only data and readable and writable data.
4. A distributed storage dynamic data protection system according to claim 3, characterized in that: The migrated data in the data view is read-only data; the non-migrated data in the data view is readable and writable data.
5. A distributed storage dynamic data protection system according to claim 3, characterized in that: The protection mode is used to authoritatively shard the data view.
6. A distributed storage dynamic data protection system according to claim 5, characterized in that: The authoritative shards include authoritative node disks and non-authoritative sets.
7. A distributed storage dynamic data protection system according to claim 6, characterized in that: The view switching includes: Selecting the data view to be switched and switching the protection mode; The data view after switching selects nodes that intersect with the authoritative node disk to construct a non-authoritative set; Publishing the non-authoritative collection as a first new view; Start the migration command, mark the authoritative shards participating in the migration in the first new view as read-only, read the data of the authoritative shards, and write them to the non-authoritative set in the EC mode; After the migration, a consistency check is performed on the first new view and the collection is then formed into a new authoritative shard set; The data view is repositioned to write data, a second new view is published, and the second new view is diffused to the cluster through a cluster view diffusion solution.
8. A distributed storage dynamic data protection system according to claim 7, characterized in that: The data view is generated by the storage engine cluster management module.
9. A distributed storage dynamic data protection system according to claim 8, characterized in that: The first new view is read-only during the migration, and no new data is written during the migration process.
10. A distributed storage dynamic data protection method, characterized in that: include: Publish data views, determine the protection mode and read / write mode of data views, and spread data views to storage engine clients and storage stand-alone engine modules; Access the data view in the storage engine cluster management module through protection mode, and synchronize the data view to the storage stand-alone engine module; Write data views in read-write mode and migrate migratable data views in protection mode; Switch the migrated data view and spread it to the storage engine client and storage stand-alone engine module.
Citation Information
Patent Citations
Distributed block storage system and data routing method thereof
CN109327539A
Data processing method, device and system, equipment and medium
CN112948178A
Distributed block storage system based on erasure codes
CN113326006A
Distributed storage cluster, storage engine, and two-copy storage method and device
CN114610235A
Distributed database cluster management and control method and device and database management and control platform
CN116414915A
