Dual-active volume expansion method, system, terminal and storage medium in abnormal state

By identifying offline sites in a dual-active storage cluster, terminating the dual-active relationship, and converting them to ordinary volumes for expansion, the problem of offline sites being unable to expand in a dual-active storage cluster is solved, enabling rapid online expansion and improved data security.

CN114840365BActive Publication Date: 2026-05-29INSPUR SUZHOU INTELLIGENT TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR SUZHOU INTELLIGENT TECH CO LTD
Filing Date
2022-05-20
Publication Date
2026-05-29

Smart Images

  • Figure CN114840365B_ABST
    Figure CN114840365B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of dual-active storage, and particularly provides a dual-active volume expansion method, system, terminal and storage medium in an abnormal state, which comprises the following steps: confirming that one offline site exists in a dual-active storage system; canceling the dual-active relationship of two sites in the dual-active storage system, and synchronously expanding the volume of a normal site; taking the normal site as a local site to restore the dual-active relationship between the normal site and the offline site, and creating a volume for the offline site based on the volume capacity of the local site; and starting data synchronization from the local site to a slave site after the offline site is online again. The application is applied to the dual-active storage system, can realize rapid online expansion of the dual-active volume of the dual-active storage system in an abnormal state, and improves the applicability of the dual-active storage system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of dual-active storage technology, specifically relating to a method, system, terminal, and storage medium for expanding a dual-active volume under abnormal conditions. Background Technology

[0002] A dual-active storage system refers to two centralized storage devices that serve as backups for each other and are both operational. If one storage device fails, the other can take over the service, ensuring the continuity of front-end user services and preventing data loss. A dual-active volume is a volume within a dual-active storage system, including the local primary volume, local secondary volume, slave primary volume, and slave secondary volume. The local and slave primary volumes are visible in the storage management interface and are mirror images of each other. The local and slave secondary volumes reside within the storage system and are modified versions of their respective primary volumes, not publicly visible. When the two primary volumes are out of sync, changed data is written to the modified volume, which then synchronizes it to the other side for consistency. When the two primary volumes are synchronized, changed data is written directly to the primary volumes and does not enter the secondary volumes.

[0003] Because dual-active volumes contain data bitmap information, this information needs to be updated and generated synchronously during expansion. If the bitmap information is incorrect, it will result in data loss for users. Therefore, most vendors do not recommend expanding dual-active volumes. The existing technical solution involves first expanding the slave primary and secondary volumes, updating the bitmap information synchronously during expansion. Then, the local secondary volume is expanded, updating the bitmap information again. Finally, the local primary volume is expanded, and the bitmap information from the local secondary volume is used as a reference to synchronously update the local primary volume, achieving online expansion of dual-active volumes in a "slave primary / secondary volume - local secondary volume - local primary volume" manner.

[0004] This expansion method requires that at least one storage node in each site of the active-active storage cluster be active. If one site in the active-active storage cluster is offline, that is, both storage nodes in that site are offline, online expansion of the active-active volume cannot be performed. This is because when a site is offline, it is impossible to read information from the disk, and the site may even have lost power, causing the disk to malfunction. Summary of the Invention

[0005] To address the problem that existing technologies cannot expand the capacity of a dual-active storage system when a site is offline, this invention provides a method, system, terminal, and storage medium for expanding a dual-active volume in an abnormal state, in order to solve the aforementioned technical problem.

[0006] In a first aspect, the present invention provides a method for expanding a dual-active volume under abnormal conditions, comprising:

[0007] It has been confirmed that there is an offline site in the dual-active storage system;

[0008] Remove the active-active relationship between the two sites in the active-active storage system and synchronously expand the volume of the normal site;

[0009] The active-active relationship between the normal site and the offline site is restored by using the normal site as the local site, and a volume is created for the offline site based on the volume capacity of the local site.

[0010] Enable data synchronization from the local site to the slave site after the offline site is brought back online.

[0011] Furthermore, it was confirmed that there is an offline site in the dual-active storage system, including:

[0012] Upon receiving the expansion command, the status of each node in the dual-active storage system is collected;

[0013] If there are 2 or 3 nodes in an offline state, then determine whether there is a site that includes two offline nodes:

[0014] If so, the site is determined to be an offline site.

[0015] Furthermore, the active-active relationship between the two sites in the active-active storage system is terminated, and the volumes of the normal site are synchronously expanded, including:

[0016] Treat the offline site as a slave site, and delete the slave primary volume and slave secondary volume of the slave site;

[0017] In a dual-active storage system, the normal site is designated as the local site, and the local primary volume and local secondary volume of the local site are changed into independent ordinary volumes.

[0018] The capacity of the modified local main volume and local auxiliary volume will be expanded simultaneously.

[0019] Furthermore, the normal site in the dual-active storage system is designated as the local site, and the local primary volume and local secondary volume of the local site are changed into independent ordinary volumes, including:

[0020] Disconnect the main volume and auxiliary volume of this terminal;

[0021] Delete the bitmap information of this site.

[0022] Furthermore, the modified local main volume and local auxiliary volume will be simultaneously expanded, including:

[0023] The normal volume expansion command is invoked to expand the capacity of the modified local main volume and local auxiliary volume to the target capacity, and the expanded local main volume and local auxiliary volume have the same capacity.

[0024] Furthermore, the active-active relationship between the normal site and the offline site is restored using the normal site as the local site, and a volume is created for the offline site based on the volume capacity of the local site, including:

[0025] Using an offline site as a slave node, a volume creation command is invoked to create a slave master volume for the slave site, and the capacity of the slave master volume is the same as the capacity of the volume of the local site.

[0026] A secondary volume belonging to the slave site is created based on the primary volume, and the secondary volume has the same capacity as the primary volume.

[0027] By specifying a dual-active domain, a dual-active relationship is established between two volumes at the local site and two volumes at the slave site.

[0028] Furthermore, after the offline site comes back online, enable data synchronization from the local site to the slave site, including:

[0029] After establishing an active-active relationship between the local and slave sites, the data in the local primary volume is copied to the slave primary volume.

[0030] After confirming that the offline site is back online, copy the bitmap information regenerated on the local site after the expansion to the slave site.

[0031] Secondly, the present invention provides a dual-active-volume expansion system for abnormal states, comprising:

[0032] The anomaly confirmation unit is used to confirm the existence of an offline site in the dual-active storage system;

[0033] The dual-active deactivation unit is used to deactivate the dual-active relationship between two sites in a dual-active storage system and to synchronously expand the volume of the normal site.

[0034] The dual-active recovery unit is used to restore the dual-active relationship between the normal site and the offline site by using the normal site as the local site, and to create a volume for the offline site based on the volume capacity of the local site.

[0035] The data synchronization unit is used to initiate data synchronization between the local site and the slave site after the offline site is brought back online.

[0036] Furthermore, the anomaly determination unit is specifically used for:

[0037] Upon receiving the expansion command, the status of each node in the dual-active storage system is collected;

[0038] If there are 2 or 3 nodes in an offline state, then determine whether there is a site that includes two offline nodes:

[0039] If so, the site is determined to be an offline site.

[0040] Furthermore, the dual-active deactivation unit includes:

[0041] The slave deletion module is used to treat the offline site as a slave site and delete the slave primary volume and slave secondary volume of the slave site;

[0042] The local change module is used to treat a normal site in a dual-active storage system as the local site and change the local primary volume and local secondary volume of the local site into independent ordinary volumes.

[0043] The local expansion module is used to synchronously expand the capacity of the modified local main volume and local auxiliary volume.

[0044] Furthermore, the local modification module is specifically used for:

[0045] Disconnect the main volume and auxiliary volume of this terminal;

[0046] Delete the bitmap information of this site.

[0047] Furthermore, the local expansion module is specifically used for:

[0048] The normal volume expansion command is invoked to expand the capacity of the modified local main volume and local auxiliary volume to the target capacity, and the expanded local main volume and local auxiliary volume have the same capacity.

[0049] Furthermore, the dual-active recovery unit is specifically used for:

[0050] Using an offline site as a slave node, a volume creation command is invoked to create a slave master volume for the slave site, and the capacity of the slave master volume is the same as the capacity of the volume of the local site.

[0051] A secondary volume belonging to the slave site is created based on the primary volume, and the secondary volume has the same capacity as the primary volume.

[0052] By specifying a dual-active domain, a dual-active relationship is established between two volumes at the local site and two volumes at the slave site.

