CN115061856A - Block-based persistent volume backup method, system, storage medium and recovery method thereof - Google Patents

Block-based persistent volume backup method, system, storage medium and recovery method thereof Download PDF

Info

Publication number
CN115061856A
CN115061856A CN202210981605.8A CN202210981605A CN115061856A CN 115061856 A CN115061856 A CN 115061856A CN 202210981605 A CN202210981605 A CN 202210981605A CN 115061856 A CN115061856 A CN 115061856A
Authority
CN
China
Prior art keywords
volume
persistent volume
backup
snapshot
persistent
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202210981605.8A
Other languages
Chinese (zh)
Other versions
CN115061856B (en
Inventor
胡晓勤
刘国印
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan University
Original Assignee
Sichuan University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sichuan University filed Critical Sichuan University
Priority to CN202210981605.8A priority Critical patent/CN115061856B/en
Publication of CN115061856A publication Critical patent/CN115061856A/en
Application granted granted Critical
Publication of CN115061856B publication Critical patent/CN115061856B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1458Management of the backup or restore process
    • G06F11/1469Backup restoration techniques

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to a block-based persistent volume backup method, a block-based persistent volume backup system, a storage medium and a recovery method thereof, and belongs to the field of data backup and recovery. The method comprises the following steps: a first target persistent volume statement acquisition step; an object information acquisition step; acquiring a volume snapshot class; a mapping triple creating step; a mapping relation construction step; a CSI snapshot creating step; a second persistent volume statement creation step; and a backup execution step. The system comprises: a first target persistent volume declaration acquisition joining module; an object information acquisition module; a volume snapshot class acquiring and adding module; a mapping triple creating and adding module; a mapping relation construction recording module; a CSI snapshot creation filling module; a second persistent volume declaration creation joining module; and backing up the execution module. The invention provides a unified method for backing up k8s persistent volume data, which completes block-based backup work by converting the working mode of the persistent volume, does not need to process each file independently, and has simple and efficient backup logic.

Description

Block-based persistent volume backup method, system, storage medium and recovery method thereof
Technical Field
The invention belongs to the field of data backup and recovery, and relates to a block-based persistent volume backup method, a block-based persistent volume backup system, a storage medium and a recovery method of the storage medium.
Background
A container is a virtualization technology, similar in function to a virtual machine, both of which are used to provide an environment isolated from the outside world, except that containers are lighter weight and more efficient than virtual machines. A container is stateless and once closed, the data it generates at runtime is lost in its entirety. K8s, collectively referred to as kubernets, is used to manage containerized applications on multiple hosts in the cloud, and K8s may make deployment of containerized applications simple and efficient. k8s provides a persistent volume to support stateful applications such as databases. A persistent volume may be understood as a file system or Block device that can be mounted inside a container, corresponding to two operating modes Filesystem and Block, respectively. CSI is a storage interface specification used by k8s that defines interfaces for functions such as creating persistent volumes, deleting persistent volumes, and snapshots. Any storage that implements the CSI specification may be stored as the back end of k8s.
At present, most of the technologies for backing up persistent volumes are based on files, and such technologies are to back up files in each file directory in a persistent volume to a server, so that the backup of the persistent volume can be completed, but certain disadvantages exist, firstly, the types of backup data to be analyzed are complicated, for example, the authority, the size and the like of each file need to be analyzed; secondly, if the number of files in the persistent volume is too large, the time occupation ratio of opening and closing the files is correspondingly increased, which greatly reduces the backup efficiency. The persistent volume backup mode of the Block device can directly backup the persistent volume in the Block mode by reading data of the Block device in the container, but the technology also faces a certain problem that the technology cannot be directly applied to the persistent volume in the file mode because in the mode, the container can only access the persistent volume in a file directory access mode and cannot access the Block device.
Therefore, how to provide a simple and efficient persistent volume backup method becomes a technical problem which needs to be solved urgently at present.
Disclosure of Invention
In order to solve the technical problems in the background art, embodiments of the present invention provide a method, a system, a storage medium, and a recovery method for a block-based persistent volume backup. The technical scheme is as follows:
in a first aspect, a block-based persistent volume backup method is provided, the method comprising the steps of:
acquiring a first target persistent volume statement and adding the first target persistent volume statement into a first target persistent volume statement list;
traversing the first target persistent volume declaration list, and acquiring backup object information, wherein the backup object information includes: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration;
acquiring all volume snapshot classes and adding the volume snapshot classes into a volume snapshot class list;
creating a mapping triple A according to a first target persistent volume declaration list, and adding the mapping triple A into the mapping triple list A, wherein the mapping triple A comprises a first target persistent volume declaration field, a volume snapshot type field and a backup CSI snapshot field;
according to the backup object information and the volume snapshot class list, constructing a mapping relation between each first target persistent volume statement and the volume snapshot class, and recording the mapping relation to a mapping triple A to form a mapping triple B and a mapping triple list B;
traversing the first target persistent volume statement list, creating a backup CSI snapshot for each first target persistent volume statement, and filling the backup CSI snapshot into the mapping triple B to form a mapping triple C and a mapping triple list C, wherein the mapping triple B is the mapping triple B where the currently traversed first target persistent volume statement is located;
creating a second persistent volume statement according to the backup CSI snapshot field of each mapping triple C in the mapping triple list C, and adding the second persistent volume statement into a second persistent volume statement list, wherein the second persistent volume statement is bound with a second persistent volume;
and executing the backup operation according to the second persistent volume statement list and the mapping triple list C.
In one embodiment, the step of constructing a mapping relationship between each first target persistent volume declaration and the volume snapshot class according to the backup object information and the volume snapshot class list, and then recording the mapping relationship to a mapping triple a to form a mapping triple B and a mapping triple list B includes:
acquiring storage class information according to the backup object information, wherein the storage class information comprises a provisioner field;
traversing a volume snapshot type list, and acquiring volume snapshot type information of each volume snapshot type, wherein the volume snapshot type information comprises a driver field;
traversing a volume snapshot class list for each first target persistent volume statement in a first target persistent volume statement list respectively, judging whether a provisioner field value of a storage class used by the first target persistent volume statement is the same as a driver field value of a current traversal volume snapshot class, and if so, constructing a mapping relation between the first target persistent volume statement and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class;
and writing the first target persistent volume statement and the volume snapshot class mapped by the first target persistent volume statement into the mapping triple A according to the mapping relation to form a mapping triple B and a mapping triple list B.
In one embodiment, the creating a second persistent volume declaration according to the backup CSI snapshot field of each mapping triplet C in the mapping triplet list C and adding the second persistent volume declaration to a second persistent volume declaration list, where the second persistent volume declaration binding the second persistent volume includes:
traversing the mapping triple list C, and constructing a second persistent volume declaration template for each mapping triple C;
filling the second persistent volume declaration template according to the first target persistent volume declaration and the backup CSI snapshot recorded in the mapping triple C, wherein a dataSource field of the second persistent volume declaration template is the name of the backup CSI snapshot;
adding a volumeMode field in the filled second persistent volume declaration template, and setting the volumeMode field as Block;
creating a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and adding the second persistent volume declaration to a second persistent volume declaration list, wherein the second persistent volume declaration binds a second persistent volume.
In one embodiment, the step of performing a backup operation according to the second persistent volume declaration list and the mapping triple list C includes:
creating a backup image, wherein the backup image comprises a backup program;
creating a backup container for each second persistent volume statement in the second persistent volume statement list through the backup mirror, wherein the backup container references the second persistent volume statement by mounting a block device;
the backup program obtains the block data in the second persistent volume by reading the block device in the backup container;
the backup program acquires backup object information through a dataSource field and a mapping triple C of a second persistent volume statement;
and packaging the backup object information and the block data into backup data and sending the backup data to a server.
In a second aspect, there is also provided a block-based persistent volume backup system, the system comprising:
the first target persistent volume statement acquiring and joining module is used for acquiring a first target persistent volume statement and joining the first target persistent volume statement into a first target persistent volume statement list;
an object information obtaining module, configured to traverse the first target persistent volume declaration list, and obtain backup object information, where the backup object information includes: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration;
the volume snapshot class acquiring and adding module is used for acquiring all volume snapshot classes and adding the volume snapshot classes into the volume snapshot class list;
the mapping triple creating and adding module is used for creating a mapping triple A according to a first target persistent volume statement list and adding the mapping triple A into the mapping triple list A, wherein the mapping triple A comprises a first target persistent volume statement field, a volume snapshot type field and a backup CSI snapshot field;
a mapping relation establishing and recording module, configured to establish a mapping relation between each first target persistent volume statement and the volume snapshot class according to the backup object information and the volume snapshot class list, and then record the mapping relation to a mapping triple a to form a mapping triple B and a mapping triple list B;
a CSI snapshot creating and filling module, configured to traverse the first target persistent volume declaration list, create a backup CSI snapshot for each first target persistent volume declaration, and fill the backup CSI snapshot into the mapping triple B to form a mapping triple C and a mapping triple list C, where the mapping triple B is the mapping triple B where the currently traversed first target persistent volume declaration is located;
a second persistent volume declaration creating and joining module, configured to create a second persistent volume declaration according to a backup CSI snapshot field of each mapping triplet C in the mapping triplet list C, and join the second persistent volume declaration into a second persistent volume declaration list, where the second persistent volume declaration binds a second persistent volume;
and the backup execution module is used for executing backup operation according to the second persistent volume statement list and the mapping triple list C.
In one embodiment, the mapping relationship construction recording module includes:
a storage class information obtaining unit, configured to obtain storage class information according to the backup object information, where the storage class information includes a provisioner field;
the volume snapshot type information acquisition unit is used for traversing the volume snapshot type list and acquiring the volume snapshot type information of each volume snapshot type, wherein the volume snapshot type information comprises a driver field;
the judging unit is used for respectively traversing a volume snapshot class list for each first target persistent volume statement in a first target persistent volume statement list, judging whether a provisioner field value of a storage class used by the first target persistent volume statement is the same as a driver field value of a current traversal volume snapshot class, and if so, establishing a mapping relation between the first target persistent volume statement and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class;
and the mapping writing unit is used for writing the first target persistent volume statement and the volume snapshot class mapped by the first target persistent volume statement into the mapping triple A according to the mapping relation to form a mapping triple B and a mapping triple list B.
In one embodiment, the second persistent volume declaration createojoining module includes:
the second persistent volume declaration template building unit is used for traversing the mapping triple list C and building a second persistent volume declaration template for each mapping triple C;
a second persistent volume declaration template filling unit, configured to fill a second persistent volume declaration template according to the first target persistent volume declaration and the backup CSI snapshot recorded in the mapping triple C, where a dataSource field of the second persistent volume declaration template is a name of the backup CSI snapshot;
the second persistent volume declaration mode setting unit is used for adding a volumeMode field in the filled second persistent volume declaration template and setting the volumeMode field as Block;
and the second persistent volume declaration creating unit is used for creating a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and adding the second persistent volume declaration into a second persistent volume declaration list, wherein the second persistent volume declaration binds a second persistent volume.
In one embodiment, the backup execution module includes:
a backup image creating unit for creating a backup image, the backup image including a backup program;
a backup container creating unit, configured to create a backup container for each second persistent volume statement in the second persistent volume statement list through the backup mirror, where the backup container refers to the second persistent volume statement by mounting a block device;
a block data acquisition unit, configured to acquire, by the backup program, block data in the second persistent volume by reading a block device inside the backup container;
a backup object information obtaining unit, configured to obtain, by the backup program, backup object information through a dataSource field of the second persistent volume declaration and the mapping triple C;
and the sending unit is used for packaging the backup object information and the block data into backup data and sending the backup data to the server.
In a third aspect, there is also provided a block-based persistent volume recovery method, the method comprising the steps of:
creating a recovery container to recover the persistent volume data;
the recovery container acquires backup data of a server side, and decapsulates the backup data into recovery block data and recovery object information;
creating a recovery persistent volume statement A according to the recovery object information, wherein the working mode of the recovery persistent volume statement A is Block, and the recovery persistent volume statement A is bound with the recovery persistent volume A;
the recovery container refers to a recovery persistent volume statement A in a mounting block device mode, and writes the recovery block data into a recovery persistent volume A;
judging whether the working mode in the recovery object information is a file system or not; if so, generating a recovery CSI snapshot for the recovery persistent volume statement A, deleting the recovery persistent volume statement A, creating a recovery persistent volume statement B according to the recovery CSI snapshot, and finishing recovery, wherein the working mode of the recovery persistent volume statement B is file system, and the recovery persistent volume B is bound; if not, the recovery is ended.
In a fourth aspect, a computer-readable storage medium is also provided, on which a computer program is stored, which when executed by a processor implements the above-described block-based persistent volume backup method.
The invention has the beneficial effects that:
(1) the persistent volumes of the two working modes can be backed up in a unified mode without separately processing the two working modes;
(2) the persistent volume with the working mode of File is converted into the persistent volume backup with the working mode of Block, the metadata of each file does not need to be independently backed up, and the backup logic is simple;
(3) compared with a file-based backup mode, the block-based backup method used by the invention has better backup efficiency under the condition that the number of small files is large.
(4) The invention generates the CSI snapshot for the persistent volume and then performs the backup operation, thereby ensuring the consistency of the backup data.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a block-based persistent volume backup method according to an embodiment of the present invention.
Fig. 2 is a block diagram of a first persistent volume declaration list in accordance with an embodiment of the present invention.
Fig. 3 is a structural diagram of a volume snapshot class list according to an embodiment of the present invention.
Fig. 4 is a structural diagram of a block-based persistent volume backup system according to a second embodiment of the present invention.
Fig. 5 is a structural diagram of a mapping relationship construction recording module in the second embodiment of the present invention.
FIG. 6 is a block diagram of a second persistent volume declaration creation join module in accordance with a second embodiment of the present invention.
Fig. 7 is a structural diagram of a backup execution module according to a second embodiment of the present invention.
FIG. 8 is a graph showing the results of the experiment in the second embodiment of the present invention.
In the drawings, the components represented by the respective reference numerals are listed below:
1001. a first target persistent volume declaration obtaining and joining module 1002, an object information obtaining module 1003, a volume snapshot class obtaining and joining module 1004, a mapping triple creating and joining module 1005, a mapping relation construction recording module 1006, a CSI snapshot creating and filling module 1007, a second persistent volume declaration creating and joining module 1008, a backup execution module 10051, a storage class information obtaining unit 10052, a volume snapshot class information obtaining unit 10053, the system comprises a judging unit, 10054, a mapping writing unit, 10071, a second persistent volume statement template building unit, 10072, a second persistent volume statement template filling unit, 10073, a second persistent volume statement mode setting unit, 10074, a second persistent volume statement creating unit, 10081, a backup mirror image creating unit, 10082, a backup container creating unit, 10083, a block data acquiring unit, 10084, a backup object information acquiring unit, 10085 and a sending unit.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and do not delimit the invention.
The method provided by the invention can be applied to the following environments: version k8s is kubernets v1.22.4, back-end storage used by k8s is Ceph v15.2.15, and the backup and restore logic is written by Golang.
Interpretation of terms:
(1) persistent roll: the data storage system is used for storing the data generated by the container, and even if the container exits from operation, the data stored in the persistent volume cannot disappear;
(2) persistent volume declaration: the container applies for using the persistent volume through the persistent volume declaration, when the application is successful, the persistent volume declaration is bound with the persistent volume, and the k8s generally performs various operations on the persistent volume through the persistent volume declaration;
(3) the storage class: the storage class stores some general information needed when the persistent volume declaration applies to use the persistent volume;
(4) volume snapshot class: the volume snapshot class stores some general information required for taking the persistent volume snapshot, and the volume snapshot class is required to be used when the persistent volume snapshot is taken;
(5) CSI snapshot: the mode of taking the snapshot of the persistent volume by the k8s is to call a CSI interface realized by a storage manufacturer, and the snapshot generated in this mode is called a CSI snapshot.
Example one
As shown in fig. 1, the present embodiment provides a block-based persistent volume backup method, which includes the steps of:
s1, obtaining a first target persistent volume statement and adding the first target persistent volume statement into a first target persistent volume statement list.
It is to be understood that the first target persistent volume declaration specifically refers to: a persistent volume declaration bound to the persistent volume to be backed up.
In the process of backing up the persistent volume, the container may write data into the persistent volume, so that the data is changed in the backup process. Therefore, in order to ensure the consistency of backup, the persistent volume should not be directly backed up, but a CSI snapshot of the persistent volume is taken at a time point when the backup is started to be executed, and then data backup is performed from the CSI snapshot.
k8s requires a snapshot of the persistent volume through the persistent volume declaration bound to the persistent volume, so to backup the target persistent volume, first the first target persistent volume declaration bound to the target persistent volume is obtained.
S2, traversing the first target persistent volume statement list to acquire backup object information, wherein the backup object information comprises: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration.
It can be understood that the object information of the persistent volume declaration restored from the backup data needs to be consistent with the persistent volume declaration before backup, and thus the object information of the persistent volume declaration needs to be backed up. This information includes name, namespace, operating mode, persistent volume size, access mode, and storage class name.
It should be further understood that the name, namespace, working mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration specifically refer to:
a name of a first target persistent volume declaration; a namespace of a first target persistent volume declaration; a mode of operation of the first target persistent volume declaration; a first target persistent volume declared persistent volume size; a first target persistent volume declared access mode; the first target persistent volume declared storage class name.
And S3, acquiring all the volume snapshot classes and adding the volume snapshot classes into a volume snapshot class list.
And S4, creating a mapping triple A according to the first target persistent volume declaration list, and adding the mapping triple A into the mapping triple list A, wherein the mapping triple A comprises a first target persistent volume declaration field, a volume snapshot type field and a backup CSI snapshot field.
It should be noted that different storage vendors have different ways of implementing the CSI interfaces, and the volume snapshot types used when the CSI snapshot is taken are different. Therefore, a volume snapshot class corresponding to each first target persistent volume statement needs to be found first, and then a CSI snapshot is taken for the first target persistent volume statement through the volume snapshot class. The mapping triple list is used for recording the mapping relation among the first target persistent volume statement, the volume snapshot class and the CSI snapshot.
And S5, according to the backup object information and the volume snapshot class list, constructing a mapping relation between each first target persistent volume statement and the volume snapshot class, and recording the mapping relation to a mapping triple A to form a mapping triple B and a mapping triple list B.
Optionally, the step S5 includes:
and S51, acquiring storage class information according to the backup object information, wherein the storage class information comprises a provisioner field.
S52, traversing the volume snapshot list, and acquiring the volume snapshot information of each volume snapshot, wherein the volume snapshot information comprises a driver field.
S53, traversing a volume snapshot class list for each first target persistent volume statement in a first target persistent volume statement list respectively, judging whether a provisioner field value of a storage class used by the first target persistent volume statement is the same as a driver field value of a current traversal volume snapshot class, and if so, constructing a mapping relation between the first target persistent volume statement and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class.
It is worth noting that the first target persistent volume declares that the bound persistent volume is created by a storage class whose provisioner field identifies the storage vendor to which the persistent volume corresponds. And if the provisioner field of the storage class is the same as the driver field of the volume snapshot class, the first target persistent volume statement can shoot the snapshot through the volume snapshot class. The volume snapshot class for which the CSI snapshot should be taken can be found from the storage class used by the first target persistent volume declaration.
For ease of understanding, specifically, an example of operation is provided for step S53: in a backup operation, the first target persistent volume declaration list is shown in FIG. 2, and includes two first target persistent volume declarations, namely persistent volume declaration A (pvc-1) and persistent volume declaration B (pvc-2); the volume snapshot class list includes two volume snapshot classes, namely, a volume snapshot class a (csi-hostpath-snap class) and a volume snapshot class B (csi-rbdplugin-snap class), as shown in fig. 3. The storage class used by the persistent volume declaration A is a storage class A (csi-rbd-sc), the query data knows that the provider field of the storage class is rbd.csi.ceph.com, firstly, whether the volume snapshot class A is matched with the storage class is judged, the driver field of the volume snapshot class A is different from the value of the provider field of the storage class A, and the volume snapshot class is skipped over; and judging the volume snapshot class B, wherein the driver field of the volume snapshot class B is the same as the provisioner field value of the storage class A, so that a mapping relation is established between the persistent volume statement A and the volume snapshot class B. The storage class used by the persistent volume declaration B is a storage class B (csi-hostpath-sc), the query data knows that the provider field of the storage class is hostpath, csi, i, and judges whether the volume snapshot class A is matched with the storage class, and the driver field of the volume snapshot class A is the same as the value of the provider field of the storage class B, so that a mapping relation is established between the persistent volume declaration B and the volume snapshot class A.
And S54, writing the first target persistent volume statement and the volume snapshot class mapped by the first target persistent volume statement into the mapping triple A according to the mapping relation to form a mapping triple B and a mapping triple list B.
S6, traversing the first target persistent volume statement list, creating a backup CSI snapshot for each first target persistent volume statement, and filling the backup CSI snapshots into the mapping triple B to form a mapping triple C and a mapping triple list C, wherein the mapping triple B is the mapping triple B where the currently traversed first target persistent volume statement is located.
S7, according to the backup CSI snapshot field of each mapping triple C in the mapping triple list C, a second persistent volume statement is created, and the second persistent volume statement is added into a second persistent volume statement list, wherein the second persistent volume statement is bound with a second persistent volume.
Optionally, the step S7 includes:
s71, traversing the mapping triple list C, and constructing a second persistent volume declaration template for each mapping triple C.
And S72, filling the second persistent volume statement template according to the first target persistent volume statement and the backup CSI snapshot recorded in the mapping triple C, wherein a dataSource field of the second persistent volume statement template is the name of the backup CSI snapshot.
And S73, adding a volume mode field in the second filled persistent volume declaration template, and setting the volume mode field as Block.
S74, creating a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and adding the second persistent volume declaration into a second persistent volume declaration list, wherein the second persistent volume declaration binds a second persistent volume.
It is worth noting that k8s has no direct access to the specific content of the CSI snapshot. If the data of the CSI snapshot is to be accessed at k8s, a second persistent volume declaration needs to be created from the CSI snapshot by specifying the dataSource field of the second persistent volume declaration as the name of the CSI snapshot.
If the volume mode field of the second persistent volume declaration template is not specified, the working mode of the created persistent volume is default to Filesystem, and the backup container can only read data from the CSI snapshot in a file manner. And after setting the volume mode field of the second persistent volume declaration template as Block, the created persistent volume working mode is Block, and at this time, no matter which working mode the first target persistent volume declaration is, the backup container can backup data from the CSI snapshot in a manner of reading the Block device. The operation aims to convert a first target persistent volume declaration with a working mode of Filesystem into a second persistent volume declaration with a working mode of Block through a CSI snapshot, so that no matter which working mode of the persistent volume is, a backup container can be backed up in the same way.
And S8, executing backup operation according to the second persistent volume statement list and the mapping triple list C.
Optionally, the step S8 includes:
s81, creating a backup image, wherein the backup image comprises a backup program.
S82, creating a backup container for each second persistent volume statement in the second persistent volume statement list through the backup mirror, wherein the backup container refers to the second persistent volume statement in a mode of mounting a block device.
For ease of understanding, specifically, an example of operation is provided for step S82: in a backup process, the second list of persistent volume claims contains a second persistent volume claim named pvc-second-1. A backup container template is created that uses the volumeDevices field to specify that the container references the second persistent volume declaration in a mount device fashion, with the child field devicepPath of volumeDevices specified as/dev/xvda. And creating a backup container by using the backup container template, opening the/dev directory in the backup container, and seeing that a file xvda of a block device type exists in the/dev directory, wherein the content saved by the xvda file is the data needing to be backed up by the backup container.
And S83, the backup program obtains the block data in the second persistent volume in a mode of reading the block device in the backup container.
It is worth noting that the block data in the second persistent volume obtained by reading the block device inside the backup container is not all backed up. The inside of a block device comprises a plurality of storage areas taking blocks as units, and data is stored in some blocks in a binary mode, so that in the backup process, only the blocks in which the data are stored and the offset positions of the blocks are required to be backed up, and empty blocks in which the data are not stored can be directly skipped.
It should be further noted that, in a backup scenario where a large number of small files are provided, the block device needs to be opened only once before data is read in the block device layer backup, and the block device needs to be closed once after the data is read. Therefore, under the backup scene that the number of small files is large, the block-based persistent volume backup mode has higher efficiency.
And S84, the backup program acquires backup object information through the data source field and the mapping triple C of the second persistent volume statement.
It can be understood that the data source field of the second persistent volume declaration indicates a CSI snapshot used by the data source applying for using the persistent volume, and the CSI snapshot name may be used to obtain the first target persistent volume declaration corresponding to the second persistent volume declaration from the mapping triple C, so as to obtain the backup object information.
And S85, packaging the backup object information and the block data into backup data and sending the backup data to a server.
According to the technical scheme, the persistent volume with the working mode of file is converted into the persistent volume with the working mode of Block through the CSI snapshot, the backup container can backup the persistent volumes with the two working modes by using one method, and the method is simple and efficient. Meanwhile, the method of the embodiment shoots the CSI snapshot before backup, and then backs up the persistent volume data through the CSI snapshot with unchanged data during the backup period, so that the consistency of the data is ensured.
Example two
As shown in FIG. 4, in one embodiment, a block-based persistent volume backup system is provided, the system comprising:
a first target persistent volume declaration obtaining and joining module 1001, configured to obtain a first target persistent volume declaration and join the first target persistent volume declaration into a first target persistent volume declaration list;
an object information obtaining module 1002, configured to traverse the first target persistent volume declaration list, and obtain backup object information, where the backup object information includes: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration;
a volume snapshot class acquiring and adding module 1003, configured to acquire all volume snapshot classes and add them to the volume snapshot class list;
a mapping triple creating and adding module 1004, configured to create a mapping triple a according to a first target persistent volume declaration list, and add the mapping triple a to the mapping triple list a, where the mapping triple a includes a first target persistent volume declaration field, a volume snapshot class field, and a backup CSI snapshot field;
a mapping relationship establishing and recording module 1005, configured to establish a mapping relationship between each first target persistent volume statement and the volume snapshot class according to the backup object information and the volume snapshot class list, and then record the mapping relationship to a mapping triple a to form a mapping triple B and a mapping triple list B;
a CSI snapshot creating and filling module 1006, configured to traverse the first target persistent volume declaration list, create a backup CSI snapshot for each first target persistent volume declaration, and record the backup CSI snapshot to the mapping triple B to form a mapping triple C and a mapping triple list C, where the mapping triple B is the mapping triple B where the currently traversed first target persistent volume declaration is located;
a second persistent volume declaration creating and joining module 1007, configured to create a second persistent volume declaration according to the backup CSI snapshot field of each mapping triplet C in the mapping triplet list C, and join the second persistent volume declaration into a second persistent volume declaration list, where the second persistent volume declaration binds to a second persistent volume;
and a backup executing module 1008, configured to execute a backup operation according to the second persistent volume declaration list and the mapping triple list C.
Optionally, as shown in fig. 5, on the basis of this embodiment, the mapping relationship building module 1005 includes:
a storage class information obtaining unit 10051, configured to obtain storage class information according to the backup object information, where the storage class information includes a provider field;
a volume snapshot type information obtaining unit 10052, configured to traverse the volume snapshot type list, and obtain volume snapshot type information of each volume snapshot type, where the volume snapshot type information includes a driver field;
a determining unit 10053, configured to traverse a volume snapshot class list for each first target persistent volume declaration in a first target persistent volume declaration list, determine whether a provisioner field value of a storage class used by the first target persistent volume declaration is the same as a driver field value of a current traversal volume snapshot class, and if so, construct a mapping relationship between the first target persistent volume declaration and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class;
the mapping writing unit 10054 is configured to write the first target persistent volume declaration and the volume snapshot class mapped to the first target persistent volume declaration into the mapping triple a according to the mapping relationship, so as to form a mapping triple B and a mapping triple list B.
Optionally, as shown in fig. 6, on the basis of this embodiment, the second persistent volume declaration creation joining module 1007 includes:
a second persistent volume declaration template constructing unit 10071, configured to traverse the mapping triple list C and construct a second persistent volume declaration template for each mapping triple C;
a second persistent volume declaration template filling unit 10072, configured to fill the second persistent volume declaration template according to the first target persistent volume declaration and the backup CSI snapshot recorded in the mapping triple C, where a dataSource field of the second persistent volume declaration template is a name of the backup CSI snapshot;
a second persistent volume declaration mode setting unit 10073, configured to add a volumeMode field in the filled second persistent volume declaration template, and set the volumeMode field as Block;
a second persistent volume declaration creating unit 10074 is configured to create a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and add the second persistent volume declaration to a second persistent volume declaration list, where the second persistent volume declaration binds a second persistent volume.
Optionally, as shown in fig. 7, on the basis of this embodiment, the backup execution module 1008 includes:
a backup image creating unit 10081 configured to create a backup image, where the backup image includes a backup program;
a backup container creating unit 10082, configured to create a backup container for each second persistent volume declaration in the second persistent volume declaration list through the backup mirror, where the backup container refers to the second persistent volume declaration by mounting a block device;
a block data obtaining unit 10083, configured to obtain, by the backup program, block data in the second persistent volume by reading a block device inside the backup container;
a backup object information obtaining unit 10084, configured to obtain, by the backup program, backup object information through a dataSource field of the second persistent volume declaration and the mapping triple C;
a sending unit 10085, configured to encapsulate the backup object information and the block data into backup data, and send the backup data to the server.
In the technical solution of this embodiment, the first target persistent volume declaration obtaining and joining module 1001 is configured to obtain a first target persistent volume declaration and join the first target persistent volume declaration into a first target persistent volume declaration list; an object information obtaining module 1002, configured to traverse the first target persistent volume declaration list, and obtain backup object information; a volume snapshot class acquiring and adding module 1003, configured to acquire all volume snapshot classes and add them to the volume snapshot class list; a mapping triple creating and adding module 1004, configured to create a mapping triple a according to a first target persistent volume declaration list, and add the mapping triple a to the mapping triple list a; a mapping relationship establishing and recording module 1005, configured to establish a mapping relationship between each first target persistent volume statement and the volume snapshot class according to the backup object information and the volume snapshot class list, and then record the mapping relationship to a mapping triple a to form a mapping triple B and a mapping triple list B; a CSI snapshot creating and filling module 1006, configured to traverse the first target persistent volume declaration list, create a backup CSI snapshot for each first target persistent volume declaration, and record the backup CSI snapshot to the mapping triple B to form a mapping triple C and a mapping triple list C; a second persistent volume declaration creating and adding module 1007, configured to create a second persistent volume declaration according to the backup CSI snapshot field of each mapping triplet C in the mapping triplet list C, and add the second persistent volume declaration to a second persistent volume declaration list; and a backup executing module 1008, configured to execute a backup operation according to the second persistent volume declaration list and the mapping triple list C. The technical problem that metadata generated when the persistent volume is backed up through a file system is complicated is solved, for example, metadata such as the name, size, authority and modification time of each file need to be backed up when the persistent volume is backed up through the file. The embodiment converts the backup of the file in the persistent volume into the backup of the block device, and achieves the effect of improving the backup efficiency under the condition that a plurality of small files exist.
In the following, we provide a set of experiments, and to further illustrate this example, the experimental environment is: the operating system is Ubuntu 20.04.3 LTS, the Kubernets version is v1.22.4, the Kubernets backend storage is Ceph v15.2.15, and the cloud storage is Minio v7.0.22. In the experiment, 100 ten thousand small files with the size of 1kb-2kb are randomly generated in the persistent volume through a file generation program written by golang, the persistent volume is backed up respectively through a block-based backup mode and a file-based backup mode, and backup data are uploaded to cloud storage.
The evaluation index of this experiment is the time taken to backup the persistent volume data. As a result of the experiment, as shown in fig. 8, when the number of small files is large, the block-based backup method requires only 1 minute and 5 seconds, whereas the file-based backup method requires 16 minutes and 23 seconds. It can be seen that, under the condition that the number of small files is large, the block-based backup mode of the embodiment is obviously superior to the file-based backup mode in efficiency.
EXAMPLE III
In one embodiment, a block-based persistent volume restore method is provided, which uses the block-based persistent volume backup method described in embodiment 1, and further includes the steps of:
and S9, creating a recovery container for recovering the persistent volume data.
And S10, the recovery container acquires backup data of a server, and decapsulates the backup data into recovery block data and recovery object information.
S11, creating a recovery persistent volume statement A according to the recovery object information, wherein the working mode of the recovery persistent volume statement A is Block, and the recovery persistent volume statement A is bound with the recovery persistent volume A.
And S12, the recovery container refers to a recovery persistent volume statement A in a mode of mounting block equipment, and writes the recovery block data into the recovery persistent volume A.
S13, judging whether the working mode in the recovery object information is a Filesystem or not; if so, generating a recovery CSI snapshot for the recovery persistent volume statement A, deleting the recovery persistent volume statement A, creating a recovery persistent volume statement B according to the recovery CSI snapshot, and finishing recovery, wherein the working mode of the recovery persistent volume statement B is file system, and the recovery persistent volume B is bound; if not, the recovery is ended.
According to the technical scheme of the embodiment, the recovery persistent volume statement and the recovery persistent volume with the same attribute as the original persistent volume statement are created through the recovery object information, the recovery block data is written back to the recovery persistent volume through the recovery persistent volume statement, and finally whether the working modes of the recovery persistent volume statement and the recovery persistent volume need to be converted or not is judged, so that the recovery of the block-based persistent volume data is completed.
Example four
In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the program implements the method for capturing a database consistency point in a block level CDP according to the first embodiment.
Computer storage media for embodiments of the invention may employ any combination of one or more computer-readable media. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A method for block-based persistent volume backup, the method comprising the steps of:
acquiring a first target persistent volume statement and adding the first target persistent volume statement into a first target persistent volume statement list;
traversing the first target persistent volume declaration list, and acquiring backup object information, wherein the backup object information includes: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration;
acquiring all volume snapshot classes and adding the volume snapshot classes into a volume snapshot class list;
creating a mapping triple A according to a first target persistent volume declaration list, and adding the mapping triple A into the mapping triple list A, wherein the mapping triple A comprises a first target persistent volume declaration field, a volume snapshot type field and a backup CSI snapshot field;
according to the backup object information and the volume snapshot class list, constructing a mapping relation between each first target persistent volume statement and the volume snapshot class, and recording the mapping relation to a mapping triple A to form a mapping triple B and a mapping triple list B;
traversing the first target persistent volume statement list, creating a backup CSI snapshot for each first target persistent volume statement, and recording the backup CSI snapshot to the mapping triple B to form a mapping triple C and a mapping triple list C, wherein the mapping triple B is the mapping triple B where the currently traversed first target persistent volume statement is located;
creating a second persistent volume statement according to the backup CSI snapshot field of each mapping triple C in the mapping triple list C, and adding the second persistent volume statement into a second persistent volume statement list, wherein the second persistent volume statement is bound with a second persistent volume;
and executing the backup operation according to the second persistent volume statement list and the mapping triple list C.
2. The method of claim 1, wherein the step of constructing a mapping relationship between each first target persistent volume declaration and the volume snapshot class according to the backup object information and the volume snapshot class list, and recording the mapping relationship to a mapping triple a to form a mapping triple B and a mapping triple list B comprises:
acquiring storage class information according to the backup object information, wherein the storage class information comprises a provisioner field;
traversing a volume snapshot type list, and acquiring volume snapshot type information of each volume snapshot type, wherein the volume snapshot type information comprises a driver field;
respectively traversing a volume snapshot class list for each first target persistent volume statement in a first target persistent volume statement list, judging whether a provisioner field value of a storage class used by the first target persistent volume statement is the same as a driver field value of a current traversal volume snapshot class, and if so, constructing a mapping relation between the first target persistent volume statement and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class;
and writing the first target persistent volume statement and the volume snapshot class mapped by the first target persistent volume statement into the mapping triple A according to the mapping relation to form a mapping triple B and a mapping triple list B.
3. The block-based persistent volume backup method according to claim 1, wherein said creating a second persistent volume declaration according to the backup CSI snapshot field of each mapping triplet C in the mapping triplet list C and adding the second persistent volume declaration to a second persistent volume declaration list, wherein the step of binding the second persistent volume declaration to the second persistent volume declaration includes:
traversing the mapping triple list C, and constructing a second persistent volume declaration template for each mapping triple C;
filling the second persistent volume declaration template according to the first target persistent volume declaration and the backup CSI snapshot recorded in the mapping triple C, wherein a dataSource field of the second persistent volume declaration template is the name of the backup CSI snapshot;
adding a volumeMode field in the filled second persistent volume declaration template, and setting the volumeMode field as Block;
creating a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and adding the second persistent volume declaration to a second persistent volume declaration list, wherein the second persistent volume declaration binds a second persistent volume.
4. The block-based persistent volume backup method according to claim 3, wherein said step of performing a backup operation according to the second persistent volume declaration list and the mapping triple list C comprises:
creating a backup image, wherein the backup image comprises a backup program;
creating a backup container for each second persistent volume statement in the second persistent volume statement list through the backup mirror, wherein the backup container references the second persistent volume statement by mounting a block device;
the backup program obtains the block data in the second persistent volume by reading the block device in the backup container;
the backup program acquires backup object information through a dataSource field and a mapping triple C of a second persistent volume statement;
and packaging the backup object information and the block data into backup data and sending the backup data to a server.
5. A block-based persistent volume backup system, the system comprising:
the first target persistent volume statement acquiring and joining module is used for acquiring a first target persistent volume statement and joining the first target persistent volume statement into a first target persistent volume statement list;
an object information obtaining module, configured to traverse the first target persistent volume declaration list, and obtain backup object information, where the backup object information includes: the name, namespace, operating mode, persistent volume size, access mode, and storage class name of the first target persistent volume declaration;
the volume snapshot class acquiring and adding module is used for acquiring all volume snapshot classes and adding the volume snapshot classes into the volume snapshot class list;
the mapping triple creating and adding module is used for creating a mapping triple A according to a first target persistent volume statement list and adding the mapping triple A into the mapping triple list A, wherein the mapping triple A comprises a first target persistent volume statement field, a volume snapshot type field and a backup CSI snapshot field;
a mapping relation establishing and recording module, configured to establish a mapping relation between each first target persistent volume statement and the volume snapshot class according to the backup object information and the volume snapshot class list, and then record the mapping relation to a mapping triple a to form a mapping triple B and a mapping triple list B;
the CSI snapshot creating and filling module is used for traversing the first target persistent volume statement list, creating a backup CSI snapshot for each first target persistent volume statement, recording the backup CSI snapshot to the mapping triple B, and forming a mapping triple C and a mapping triple list C, wherein the mapping triple B is the mapping triple B where the currently traversed first target persistent volume statement is located;
a second persistent volume declaration creating and joining module, configured to create a second persistent volume declaration according to a backup CSI snapshot field of each mapping triplet C in the mapping triplet list C, and join the second persistent volume declaration into a second persistent volume declaration list, where the second persistent volume declaration binds a second persistent volume;
and the backup execution module is used for executing backup operation according to the second persistent volume statement list and the mapping triple list C.
6. The block-based persistent volume backup system according to claim 5, wherein the mapping relationship building record module comprises:
a storage class information obtaining unit, configured to obtain storage class information according to the backup object information, where the storage class information includes a provisioner field;
the volume snapshot type information acquisition unit is used for traversing the volume snapshot type list and acquiring the volume snapshot type information of each volume snapshot type, wherein the volume snapshot type information comprises a driver field;
the judging unit is used for respectively traversing a volume snapshot class list for each first target persistent volume statement in a first target persistent volume statement list, judging whether a provisioner field value of a storage class used by the first target persistent volume statement is the same as a driver field value of a current traversal volume snapshot class, and if so, establishing a mapping relation between the first target persistent volume statement and the current traversal volume snapshot class; if not, skipping the current traversal volume snapshot class;
and the mapping writing unit is used for writing the first target persistent volume statement and the volume snapshot class mapped by the first target persistent volume statement into the mapping triple A according to the mapping relation to form a mapping triple B and a mapping triple list B.
7. The block-based persistent volume backup system of claim 5 wherein the second persistent volume declaration create-join module comprises:
the second persistent volume declaration template building unit is used for traversing the mapping triple list C and building a second persistent volume declaration template for each mapping triple C;
a second persistent volume declaration template filling unit, configured to fill a second persistent volume declaration template according to the first target persistent volume declaration and the backup CSI snapshot recorded in the mapping triple C, where a dataSource field of the second persistent volume declaration template is a name of the backup CSI snapshot;
the second persistent volume declaration mode setting unit is used for adding a volumeMode field in the filled second persistent volume declaration template and setting the volumeMode field as Block;
and the second persistent volume declaration creating unit is used for creating a second persistent volume declaration by adding a second persistent volume declaration template of the volume mode field, and adding the second persistent volume declaration into a second persistent volume declaration list, wherein the second persistent volume declaration binds a second persistent volume.
8. The block-based persistent volume backup system according to claim 7, wherein the backup execution module comprises:
the backup image creating unit is used for creating a backup image, and the backup image comprises a backup program;
a backup container creating unit, configured to create a backup container for each second persistent volume statement in the second persistent volume statement list through the backup mirror, where the backup container refers to the second persistent volume statement by mounting a block device;
a block data obtaining unit, configured to obtain, by the backup program, block data in the second persistent volume by reading a block device inside the backup container;
a backup object information obtaining unit, configured to obtain, by the backup program, backup object information through a dataSource field of the second persistent volume declaration and the mapping triple C;
and the sending unit is used for packaging the backup object information and the block data into backup data and sending the backup data to the server.
9. A block-based persistent volume recovery method, characterized in that the block-based persistent volume backup method according to any one of claims 1 to 4 further comprises the steps of:
creating a recovery container to recover the persistent volume data;
the recovery container acquires backup data of a server side, and decapsulates the backup data into recovery block data and recovery object information;
creating a recovery persistent volume statement A according to the recovery object information, wherein the working mode of the recovery persistent volume statement A is Block, and the recovery persistent volume statement A is bound with the recovery persistent volume A;
the recovery container refers to a recovery persistent volume statement A in a mounting block device mode, and writes the recovery block data into a recovery persistent volume A;
judging whether the working mode in the recovery object information is a file system or not; if so, generating a recovery CSI snapshot for the recovery persistent volume statement A, deleting the recovery persistent volume statement A, creating a recovery persistent volume statement B according to the recovery CSI snapshot, and finishing recovery, wherein the working mode of the recovery persistent volume statement B is file system, and the recovery persistent volume B is bound; if not, the recovery is ended.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out a block-based persistent volume backup method according to any one of claims 1 to 4.
CN202210981605.8A 2022-08-16 2022-08-16 Block-based persistent volume backup method, system, storage medium and recovery method thereof Active CN115061856B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210981605.8A CN115061856B (en) 2022-08-16 2022-08-16 Block-based persistent volume backup method, system, storage medium and recovery method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210981605.8A CN115061856B (en) 2022-08-16 2022-08-16 Block-based persistent volume backup method, system, storage medium and recovery method thereof

Publications (2)

Publication Number Publication Date
CN115061856A true CN115061856A (en) 2022-09-16
CN115061856B CN115061856B (en) 2022-11-01

Family

ID=83208511

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210981605.8A Active CN115061856B (en) 2022-08-16 2022-08-16 Block-based persistent volume backup method, system, storage medium and recovery method thereof

Country Status (1)

Country Link
CN (1) CN115061856B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116166471A (en) * 2023-01-04 2023-05-26 安超云软件有限公司 Snapshot rollback method, containerized cloud platform and computer readable medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100306174A1 (en) * 2009-06-02 2010-12-02 Hitachi, Ltd. Method and apparatus for block based volume backup
CN102012947A (en) * 2010-12-16 2011-04-13 创新科存储技术有限公司 Method and system for online backup of database
CN104714864A (en) * 2015-03-20 2015-06-17 成都云祺科技有限公司 Intelligent computer data backup method
WO2018153251A1 (en) * 2017-02-21 2018-08-30 中兴通讯股份有限公司 Method for processing snapshots and distributed block storage system
CN108958976A (en) * 2018-07-02 2018-12-07 山东汇贸电子口岸有限公司 A kind of PV snapshot restores distributed data base data method and system
CN113849344A (en) * 2021-09-23 2021-12-28 苏州浪潮智能科技有限公司 Volume snapshot creating method and device and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100306174A1 (en) * 2009-06-02 2010-12-02 Hitachi, Ltd. Method and apparatus for block based volume backup
CN102012947A (en) * 2010-12-16 2011-04-13 创新科存储技术有限公司 Method and system for online backup of database
CN104714864A (en) * 2015-03-20 2015-06-17 成都云祺科技有限公司 Intelligent computer data backup method
WO2018153251A1 (en) * 2017-02-21 2018-08-30 中兴通讯股份有限公司 Method for processing snapshots and distributed block storage system
CN108958976A (en) * 2018-07-02 2018-12-07 山东汇贸电子口岸有限公司 A kind of PV snapshot restores distributed data base data method and system
CN113849344A (en) * 2021-09-23 2021-12-28 苏州浪潮智能科技有限公司 Volume snapshot creating method and device and storage medium

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
FOYER CLEMENT M: "Abstractions for Portable Data Management in Heterogeneous Memory Systems", 《HTTP://RESEARCH-INFORMATION.BRISTOL.AC.UK》 *
宋东平等: "面向Linux非逻辑卷块设备的快照系统", 《计算机系统应用》 *
是维C呀: "K8s--kubernetes持久化存储PV/PVC", 《HTTP://BLOG.CSDN.NET/WEXIN-55985097/ARTICLE/DETAILS/119084409》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116166471A (en) * 2023-01-04 2023-05-26 安超云软件有限公司 Snapshot rollback method, containerized cloud platform and computer readable medium
CN116166471B (en) * 2023-01-04 2024-03-22 安超云软件有限公司 Snapshot rollback method, containerized cloud platform and computer readable medium

Also Published As

Publication number Publication date
CN115061856B (en) 2022-11-01

Similar Documents

Publication Publication Date Title
US10353621B1 (en) File block addressing for backups
CN104216801B (en) The data copy method and system of a kind of Virtual environment
US11880280B2 (en) Variable number and size of put operations for storage backup
CN109522154B (en) Data recovery method and related equipment and system
US11042504B2 (en) Managing overwrites when archiving data in cloud/object storage
US9946609B2 (en) Managing multi-level backups into the cloud
CN107203331B (en) Method and device for writing data
CN115061856B (en) Block-based persistent volume backup method, system, storage medium and recovery method thereof
WO2013044794A1 (en) Terminal backup and recovery method
CN110413376A (en) A kind of method, equipment and the storage medium of Virtual Machine Manager USB device
CN113656149A (en) Application processing method and device and related equipment
CN108572888B (en) Disk snapshot creating method and disk snapshot creating device
CN112667246A (en) Application function extension method and device and electronic equipment
CN113157487A (en) Data recovery method and apparatus thereof
CN111158858A (en) Cloning method and device of virtual machine and computer readable storage medium
CN104951482A (en) Method and device for operating Sparse-format mirror image document
CN109144403B (en) Method and equipment for switching cloud disk modes
JP2017531892A (en) Improved apparatus and method for performing a snapshot of a block level storage device
US20170286463A1 (en) Mainframe index database to supplement a system catalog
CN115586872A (en) Container mirror image management method, device, equipment and storage medium
CA2930061A1 (en) Variants of files in a file system
CN111258503B (en) Management method and device of CIRROS file system
CN110837442B (en) KVM virtual machine backup system based on dirty data bitmap and network block equipment
CN114996236A (en) Data processing method, device and equipment for converged storage system and storage medium
CN114840307A (en) Container loading method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant