CN110879764B - Bitmap setting method, device and equipment and readable storage medium - Google Patents

Bitmap setting method, device and equipment and readable storage medium Download PDF

Info

Publication number
CN110879764B
CN110879764B CN201911113996.6A CN201911113996A CN110879764B CN 110879764 B CN110879764 B CN 110879764B CN 201911113996 A CN201911113996 A CN 201911113996A CN 110879764 B CN110879764 B CN 110879764B
Authority
CN
China
Prior art keywords
bitmap
value
space
threshold
current
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.)
Active
Application number
CN201911113996.6A
Other languages
Chinese (zh)
Other versions
CN110879764A (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.)
Inspur Beijing Electronic Information Industry Co Ltd
Original Assignee
Inspur Beijing Electronic Information Industry Co Ltd
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 Inspur Beijing Electronic Information Industry Co Ltd filed Critical Inspur Beijing Electronic Information Industry Co Ltd
Priority to CN201911113996.6A priority Critical patent/CN110879764B/en
Publication of CN110879764A publication Critical patent/CN110879764A/en
Application granted granted Critical
Publication of CN110879764B publication Critical patent/CN110879764B/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/1458Management of the backup or restore process
    • G06F11/1464Management of the backup or restore process for networked environments
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/065Replication mechanisms

Abstract

The invention discloses a bitmap setting method, which comprises the following steps: acquiring a used space value, a residual space value and a total space value of a current bitmap, and judging whether the residual space value is smaller than a first threshold value; if the remaining space value is smaller than a first threshold value, creating a first bitmap with the space value as a first value, migrating data in the current bitmap to the first bitmap, and releasing the current bitmap; if the residual space value is not smaller than the first threshold, judging whether the residual space value is larger than a second threshold; if the remaining space value is larger than a second threshold value, creating a second bitmap with the space value being a second value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap; the method can automatically adjust the size of the bitmap space without manually adjusting the size of the bitmap space by an administrator; in addition, the invention also provides a bitmap setting device, equipment and a computer readable storage medium, and the bitmap setting device, the equipment and the computer readable storage medium also have the beneficial effects.

Description

Bitmap setting method, device and equipment and readable storage medium
Technical Field
The present invention relates to the field of storage system technologies, and in particular, to a bitmap setting method, a bitmap setting apparatus, a bitmap setting device, and a computer-readable storage medium.
Background
Remote copy relationships define the relationship between volumes, typically one volume designated as a primary volume and the other as a secondary volume. The host application writes the data to the primary volume and does not run I/O operations on the secondary volume. Although data is written to only one volume, the system will copy the data to another volume (secondary volume). At disaster recovery, a copy on another volume may be used as a backup.
In current implementations of storage systems, the remote copy relationship between the primary and secondary volumes of remote copy is managed by bitmaps, which default to 20M, and can support 40T of remote copy storage capacity. The size of the bitmap space cannot be automatically adjusted, and when the bitmap space is exhausted or surplus, the bitmap space can be manually adjusted only by an administrator, so that the efficiency is very low.
Therefore, how to solve the problem of low efficiency of the existing bitmap setting method is a technical problem to be solved by those skilled in the art.
Disclosure of Invention
In view of the above, the present invention provides a bitmap setting method, a bitmap setting device, and a computer readable storage medium, which solve the problem of low efficiency of the existing bitmap setting method.
In order to solve the above technical problem, the present invention provides a bitmap setting method, including:
acquiring a used space value, a residual space value and a total space value of a current bitmap, and judging whether the residual space value is smaller than a first threshold value or not;
if the residual space value is smaller than the first threshold value, creating a first bitmap with the space value as a first value, migrating data in the current bitmap to the first bitmap, and releasing the current bitmap; wherein the first value is greater than the total space value;
if the residual space value is not smaller than the first threshold, judging whether the residual space value is larger than a second threshold; wherein the second threshold is greater than the first threshold;
if the residual space value is larger than the second threshold value, creating a second bitmap with the space value as a second value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
Optionally, the method further includes:
when a creation instruction is received, analyzing the creation instruction to obtain main volume information and auxiliary volume information;
and creating a remote copy relationship by using the primary volume information and the secondary volume information, and adding the remote copy relationship into the current bitmap.
Optionally, the method further includes:
when a deleting instruction is received, analyzing the deleting instruction, and determining a first remote copying relation appointed by the deleting instruction;
deleting the first remote copy relationship in the current bitmap, and updating the current bitmap.
Optionally, the method further includes:
when a disaster recovery signal aiming at a target primary volume is detected, acquiring a target remote copy relation corresponding to the disaster recovery signal by using the current bitmap;
and determining a target auxiliary volume by using the target remote copy relationship, and executing disaster recovery operation by using the target auxiliary volume.
Optionally, before the creating the first bitmap with the spatial value being the first value, the method further includes:
and acquiring a first preset numerical value, and adding the first preset numerical value and the total space numerical value to obtain the first numerical value.
Optionally, before the creating the second bitmap with the spatial value being the second value, the method further includes:
and obtaining the first preset numerical value, and subtracting the first preset numerical value from the total space numerical value to obtain the second numerical value.
The present invention also provides a bitmap setting apparatus, including:
the first judgment module is used for acquiring a used space value, a residual space value and a total space value of the current bitmap and judging whether the residual space value is smaller than a first threshold value or not;
a first updating module, configured to create a first bitmap with a space size of a first value if the remaining space value is smaller than the first threshold, migrate data in the current bitmap to the first bitmap, and release the current bitmap; wherein the first value is greater than the total space value;
the second judgment module is used for judging whether the residual space value is larger than a second threshold value or not if the residual space value is not smaller than the first threshold value; wherein the second threshold is greater than the first threshold;
a second updating module, configured to create a second bitmap with a space size of a second value if the remaining space value is greater than the second threshold, migrate data in the current bitmap to the second bitmap, and release the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
Optionally, the method further includes:
the first analysis module is used for analyzing the creation instruction when the creation instruction is received to obtain the main volume information and the auxiliary volume information;
and the creating module is used for creating a remote copying relationship by utilizing the primary volume information and the secondary volume information and adding the remote copying relationship into the current bitmap.
The present invention also provides a bitmap setting apparatus comprising a memory and a processor, wherein:
the memory is used for storing a computer program;
the processor is configured to execute the computer program to implement the bitmap setting method.
The present invention also provides a computer-readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the bitmap setting method described above.
The bitmap setting method provided by the invention obtains the used space value, the residual space value and the total space value of the current bitmap, and judges whether the residual space value is smaller than a first threshold value. If the remaining space value is smaller than a first threshold value, creating a first bitmap with the space value as a first value, migrating data in the current bitmap to the first bitmap, and releasing the current bitmap; wherein the first value is greater than the total space value. If the remaining space value is not smaller than the first threshold, whether the remaining space value is larger than a second threshold or not is judged, wherein the second threshold is larger than the first threshold. If the remaining space value is larger than a second threshold value, creating a second bitmap with the space value as a second value, migrating data in the current bitmap to the second bitmap, and releasing the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
It can be seen that the method determines the subsequent steps through the size relationship between the remaining space value of the current bitmap and the first threshold value and the second threshold value, when the remaining space value is smaller than the first threshold value, it indicates that the remaining space of the current bitmap is smaller, and the remaining space of the bitmap needs to be enlarged, so that a first bitmap is created, the size of the first bitmap is larger than the total space value of the current bitmap, data in the current bitmap is migrated to the first bitmap, and the current bitmap is released; and when the residual space value is larger than a second threshold value, indicating that the residual space of the current bitmap is larger and the residual space of the bitmap needs to be reduced, then creating a second bitmap, wherein the size of the second bitmap is larger than the used space value and is smaller than the total space value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap. The method can automatically adjust the size of the bitmap space without manually adjusting the size of the bitmap space by an administrator, and solves the problem of low efficiency of the existing bitmap space setting method.
In addition, the invention also provides a bitmap setting device, bitmap setting equipment and a computer readable storage medium, and the bitmap setting device, the bitmap setting equipment and the computer readable storage medium also have the beneficial effects.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a bitmap setting method according to an embodiment of the present invention;
fig. 2 is a flow chart of daily business processing according to an embodiment of the present invention;
figure 3 is a flow chart of disaster recovery provided by an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a bitmap setting apparatus according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a bitmap setting device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, fig. 1 is a flowchart illustrating a bitmap setting method according to an embodiment of the present invention. The method comprises the following steps:
s101: and acquiring the used space value, the residual space value and the total space value of the current bitmap.
The bitmap is used to store remote copy relationships, which may be a list or a special storage area. Since the bitmap needs to be stored in a computer or device, the method can be performed by using a device storing the bitmap. The remote copy relationship is information for recording the relationship between the primary volume and the secondary volume so as to perform a disaster recovery operation to recover data when the primary volume fails or the primary volume information is lost. The attribute information of the current bitmap is the bitmap being used, and may include the total space value of the current bitmap, i.e. the size of the total storage space of the current bitmap, and may also include the used space data of the current bitmap, i.e. the size of the space occupied by the remote copy relationship in the current bitmap. The remaining space value may be recorded in the attribute information of the current bitmap as well, or may be calculated using the used space value and the total space value of the current bitmap. After the used space value, the remaining space value, and the total space value of the current bitmap are obtained, step S102 may be entered.
It should be noted that, the embodiment does not limit the timing for executing the acquisition of the used space value, the remaining space value, and the total space value of the current bitmap, and for example, the acquisition operation may be executed according to a preset period; or may perform the fetch operation upon receipt of the fetch instruction. Further, when receiving an acquisition instruction to execute an acquisition operation, the acquisition instruction can be generated after a daily service is executed, wherein the daily service comprises addition of a remote copy relationship, deletion of the remote copy relationship, query of the remote copy relationship and the like; or the acquisition instruction may be generated when a preset number of daily transactions have been performed. Preferably, in order to set the bitmap in time, the operation of obtaining the used space value, the remaining space value and the total space value of the current bitmap may be performed once after each execution of the daily service.
S102: and judging whether the residual space value is smaller than a first threshold value.
The first threshold is used to determine whether the current bitmap needs to be expanded, and the specific size of the first threshold is not limited in this embodiment, for example, the first threshold may be set to 10 Mb. When the size of the remaining space of the current bitmap is smaller than the first threshold, it indicates that the remaining space of the current bitmap is insufficient, and the space of the bitmap needs to be expanded, so the process may proceed to step S103; when the size of the remaining space of the current bitmap is not smaller than the first threshold, it means that the remaining space of the bitmap does not need to be enlarged, and therefore, the process may proceed to step S104.
S103: and creating a first bitmap with a space value as a first value, migrating data in the current bitmap to the first bitmap, and releasing the current bitmap.
When the remaining space of the current bitmap is small, in order to prevent the bitmap from having insufficient remaining space to cause a failure in creating a remote copy relationship or cause other failures, the space of the bitmap needs to be enlarged. Specifically, a first bitmap with a space value as a first value is created, where the first value is greater than the total space value of the current bitmap, that is, the total space size of the first bitmap is greater than the total space size of the current bitmap. After the first bitmap is successfully created, the data in the current bitmap is migrated to the first bitmap, and the specific migration process may refer to related technologies, which is not limited in this embodiment. And after the data migration is finished, releasing the current bitmap, and replacing the work of the current bitmap with the first bitmap, namely determining the first bitmap as the current bitmap to expand the bitmap space.
S104: and judging whether the residual space value is larger than a second threshold value.
When the remaining space value of the current bitmap is not less than the first threshold, it indicates that the current bitmap does not need to be expanded, and therefore, whether the remaining space value of the current bitmap is greater than the second threshold is judged. It should be noted that the second threshold is greater than the first threshold, and is used to determine whether the bitmap needs to be reduced. When the remaining space value is greater than the second threshold, step S105 may be entered; when the value of the remaining space is not greater than the second threshold, it indicates that the size of the remaining space of the current bitmap is in a relatively suitable state, and the current bitmap does not need to be expanded or reduced, so step S106 may be entered: no operation, i.e., no operation is performed.
S105: and creating a second bitmap with a space value as a second value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap.
When the value of the remaining space is greater than the second threshold, it indicates that the remaining space of the current bitmap is too large, and in order to prevent the memory resource waste caused by the too large bitmap, the bitmap space needs to be reduced. Specifically, a second bitmap with a space value of a second value may be created, where the second value is smaller than the total space value of the current bitmap and larger than the used space value of the current bitmap. And when the second bitmap is successfully created, migrating the data in the current bitmap to the second bitmap, releasing the current bitmap, and replacing the work of the current bitmap with the second bitmap, namely determining the second bitmap as the current bitmap, so as to reduce the bitmap space.
By applying the bitmap setting method provided by the embodiment of the invention, the subsequent steps are determined according to the size relationship between the remaining space value of the current bitmap and the first threshold value and the second threshold value, when the remaining space value is smaller than the first threshold value, the remaining space of the current bitmap is smaller, and the remaining space of the bitmap needs to be enlarged, so that a first bitmap is created, the size of the first bitmap is larger than the total space value of the current bitmap, data in the current bitmap is migrated to the first bitmap, and the current bitmap is released; and when the residual space value is larger than a second threshold value, indicating that the residual space of the current bitmap is larger and the residual space of the bitmap needs to be reduced, then creating a second bitmap, wherein the size of the second bitmap is larger than the used space value and is smaller than the total space value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap. The method can automatically adjust the size of the bitmap space without manually adjusting the size of the bitmap space by an administrator, and solves the problem of low efficiency of the existing bitmap space setting method.
Based on the above embodiments, the embodiments of the present invention will explain a processing flow of daily business. Referring to fig. 2, fig. 2 is a flowchart of a daily business process according to an embodiment of the present invention, including:
s201: and when the creation instruction is received, analyzing the creation instruction to obtain the main volume information and the auxiliary volume information.
The creation instruction is used for creating a remote copy relationship, and the specific form is not limited. When a creation instruction is received, the creation instruction is analyzed to obtain the main volume information and the auxiliary volume information specified by the creation instruction. The primary volume information is information of a volume in which protected data is stored, and the secondary volume information is information of a backup volume serving as a primary volume. The primary volume information and the secondary volume information may be address information of the primary volume and the secondary volume, or may be number or name information of the primary volume and the secondary volume, or the like, as long as the identities of the primary volume and the secondary volume can be determined.
S202: and creating a remote copy relationship by using the primary volume information and the secondary volume information, and adding the remote copy relationship into the current bitmap.
And creating a remote copy relationship by using the primary volume information and the secondary volume information, and adding the remote copy relationship into the current bitmap. Further, in order to set the bitmap in time, i.e., adjust the size of the bitmap space in time, after adding the remote copy relationship to the current bitmap, step S101 may be performed.
S203: when a deleting instruction is received, the deleting instruction is analyzed, and a first remote copying relation specified by the deleting instruction is determined.
And the deleting instruction is used for deleting the specified remote copying relation, and the deleting instruction is analyzed when the deleting instruction is received, so that the first remote copying relation specified by the deleting instruction is determined. Specifically, the deletion instruction may include a number of the first remote copy relationship, which is used to specify the first remote copy relationship; or may include primary volume information or secondary volume information in the first remote copy relationship, the first remote copy relationship being determined using the primary volume information and the secondary volume information in the delete instruction.
S204: and deleting the first remote copy relationship in the current bitmap, and updating the current bitmap.
After the first remote copy relationship is determined, the first remote copy relationship is deleted from the current bitmap, and the current bitmap is updated, specifically, the attribute corresponding to the current bitmap may be updated.
It should be noted that the execution sequence of step S201 and step S203 is not limited, and when the creation instruction is received, step S201 and step S202 may be executed; upon receiving the deletion instruction, step S203 and step S204 may be executed.
Based on the above embodiments of the invention, a specific disaster recovery process will be described in the embodiments of the invention, please refer to fig. 3, where fig. 3 is a disaster recovery flow chart provided by the embodiments of the invention, including:
s301: and when a disaster recovery signal aiming at the target primary volume is detected, acquiring a target remote copy relation corresponding to the disaster recovery signal by using the current bitmap.
The disaster recovery signal is used for recovering a primary volume which has failed or has lost data due to other reasons, and when the disaster recovery signal of the target primary volume of the fleet is detected, the data loss in the target primary volume is indicated. Therefore, the target remote copy relationship corresponding to the disaster recovery signal is obtained by using the current bitmap, that is, the target remote copy relationship corresponding to the target primary volume is determined. Specifically, the disaster recovery signal may include primary volume information of the target primary volume, and the target remote copy relationship corresponding to the disaster recovery signal may be determined by using the primary volume information of the target primary volume; or the disaster recovery signal may include information such as the number of the target remote copy relationship, and the target remote copy relationship corresponding to the disaster recovery signal may be determined by using the information. As long as the information in the disaster recovery signal matches the identity information of the remote copy relationship stored in the current bitmap.
S302: and determining a target auxiliary volume by using the target remote copy relationship, and executing disaster recovery operation by using the target auxiliary volume.
And after the target remote copy relationship is determined, determining a target auxiliary volume by using the target remote copy relationship, and executing disaster recovery operation by using the target auxiliary volume. The details and steps of the disaster recovery operation can refer to the related art, and the description of this embodiment is not repeated herein.
Based on the foregoing embodiment of the present invention, in order to make the bitmap remaining space after each bitmap expansion or reduction meet the requirement, and avoid situations that the bitmap space needs to be reduced immediately after the bitmap space is expanded, and the like, a specific method for determining a first value and a second value will be described in the embodiment of the present invention, specifically, before creating a first bitmap whose space value is the first value, the method may further include:
and acquiring a first preset numerical value, and adding the first preset numerical value and the total space numerical value to obtain a first numerical value.
The first preset value may be set in advance to limit the size of each bitmap space expansion or reduction. It should be noted that the magnitude of the first preset value is related to the first threshold and the second threshold, and specifically, the magnitude of the first preset value cannot be greater than the difference between the second threshold and the first threshold. When the bitmap space is expanded, a value obtained by adding the first preset numerical value and the total space numerical value is the first numerical value.
Correspondingly, before creating the second bitmap with the spatial value being the second value, the method may further include:
and obtaining a first preset value, and subtracting the first preset value by using the total space value to obtain a second value.
In the following, the bitmap setting apparatus provided in the embodiment of the present invention is introduced, and the bitmap setting apparatus described below and the bitmap setting method described above may be referred to correspondingly.
Referring to fig. 4, fig. 4 is a schematic structural diagram of a bitmap setting apparatus according to an embodiment of the present invention, including:
a first determining module 410, configured to obtain a used space value, a remaining space value, and a total space value of the current bitmap, and determine whether the remaining space value is smaller than a first threshold;
a first updating module 420, configured to create a first bitmap with a space size being a first value if the remaining space value is smaller than a first threshold, migrate data in the current bitmap to the first bitmap, and release the current bitmap; wherein the first value is greater than the total space value;
a second determining module 430, configured to determine whether the remaining space value is greater than a second threshold value if the remaining space value is not less than the first threshold value; wherein the second threshold is greater than the first threshold;
a second updating module 440, configured to create a second bitmap with a space size of a second numerical value if the remaining space numerical value is greater than a second threshold, migrate data in the current bitmap to the second bitmap, and release the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
Optionally, the method further includes:
the first analysis module is used for analyzing the creation instruction when the creation instruction is received to obtain the main volume information and the auxiliary volume information;
and the creating module is used for creating a remote copying relation by utilizing the primary volume information and the secondary volume information and adding the remote copying relation into the current bitmap.
Optionally, the method further includes:
the second analysis module is used for analyzing the deletion instruction when the deletion instruction is received and determining a first remote copying relation appointed by the deletion instruction;
and the deleting module is used for deleting the first remote copying relation in the current bitmap and updating the current bitmap.
Optionally, the method further includes:
the determining module is used for acquiring a target remote copy relationship corresponding to the disaster recovery signal by using a current bitmap when the disaster recovery signal aiming at the target primary volume is detected;
the recovery module determines a target secondary volume using the target remote copy relationship and performs a disaster recovery operation using the target secondary volume.
Optionally, the method further includes:
the first calculation module is used for acquiring a first preset value and obtaining the first value by adding the first preset value and the total space value.
Optionally, the method further includes:
and the second calculation module is used for acquiring the first preset value and subtracting the first preset value from the total space value to obtain a second value.
In the following, the bitmap setting device provided by the embodiment of the present invention is introduced, and the bitmap setting device described below and the bitmap setting method described above may be referred to correspondingly.
Referring to fig. 5, fig. 5 is a schematic structural diagram of a bitmap setting device according to an embodiment of the present invention, where the bitmap setting device includes a memory and a processor, where:
a memory 510 for storing a computer program;
a processor 520 for executing a computer program to implement the bitmap setting method described above.
In the following, a computer-readable storage medium provided by an embodiment of the present invention is introduced, and the computer-readable storage medium described below and the bitmap setting method described above may be referred to correspondingly.
The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the bitmap setting method described above.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Finally, it should also be noted that, herein, relationships such as first and second, etc., are intended only to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
The present invention provides a bitmap setting method, a bitmap setting device, and a computer readable storage medium, which are described in detail above, and a specific example is applied in this document to explain the principle and the implementation of the present invention, and the description of the above embodiment is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (10)

1. A bitmap setting method, comprising:
acquiring a used space value, a residual space value and a total space value of a current bitmap, and judging whether the residual space value is smaller than a first threshold value or not;
if the residual space value is smaller than the first threshold value, creating a first bitmap with the space value as a first value, migrating data in the current bitmap to the first bitmap, and releasing the current bitmap; wherein the first value is greater than the total space value;
if the residual space value is not smaller than the first threshold, judging whether the residual space value is larger than a second threshold; wherein the second threshold is greater than the first threshold;
if the residual space value is larger than the second threshold value, creating a second bitmap with the space value as a second value, migrating the data in the current bitmap to the second bitmap, and releasing the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
2. The bitmap setting method according to claim 1, characterized by further comprising:
when a creation instruction is received, analyzing the creation instruction to obtain main volume information and auxiliary volume information;
and creating a remote copy relationship by using the primary volume information and the secondary volume information, and adding the remote copy relationship into the current bitmap.
3. The bitmap setting method according to claim 1, characterized by further comprising:
when a deleting instruction is received, analyzing the deleting instruction, and determining a first remote copying relation appointed by the deleting instruction;
deleting the first remote copy relationship in the current bitmap, and updating the current bitmap.
4. The bitmap setting method according to claim 1, characterized by further comprising:
when a disaster recovery signal aiming at a target primary volume is detected, acquiring a target remote copy relation corresponding to the disaster recovery signal by using the current bitmap;
and determining a target auxiliary volume by using the target remote copy relationship, and executing disaster recovery operation by using the target auxiliary volume.
5. The bitmap setting method according to claim 1, further comprising, before the creating of the first bitmap whose spatial value is the first value:
and acquiring a first preset numerical value, and adding the first preset numerical value and the total space numerical value to obtain the first numerical value.
6. The bitmap setting method according to claim 5, further comprising, before the creating of the second bitmap whose spatial value is the second value:
and obtaining the first preset numerical value, and subtracting the first preset numerical value from the total space numerical value to obtain the second numerical value.
7. A bitmap setting apparatus, comprising:
the first judgment module is used for acquiring a used space value, a residual space value and a total space value of the current bitmap and judging whether the residual space value is smaller than a first threshold value or not;
a first updating module, configured to create a first bitmap with a space size of a first value if the remaining space value is smaller than the first threshold, migrate data in the current bitmap to the first bitmap, and release the current bitmap; wherein the first value is greater than the total space value;
the second judgment module is used for judging whether the residual space value is larger than a second threshold value or not if the residual space value is not smaller than the first threshold value; wherein the second threshold is greater than the first threshold;
a second updating module, configured to create a second bitmap with a space size of a second value if the remaining space value is greater than the second threshold, migrate data in the current bitmap to the second bitmap, and release the current bitmap; wherein the second value is less than the total space value and greater than the used space value.
8. The bitmap setting apparatus according to claim 7, characterized by further comprising:
the first analysis module is used for analyzing the creation instruction when the creation instruction is received to obtain the main volume information and the auxiliary volume information;
and the creating module is used for creating a remote copying relationship by utilizing the primary volume information and the secondary volume information and adding the remote copying relationship into the current bitmap.
9. A bitmap setting apparatus comprising a memory and a processor, wherein:
the memory is used for storing a computer program;
the processor for executing the computer program to implement the bitmap setting method of any one of claims 1 to 6.
10. A computer-readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the bitmap setting method according to any one of claims 1 to 6.
CN201911113996.6A 2019-11-14 2019-11-14 Bitmap setting method, device and equipment and readable storage medium Active CN110879764B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911113996.6A CN110879764B (en) 2019-11-14 2019-11-14 Bitmap setting method, device and equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911113996.6A CN110879764B (en) 2019-11-14 2019-11-14 Bitmap setting method, device and equipment and readable storage medium

Publications (2)

Publication Number Publication Date
CN110879764A CN110879764A (en) 2020-03-13
CN110879764B true CN110879764B (en) 2022-04-22

Family

ID=69729650

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911113996.6A Active CN110879764B (en) 2019-11-14 2019-11-14 Bitmap setting method, device and equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN110879764B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114968124A (en) * 2022-06-28 2022-08-30 深圳前海微众银行股份有限公司 Data storage method, server and storage medium
CN115454997B (en) * 2022-08-16 2024-02-02 苏州浪潮智能科技有限公司 Bitmap management method, bitmap management device, computer equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104572113A (en) * 2015-01-21 2015-04-29 深圳市中兴移动通信有限公司 Automatic storage space arranging method and mobile terminal
CN107590283A (en) * 2017-09-29 2018-01-16 浙江大华技术股份有限公司 A kind of file recovery method, device, server and computer-readable recording medium
CN109324929A (en) * 2018-09-17 2019-02-12 郑州云海信息技术有限公司 A kind of snapshot creation method, device, equipment and readable storage medium storing program for executing
CN109783494A (en) * 2018-12-29 2019-05-21 深圳云天励飞技术有限公司 Date storage method and relevant apparatus
CN110018797A (en) * 2019-04-11 2019-07-16 苏州浪潮智能科技有限公司 A kind of data migration method, device, equipment and readable storage medium storing program for executing
CN110377529A (en) * 2019-06-27 2019-10-25 苏州浪潮智能科技有限公司 A kind of method, apparatus and equipment of full flash memory storage system data management

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
MX2011010772A (en) * 2009-04-14 2011-10-28 Samsung Electronics Co Ltd Information storage medium, recording / playback apparatus, and recording / playback method.
KR101636875B1 (en) * 2009-10-26 2016-07-06 삼성전자주식회사 Information storage medium, recording reproducing apparatus, recording reproducing method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104572113A (en) * 2015-01-21 2015-04-29 深圳市中兴移动通信有限公司 Automatic storage space arranging method and mobile terminal
CN107590283A (en) * 2017-09-29 2018-01-16 浙江大华技术股份有限公司 A kind of file recovery method, device, server and computer-readable recording medium
CN109324929A (en) * 2018-09-17 2019-02-12 郑州云海信息技术有限公司 A kind of snapshot creation method, device, equipment and readable storage medium storing program for executing
CN109783494A (en) * 2018-12-29 2019-05-21 深圳云天励飞技术有限公司 Date storage method and relevant apparatus
CN110018797A (en) * 2019-04-11 2019-07-16 苏州浪潮智能科技有限公司 A kind of data migration method, device, equipment and readable storage medium storing program for executing
CN110377529A (en) * 2019-06-27 2019-10-25 苏州浪潮智能科技有限公司 A kind of method, apparatus and equipment of full flash memory storage system data management

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
一种采用双向有序链表存储的动态编码位图索引方法;王书海 等;《石家庄铁道大学学报》;20150630;第28卷(第2期);第95-101页 *
基于Hadoop的位图索引的空间和效率研究;薛胜军 等;《科学技术与工程》;20150930;第15卷(第25期);第161-168页 *
面向科学数据的分布式位图索引关键技术及应用;种冠鹏;《中国优秀硕士学位论文全文数据库-信息科技辑》;20180415;第2018年卷(第4期);第I138-1940页 *