[0053] Furthermore, the data synchronization unit is specifically used for:

[0054] After establishing an active-active relationship between the local and slave sites, the data in the local primary volume is copied to the slave primary volume.

[0055] After confirming that the offline site is back online, copy the bitmap information regenerated on the local site after the expansion to the slave site.

[0056] Thirdly, a terminal is provided, including:

[0057] Processor, memory, among which,

[0058] This memory is used to store computer programs.

[0059] The processor is used to retrieve and run the computer program from memory, causing the terminal to perform the terminal method described above.

[0060] Fourthly, a computer storage medium is provided, wherein instructions are stored therein, which, when executed on a computer, cause the computer to perform the methods described in the above aspects.

[0061] The beneficial effects of this invention are that the method, system, terminal, and storage medium for expanding dual-active volumes in abnormal states provided by this invention enable cluster state detection and determination of the expansion process. Based on the state of nodes at each site, it determines the local and slave volumes, then converts the dual-active volume to a regular volume and expands the regular volume, and then converts the regular volume back to a dual-active volume. This volume wear conversion method enables rapid online expansion of dual-active volumes even in abnormal states of a dual-active storage cluster. When applied to dual-active storage systems, this invention enables rapid online expansion of dual-active volumes in abnormal states, improving the applicability of dual-active storage systems.

[0062] Furthermore, the design principle of this invention is reliable, the structure is simple, and it has a very wide range of application prospects. Attached Figure Description

[0063] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0064] Figure 1 This is a schematic flowchart of a method according to an embodiment of the present invention.

[0065] Figure 2 This is another illustrative flowchart of a method according to an embodiment of the present invention.

[0066] Figure 3 This is a schematic block diagram of a system according to an embodiment of the present invention.

[0067] Figure 4 This is a schematic diagram of the structure of a terminal provided in an embodiment of the present invention. Detailed Implementation

[0068] To enable those skilled in the art to better understand the technical solutions of this invention, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this invention.

[0069] The key terms used in this invention will be explained below.

[0070] Change volumes can be used in globally mirrored relationships configured in a round-robin fashion. They can also be used between HyperSwap volume copies and other relationship types to automatically maintain a consistent image of secondary volumes during relationship resynchronization. Change volumes create periodic point-in-time copies of the source volume and replicate these copies to secondary sites. Using change volumes reduces bandwidth requirements by satisfying only average throughput rather than peak throughput. If globally mirrored in a round-robin fashion, the copy process is similar to high-speed mirroring and standard global mirroring. Change volumes must be configured for both the primary and secondary volumes in each relationship. The primary volume in the relationship is copied using the change volume specified when the globally mirrored relationship (with change volumes) was created. The background copy process reads data from a stable and consistent change volume and replicates the data to the secondary volumes in the relationship. Copy-on-write technology maintains the consistency of the primary volume image for reading the background copy process. It also tracks changes that occur during the background copy process's persistence. Change volumes for secondary volumes can also be used to maintain the consistency of the secondary volume image while the background copy process is active. Once the background copy process is complete, the change volume for the primary volume merges the change records received by the globally mirrored relationship. If the process does not complete normally, for example, when the relationship stops, the global mirror relationship becomes "Inconsistent Stopped" or "Consistent Stopped". Changes to the volume and on both sites (using...) It is used with volumes that have copies on the topology. Similar to the change copy used in a global mirror relationship, HyperSwap's change volumes are used to create point-in-time copies of the volume on a separate site. Change volumes maintain a consistent and stable record of changes and enable faster data resynchronization.

[0071] Figure 1 This is a schematic flowchart illustrating a method according to an embodiment of the present invention. Wherein, Figure 1 The executing entity can be a dual-active-volume expansion system in an abnormal state.

[0072] like Figure 1 As shown, the method includes:

[0073] Step 110: Confirm that there is an offline site in the dual-active storage system;

[0074] Step 120: Remove the active-active relationship between the two sites in the active-active storage system and synchronously expand the volume of the normal site.

[0075] Step 130: Restore the active-active relationship between the normal site and the offline site using the normal site as the local site, and create a volume for the offline site based on the volume capacity of the local site.

[0076] Step 140: After the offline site comes back online, start data synchronization from the local site to the slave site.

[0077] This method involves cluster status detection and determining the expansion process. Based on the status of nodes at each site, it determines the local and slave volumes, then converts the dual-active volume to a regular volume and expands it. This process is repeated, converting the regular volume back to a dual-active volume. This volume wear-out conversion method enables rapid online expansion of dual-active volumes even in abnormal dual-active storage cluster states. When applied to dual-active storage systems, this invention allows for rapid online expansion of dual-active volumes even in abnormal states, improving the applicability of dual-active storage systems.

[0078] To facilitate understanding of the present invention, the following description further illustrates the dual-active volume expansion method under abnormal conditions, based on the principle of the present invention and the process of expanding a dual-active volume under abnormal conditions in the embodiments.

[0079] For details, please refer to Figure 2 The method for expanding a dual-active volume under abnormal conditions includes:

[0080] S1. Confirm that there is an offline site in the dual-active storage system.

[0081] Upon receiving the expansion command, the status of each node in the dual-active storage system is collected; if the number of nodes in the offline state is 2 or 3, it is determined whether there is a site that includes two offline nodes; if so, the site is determined to be an offline site.

[0082] Specifically, after the cluster status detection and determination of the expansion process as a dual-active volume expansion instruction are executed, the dual-active storage management system will detect the current cluster status, determine the running status of each node in each site, and execute the corresponding expansion process according to different running statuses. The specific steps are as follows:

[0083] a> If the node status queried in step a> is active, proceed with the normal online expansion process for dual-active volumes.

[0084] b> If, in step a>, one of the nodes in the running status is offline and the rest are active, proceed with the normal dual-active volume online expansion process.

[0085] c> If two of the nodes found in step a> are offline, and these two offline nodes are located in different sites, and the remaining two storage nodes are active, then proceed with the normal dual-active volume online expansion process.

[0086] d> If two of the nodes in the running status queried in step a> are offline, and these two offline nodes are located in the same site, and the remaining two storage nodes are active, then the abnormal dual-active volume online expansion process is followed, which is the expansion method provided by this invention.

[0087] e> If three of the nodes in the running status queried in step a> are offline and the remaining storage node is active, then the abnormal dual-active volume online expansion process is followed, which is the expansion method provided by this invention.

[0088] The normal online expansion process for dual active volumes first expands the slave primary and secondary volumes, updating the new bitmap information synchronously during expansion. Then, it expands the local secondary volume, updating the new bitmap information during expansion. Finally, it expands the local primary volume, updating the local primary volume synchronously with reference to the bitmap information of the local secondary volume. This achieves online expansion of dual active volumes in the manner of "slave primary and secondary volumes - local secondary volume - local primary volume".

[0089] S2. Remove the active-active relationship between the two sites in the active-active storage system and synchronously expand the volume of the normal site.

[0090] The offline site is designated as a slave site, and its slave primary volume and slave secondary volume are deleted. The normal site in the dual-active storage system is designated as the local site, and its local primary volume and local secondary volume are changed to independent ordinary volumes. The changed local primary volume and local secondary volume are then synchronously expanded. Specifically, designating the normal site in the dual-active storage system as the local site and changing its local primary volume and local secondary volume to independent ordinary volumes includes: decoupling the association between the local primary volume and local secondary volume; and deleting the bitmap information of the local site. The synchronous expansion of the changed local primary volume and local secondary volume includes: calling ordinary volume expansion commands to expand the capacity of the changed local primary volume and local secondary volume to the target capacity, ensuring that the expanded local primary volume has the same capacity as the local secondary volume.

[0091] The specific execution method for this step is as follows:

[0092] (1) Determining the local endpoint and its volume: Based on the detection results and expansion process in step S1, determine which site is the local endpoint. The volume attached to that site is the local endpoint volume. This also determines that the other site is the slave endpoint and the volume attached to that other site is the slave endpoint volume. Details are as follows:

[0093] If the detection result matches condition d> in step S1, then the local end is a site where both storage nodes are active. The volumes attached to this site are local volumes, including the local primary volume and the local secondary volume. Both volumes are active at this time. Correspondingly, the other site is a slave end, and the volumes attached to the other site are slave volumes, including the slave primary volume and the slave secondary volume. Both volumes are offline at this time.