Also Published As

Publication number Publication date
CN110879764A (en) 2020-03-13

Similar Documents

Publication Publication Date Title
CN107643880B (en) File data migration method and device based on distributed file system
CN106354884B (en) Data object deleting method and device based on distributed file system
CN109032507B (en) Method, system and related assembly for generating source volume storage snapshot
EP3474143B1 (en) Method and apparatus for incremental recovery of data
CN110543386B (en) Data storage method, device, equipment and storage medium
CN110879764B (en) Bitmap setting method, device and equipment and readable storage medium
CN109614045B (en) Metadata dropping method and device and related equipment
CN107577558B (en) Cloud storage snapshot method and device
CN113467993A (en) Method, system, equipment and storage medium for restoring cloud platform resources
CN111382011B (en) File data access method and device and computer readable storage medium
CN106096447A (en) A kind of document protection method and device
CN110795282B (en) Data rollback method, device, equipment and storage medium
CN107329699B (en) Erasure rewriting method and system
WO2018177193A1 (en) Software upgrade method and device
CN103729301B (en) Data processing method and device
CN108205559B (en) Data management method and equipment thereof
CN110658993A (en) Snapshot rollback method, device, equipment and storage medium
CN110750521A (en) Data migration method, device and equipment and computer readable storage medium
CN111984472B (en) Data snapshot method, device and related equipment
CN110908610A (en) Volume recovery station cleaning method, device, equipment and readable storage medium
CN114138566B (en) Data storage method and device of virtual machine, virtual machine and storage medium
CN111125012A (en) Snapshot generation method, device and equipment and readable storage medium
CN112269679B (en) Database persistence method, system, equipment and storage medium of cloud platform
CN110795043B (en) Distributed storage block zeroing method and device, electronic equipment and storage medium
CN110767258B (en) Data erasure command test method and related device

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