[0094] If the detection result matches condition e> in step S1, then the local end is a storage node with an active status, and the volumes attached to this site are local volumes, including the local primary volume and the local secondary volume. Both volumes are in the degrade state at this time. Correspondingly, the other site is the slave end, and the volumes attached to the other site are slave volumes, including the slave primary volume and the slave secondary volume. Both volumes are in the offline state at this time.

[0095] (2) Convert the double-rolled paper to a regular paper.

[0096] After determining the local site and its primary and secondary volumes, the storage cluster calls the delete volume command to delete the secondary primary and secondary volumes. This removes the active-active relationship between the local and secondary volumes, turning them into ordinary volumes. The association between the primary and secondary volumes is also severed, and the bitmap information is deleted, making them two independent ordinary volumes. Since only the primary volume contains business data, and the secondary volume does not, front-end user services only read and write to the primary volume, preventing service interruption.

[0097] (3) Expand the capacity of regular test papers.

[0098] The storage cluster invokes a normal volume expansion command to expand both the local primary volume and the local secondary volume, ensuring that the two volumes have the same capacity after expansion.

[0099] S3. Restore the active-active relationship between the normal site and the offline site using the normal site as the local site, and create a volume for the offline site based on the volume capacity of the local site.

[0100] Using the offline site as a slave node, a create volume command is invoked to create a slave primary volume for the slave site, the capacity of which is the same as the capacity of the volume at the local site; a slave secondary volume belonging to the slave site is created based on the slave primary volume, the capacity of which is the same as the slave primary volume; and a dual-active relationship is established between the two volumes at the local site and the two volumes at the slave site by specifying a dual-active domain.

[0101] Specifically, after the expansion of the ordinary volumes (original primary volume and original secondary volume) is completed, the storage cluster calls the create volume command to create a volume belonging to the slave end with the same volume capacity as the expanded primary end. This volume is the slave primary volume. Then, a slave secondary volume is created based on this volume. The slave primary volume and the slave secondary volume have the same volume capacity, and both are the same as the local primary volume and the local secondary volume. The active-active relationship between the four volumes on the local and slave ends is re-established. The local end generates the latest bitmap information, while the slave end, being offline at this time, does not generate bitmap information. When re-establishing the active-active relationship between the four volumes on the local and slave ends, the active-active domain specifies the resources of the local and slave sites. The specific attribute settings are common knowledge in this field and will not be elaborated here.

[0102] S4. Enable data synchronization from the local site to the slave site after the offline site is brought back online.

[0103] After establishing an active-active relationship between the local and slave sites, the data in the local master volume is copied to the slave master volume; after confirming that the offline site is back online, the bitmap information regenerated by the local site after expansion is copied to the slave site.

[0104] Specifically, after the active-active relationship is established, consistent synchronization begins. This means data in the local primary volume is copied to the secondary primary volume. Because the secondary volume is offline at this time, the consistent synchronization process is suspended. Consistent synchronization resumes once the secondary volume becomes active or degraded. Simultaneously, bitmap information from the local volume is also copied to the secondary volume. After consistent synchronization is complete, the data and bitmap information in the local and secondary primary volumes are identical, and the active-active volume expansion is complete. During the expansion process, the front-end services continue to operate normally.

[0105] like Figure 3 As shown, the system 300 includes:

[0106] Anomaly confirmation unit 310 is used to confirm the existence of an offline site in the dual-active storage system;

[0107] The dual-active deactivation unit 320 is used to deactivate the dual-active relationship between two sites in a dual-active storage system and to synchronously expand the volume of the normal site.

[0108] The dual-active recovery unit 330 is used to restore the dual-active relationship between the normal site and the offline site by using the normal site as the local site, and to create a volume for the offline site based on the volume capacity of the local site.

[0109] The data synchronization unit 340 is used to enable data synchronization from the local site to the slave site after the offline site is brought back online.

[0110] Optionally, as an embodiment of the present invention, the anomaly determination unit is specifically used for:

[0111] Upon receiving the expansion command, the status of each node in the dual-active storage system is collected;

[0112] If there are 2 or 3 nodes in an offline state, then determine whether there is a site that includes two offline nodes:

[0113] If so, the site is determined to be an offline site.

[0114] Optionally, as an embodiment of the present invention, the dual-active release unit includes:

[0115] The slave deletion module is used to treat the offline site as a slave site and delete the slave primary volume and slave secondary volume of the slave site;

[0116] The local change module is used to treat a normal site in a dual-active storage system as the local site and change the local primary volume and local secondary volume of the local site into independent ordinary volumes.

[0117] The local expansion module is used to synchronously expand the capacity of the modified local main volume and local auxiliary volume.

[0118] Optionally, as an embodiment of the present invention, the local modification module is specifically used for:

[0119] Disconnect the main volume and auxiliary volume of this terminal;

[0120] Delete the bitmap information of this site.

[0121] Optionally, as an embodiment of the present invention, the local expansion module is specifically used for:

[0122] The normal volume expansion command is invoked to expand the capacity of the modified local main volume and local auxiliary volume to the target capacity, and the expanded local main volume and local auxiliary volume have the same capacity.

[0123] Optionally, as an embodiment of the present invention, the dual-active recovery unit is specifically used for:

[0124] Using an offline site as a slave node, a volume creation command is invoked to create a slave master volume for the slave site, and the capacity of the slave master volume is the same as the capacity of the volume of the local site.

[0125] A secondary volume belonging to the slave site is created based on the primary volume, and the secondary volume has the same capacity as the primary volume.

[0126] By specifying a dual-active domain, a dual-active relationship is established between two volumes at the local site and two volumes at the slave site.

[0127] Optionally, as an embodiment of the present invention, the data synchronization unit is specifically used for:

[0128] After establishing an active-active relationship between the local and slave sites, the data in the local primary volume is copied to the slave primary volume.

[0129] After confirming that the offline site is back online, copy the bitmap information regenerated on the local site after the expansion to the slave site.

[0130] Figure 4 This is a schematic diagram of the structure of a terminal 400 provided in an embodiment of the present invention. The terminal 400 can be used to execute the dual-active-volume expansion method for abnormal states provided in the embodiment of the present invention.

[0131] The terminal 400 may include a processor 410, a memory 420, and a communication unit 430. These components communicate via one or more buses. Those skilled in the art will understand that the server structure shown in the figure does not constitute a limitation of the present invention. It may be a bus topology or a star topology, and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0132] The memory 420 can be used to store the execution instructions of the processor 410. The memory 420 can be implemented by any type of volatile or non-volatile memory terminal or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk. When the execution instructions in the memory 420 are executed by the processor 410, the terminal 400 is able to perform some or all of the steps in the above method embodiments.

[0133] The processor 410 serves as the control center of the storage terminal, connecting various parts of the electronic terminal via various interfaces and lines. It executes software programs and / or modules stored in the memory 420, and calls data stored in the memory to perform various functions of the electronic terminal and / or process data. The processor can be composed of integrated circuits (ICs), such as a single packaged IC or multiple packaged ICs with the same or different functions connected together. For example, the processor 410 may consist only of a central processing unit (CPU). In this embodiment of the invention, the CPU may have a single processing core or include multiple processing cores.

[0134] The communication unit 430 is used to establish a communication channel, enabling the storage terminal to communicate with other terminals. It can receive user data sent by other terminals or send user data to other terminals.

[0135] The present invention also provides a computer storage medium, wherein the computer storage medium may store a program, which, when executed, may include some or all of the steps provided in the embodiments of the present invention. The storage medium may be a magnetic disk, an optical disk, read-only memory (ROM), or random access memory (RAM), etc.

[0136] Therefore, this invention provides a cluster status detection and expansion process. Based on the status of nodes at each site, it determines the local and slave volumes, then converts the dual-active volume to a regular volume and expands it. This process is repeated, converting the regular volume back to a dual-active volume. This volume wear-out conversion method enables rapid online expansion of dual-active volumes even in abnormal dual-active storage cluster states. When applied to dual-active storage systems, this invention allows for rapid online expansion of dual-active volumes even in abnormal states, improving the applicability of dual-active storage systems. The technical effects achieved in this embodiment are described above and will not be repeated here.

[0137] Those skilled in the art will clearly understand that the techniques in the embodiments of the present invention can be implemented using software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solutions in the embodiments of the present invention, or the parts that contribute to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, or any other medium capable of storing program code. It includes several instructions to cause a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.

[0138] The same or similar parts between the various embodiments in this specification can be referred to mutually. In particular, the terminal embodiments are basically similar to the method embodiments, so the description is relatively simple, and the relevant parts can be referred to the description in the method embodiments.

[0139] In the embodiments provided by this invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative. For instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between systems or units may be electrical, mechanical, or other forms.

[0140] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0141] In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0142] Although the present invention has been described in detail with reference to the accompanying drawings and preferred embodiments, the invention is not limited thereto. Various equivalent modifications or substitutions can be made to the embodiments of the invention by those skilled in the art without departing from the spirit and essence of the invention, and such modifications or substitutions should all be within the scope of the invention. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the invention should also be covered within the protection scope of the invention. Therefore, the protection scope of the invention should be determined by the scope of the claims.

Claims

1. A method for expanding a dual-active volume under abnormal conditions, characterized in that, include: It has been confirmed that there is an offline site in the dual-active storage system; Remove the active-active relationship between the two sites in the active-active storage system and synchronously expand the volume of the normal site; The active-active relationship between the normal site and the offline site is restored by using the normal site as the local site, and a volume is created for the offline site based on the volume capacity of the local site. Enable data synchronization from the local site to the slave site after the offline site is brought back online; Confirm that there is an offline site in the dual-active storage system, including: Upon receiving the expansion command, the status of each node in the dual-active storage system is collected; If there are 2 or 3 nodes in an offline state, then determine whether there is a site that includes two offline nodes: If so, the site is determined to be an offline site.

2. The method according to claim 1, characterized in that, Remove the active-active relationship between the two sites in the active-active storage system and synchronously expand the volume of the normal site, including: Treat the offline site as a slave site, and delete the slave primary volume and slave secondary volume of the slave site; In a dual-active storage system, the normal site is designated as the local site, and the local primary volume and local secondary volume of the local site are changed into independent ordinary volumes. The capacity of the modified local main volume and local auxiliary volume will be expanded simultaneously.

3. The method according to claim 2, characterized in that, In a dual-active storage system, the normal site is designated as the local site, and the local primary volume and local secondary volume of the local site are changed to independent ordinary volumes, including: Disconnect the main volume and auxiliary volume of this terminal; Delete the bitmap information of this site.

4. The method according to claim 2, characterized in that, The modified local main volume and local auxiliary volume will be expanded synchronously, including: The normal volume expansion command is invoked to expand the capacity of the modified local main volume and local auxiliary volume to the target capacity, and the expanded local main volume and local auxiliary volume have the same capacity.

5. The method according to claim 1, characterized in that, Restore the active-active relationship between the normal site and the offline site using the normal site as the local site, and create volumes for the offline site based on the volume capacity of the local site, including: Using an offline site as a slave node, a volume creation command is invoked to create a slave master volume for the slave site, and the capacity of the slave master volume is the same as the capacity of the volume of the local site. A secondary volume belonging to the slave site is created based on the primary volume, and the secondary volume has the same capacity as the primary volume. By specifying a dual-active domain, a dual-active relationship is established between two volumes at the local site and two volumes at the slave site.

6. The method according to claim 1, characterized in that, After the offline site comes back online, enable data synchronization from the local site to the slave site, including: After establishing an active-active relationship between the local and slave sites, the data in the local primary volume is copied to the slave primary volume. After confirming that the offline site is back online, copy the bitmap information regenerated on the local site after the expansion to the slave site.

7. A dual-active volume expansion system under abnormal conditions, characterized in that, include: The anomaly confirmation unit is used to confirm the existence of an offline site in the dual-active storage system; The dual-active deactivation unit is used to deactivate the dual-active relationship between two sites in a dual-active storage system and to synchronously expand the volume of the normal site. The dual-active recovery unit is used to restore the dual-active relationship between the normal site and the offline site by using the normal site as the local site, and to create a volume for the offline site based on the volume capacity of the local site. The data synchronization unit is used to initiate data synchronization between the local site and the slave site after the offline site is brought back online. Confirm that there is an offline site in the dual-active storage system, including: Upon receiving the expansion command, the status of each node in the dual-active storage system is collected; If there are 2 or 3 nodes in an offline state, then determine whether there is a site that includes two offline nodes: If so, the site is determined to be an offline site.

8. A terminal, characterized in that, include: processor; Memory used to store the processor's execution instructions; The processor is configured to perform the method according to any one of claims 1-6.

9. A computer-readable storage medium storing a computer program, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-6.