A method, system, device and medium for sending data request to a logical volume
By setting different path group priorities for logical volumes, the problem of uneven path distribution in multi-control storage scenarios is solved, and storage performance improvement and resource load balancing are achieved.
Patent Information
- Application Number
- CN202210589510.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-26
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2042-05-26
AI Technical Summary
In a multi-controller storage scenario, logical volumes experience uneven path distribution when a controller fails, resulting in resource waits and reduced storage performance.
Obtain the IO paths on the storage side, combine them into path groups, and set different priorities for each logical volume. Select the appropriate path group to issue data requests based on the path group status and priority, and dynamically adjust the path group priority to achieve load balancing. .
It effectively solves the problem of resource waiting and uneven IO distribution caused by multiple logical volumes preempting paths, improves storage performance, and especially reduces resource waiting in failure scenarios.
Smart Images

Figure CN114816264B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of storage, and in particular to a method, system, device and storage medium for sending data requests from a logical volume. Background Art
[0002] ALUA (Asymmetric Logical Unit Access) storage notifies the host of the status of each path AO (Active Optimized) and AN (Active Non-optimized) through standard protocol instructions. In conjunction with the host-side multipath priority policy, IO is preferentially sent from the AO path and is only sent from the AN path after the AO path fails.
[0003] Usually, multiple logical volumes will be created in user scenarios, and AO / AN paths are grouped by controllers. After a controller fails, there will be uneven distribution of AO / AN paths for logical volumes in multi-controller storage scenarios (number of control nodes > 2). The logical volume with this controller as the optimal path will preempt all AN paths, and will also preempt logical volumes with other remaining controllers as the optimal path, causing additional waiting and uneven distribution of resources, and reducing storage performance. Summary of the invention
[0004] In view of this, in order to overcome at least one aspect of the above problems, an embodiment of the present invention proposes a method for sending a data request for a logical volume, comprising the following steps:
[0005] Get the IO path of each controller in the storage end;
[0006] Taking the IO paths in the same controller as one path group to obtain multiple path groups;
[0007] Allocating the plurality of path groups to each logical volume and setting different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups having the highest priorities;
[0008] According to the status and priority of each path group allocated to the logical volume, a corresponding path group is selected to send a data request to the storage end.
[0009] In some embodiments, selecting a corresponding path group according to the status and priority of each path group assigned to the logical volume to send a data request to the storage end further includes:
[0010] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0011] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0012] In some embodiments, sending a data request using an IO path in the path group with the highest priority further includes:
[0013] Get the first parameter;
[0014] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0015] In some embodiments, sending a data request using an IO path in a path group with the highest priority in the remaining path groups further includes:
[0016] Get the second parameter;
[0017] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0018] In some embodiments, it also includes:
[0019] Creating an independent waiting queue for each IO path at the storage end;
[0020] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0021] In some embodiments, it also includes:
[0022] Periodically count each waiting queue to get the pressure of each IO path;
[0023] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0024] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0025] In some embodiments, it also includes:
[0026] Get the total amount of data requests issued by each logical volume;
[0027] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0028] Based on the same inventive concept, according to another aspect of the present invention, an embodiment of the present invention further provides a system for sending a data request for a logical volume, comprising:
[0029] An acquisition module configured to acquire an IO path in each controller in the storage end;
[0030] A combining module configured to take the IO paths in the same controller as one path group to obtain a plurality of path groups;
[0031] an allocation module, configured to allocate the plurality of path groups to each logical volume and set different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups with the highest priorities;
[0032] The sending module is configured to select a corresponding path group according to the state and priority of each path group allocated to the logical volume to send a data request to the storage end.
[0033] In some embodiments, the sending module is further configured to:
[0034] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0035] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0036] In some embodiments, the sending module is further configured to:
[0037] Get the first parameter;
[0038] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0039] In some embodiments, the sending module is further configured to:
[0040] Get the second parameter;
[0041] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0042] In some embodiments, the invention further includes a creation module configured to:
[0043] Creating an independent waiting queue for each IO path at the storage end;
[0044] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0045] In some embodiments, an adjustment module is further included, configured to:
[0046] Periodically count each waiting queue to get the pressure of each IO path;
[0047] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0048] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0049] In some embodiments, a statistics module is further included, configured to:
[0050] Get the total amount of data requests issued by each logical volume;
[0051] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0052] Based on the same inventive concept, according to another aspect of the present invention, an embodiment of the present invention further provides a computer device, including:
[0053] at least one processor; and
[0054] A memory storing a computer program executable on the processor, wherein the processor executes the steps of any one of the above-mentioned methods for sending a data request to a logical volume when executing the program.
[0055] Based on the same inventive concept, according to another aspect of the present invention, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for sending data requests to any logical volume as described above are performed.
[0056] The present invention has one of the following beneficial technical effects: the solution proposed in the present invention refines the priority of the logical volume path group with the controller as the granularity, sets different priorities for the path groups of different controllers, and the paths within the same controller have the same priority, thereby standardizing the rules for issuing IO, and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes simultaneously occupying a certain path in a fault scenario. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other embodiments can be obtained based on these drawings without paying creative work.
[0058] Figure 1 A flow chart of a method for sending a data request to a logical volume provided by an embodiment of the present invention;
[0059] Figure 2 A schematic diagram of the structure of a four-controller storage provided by an embodiment of the present invention;
[0060] Figure 3 A schematic diagram of the structure of a logical volume data request system provided by an embodiment of the present invention;
[0061] Figure 4 A schematic diagram of the structure of a computer device provided by an embodiment of the present invention;
[0062] Figure 5 A schematic diagram of the structure of a computer-readable storage medium provided for an embodiment of the present invention. DETAILED DESCRIPTION
[0063] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the embodiments of the present invention are further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.
[0064] It should be noted that all expressions using "first" and "second" in the embodiments of the present invention are for distinguishing two non-identical entities with the same name or non-identical parameters. It can be seen that "first" and "second" are only for the convenience of expression and should not be understood as limitations on the embodiments of the present invention. The subsequent embodiments will not explain this one by one.
[0065] According to one aspect of the present invention, an embodiment of the present invention provides a method for sending a data request to a logical volume, such as Figure 1 As shown, it may include the steps of:
[0066] S1, obtain the IO path in each controller in the storage end;
[0067] S2, taking the IO paths in the same controller as one path group to obtain multiple path groups;
[0068] S3, assigning the multiple path groups to each logical volume and setting different priorities for the multiple path groups in each logical volume, wherein different logical volumes are set with different path groups with the highest priority;
[0069] S4, selecting a corresponding path group according to the status and priority of each path group allocated to the logical volume and sending a data request to the storage end.
[0070] The solution proposed in the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and makes the paths in the same controller have the same priority, thereby standardizing the rules for issuing IO and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario.
[0071] In some embodiments, in step S1, the IO paths in each controller in the storage end are obtained. Specifically, each controller may have multiple IO paths, and the IO paths in the same controller may be grouped together, and the IO paths in the same path group have the same priority. In this way, the priority of each logical volume is refined according to the number of controllers, the port paths in the controller have the same priority, and the port paths between controllers are set with different priorities.
[0072] In some embodiments, in step S3, the plurality of path groups are assigned to each logical volume and different priorities are set for the plurality of path groups in each logical volume, wherein the path groups with the highest priority set for different logical volumes are different. Specifically, when creating a logical volume, the priority rules for each logical volume on different path groups can be defined by defining a private report lun protocol instruction. The priority can be set for the path group corresponding to each logical volume according to the principle of circular designation, and the private protocol CDB can be filled and sent to the host multipath, so that the path groups with the highest priority set for different logical volumes are different.
[0073] For example, for a four-controller storage system, the priority of each logical volume path is divided into: AO, AN1, AN2, AN3, and the path priority order is: AO>AN1>AN2>AN3. Figure 2 As shown in the figure, the storage system creates a total of four path groups (each path group includes two IO paths). The IO paths in each path group have the same priority. For logical volume 1, the priority of the four path groups is path group 1 (AO) > path group 2 (AN1) > path group 3 (AN2) > path group 4 (AN3); the priority of the four paths of logical volume 2 is path group 2 (AO) > path group 3 (AN1) > path group 4 (AN2) > path group 1 (AN3); the priority of the four paths of logical volume 3 is path group 3 (AO) > path group 4 (AN1) > path group 1 (AN2) > path group 2 (AN3)..., and the path priority is notified to the host multipath software through a private protocol.
[0074] In some embodiments, selecting a corresponding path group according to the status and priority of each path group assigned to the logical volume to send a data request to the storage end further includes:
[0075] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0076] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0077] Specifically, the host-side multipath software groups the logical volumes by priority in a private protocol. Under normal circumstances, each logical volume only sends IO on its own AO path group. When the AO path group fails, the AN1 path group is given priority, and so on.
[0078] In this way, the host multipath parses CDB data and groups it according to priority, expanding from the original grouping by AO / AN to grouping by controller, and refining the grouping granularity. When the AO group path is normal, the host sends IO through the AO group path. When the AO group path is abnormal, it sends the path through the AN1 group. When both the AO group and the AN1 group paths are abnormal, it sends IO through the AN2 group, and so on.
[0079] By standardizing the rules for issuing IOs through this mode, when a controller failure occurs, it reduces resource waiting and uneven IO distribution caused by multiple logical volumes simultaneously occupying each path.
[0080] In some embodiments, sending a data request using an IO path in the path group with the highest priority further includes:
[0081] Get the first parameter;
[0082] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0083] Specifically, different parameters can be set in each path group to select which IO path to use when sending data requests. For example, when selecting the loop parameter, the first data request can be sent through the first IO path, and then the second data request can be sent through the second IO path, and then the third data request can be sent through the first IO path, and so on. The loop parameter is selected first in the path group with the highest priority.
[0084] In some embodiments, sending a data request using an IO path in a path group with the highest priority in the remaining path groups further includes:
[0085] Get the second parameter;
[0086] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0087] Specifically, the second parameter may be a processing speed, that is, determining through which IO path the data request is sent based on the processing speed of each IO path. When sending data requests using the IO path in the path group with the highest priority in the remaining path groups, the IO path determined by the processing speed is given priority.
[0088] In some embodiments, it also includes:
[0089] Creating an independent waiting queue for each IO path at the storage end;
[0090] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0091] Specifically, the storage end creates an independent waiting queue M for each IO path, and fills the IO request sent by the host and the corresponding logical volume ID into the waiting queue. The storage end obtains the IO request from the waiting queue for processing each time, and clears the request from the waiting queue after processing. The storage end periodically analyzes the requests in each waiting queue, obtains the IO pressure of each path, and adds the path ID to the first linked list from small to large according to the IO pressure.
[0092] In some embodiments, it also includes:
[0093] Periodically count each waiting queue to get the pressure of each IO path;
[0094] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0095] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0096] Specifically, the front paths in the first linked list are obtained (these paths have low transmission pressure), and the corresponding path groups are obtained through the paths. The priorities of the path groups corresponding to these logical volumes are increased, and the private protocol CDB is filled and sent to the host multipath.
[0097] For example, if the pressure on path 1a in path group 1 is small, but the priority of path group 1 in other logical volumes is not high, and the pressure on the path groups with high priority in other logical volumes is relatively large, the priority of path group 1 can be increased. In this way, the host multipath parses CDB data and adjusts the IO delivery strategy according to the latest priority to achieve the purpose of load balancing.
[0098] In some embodiments, it also includes:
[0099] Get the total amount of data requests issued by each logical volume;
[0100] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0101] Specifically, the business request volume of each logical volume can be obtained, and the logical volume IDs can be added to the second linked list according to the business request volume from large to small. Thus, when optimizing the logical volumes, the logical volumes at the front of the second linked list (these volumes have high access pressure) can be optimized.
[0102] The solution proposed by the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and sets the same priority for the paths within the same controller, thereby standardizing the rules for issuing IOs and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario. It can also dynamically adjust the priority of the path group, reducing the uneven IO distribution caused by high pressure on some IO paths and low pressure on some IO paths when some logical volumes are busy.
[0103] Based on the same inventive concept, according to another aspect of the present invention, an embodiment of the present invention further provides a system 400 for sending a data request to a logical volume, such as Figure 3 As shown, including:
[0104] An acquisition module 401 is configured to acquire an IO path in each controller in a storage end;
[0105] A combining module 402 is configured to take the IO paths in the same controller as one path group to obtain multiple path groups;
[0106] An allocation module 403 is configured to allocate the plurality of path groups to each logical volume and set different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups having the highest priorities;
[0107] The sending module 404 is configured to select a corresponding path group according to the status and priority of each path group allocated to the logical volume and send a data request to the storage end.
[0108] The solution proposed in the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and makes the paths in the same controller have the same priority, thereby standardizing the rules for issuing IO and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario.
[0109] In some embodiments, the sending module 404 is further configured to:
[0110] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0111] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0112] In some embodiments, the sending module 404 is further configured to:
[0113] Get the first parameter;
[0114] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0115] In some embodiments, the sending module 404 is further configured to:
[0116] Get the second parameter;
[0117] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0118] In some embodiments, the invention further includes a creation module configured to:
[0119] Creating an independent waiting queue for each IO path at the storage end;
[0120] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0121] In some embodiments, an adjustment module is further included, configured to:
[0122] Periodically count each waiting queue to get the pressure of each IO path;
[0123] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0124] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0125] In some embodiments, a statistics module is further included, configured to:
[0126] Get the total amount of data requests issued by each logical volume;
[0127] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0128] The solution proposed by the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and sets the same priority for the paths within the same controller, thereby standardizing the rules for issuing IOs and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario. It can also dynamically adjust the priority of the path group, reducing the uneven IO distribution caused by high pressure on some IO paths and low pressure on some IO paths when some logical volumes are busy.
[0129] Based on the same inventive concept, according to another aspect of the present invention, Figure 4 As shown, an embodiment of the present invention further provides a computer device 501, including:
[0130] at least one processor 520; and
[0131] The memory 510 stores a computer program 511 that can be run on the processor. When the processor 520 executes the program, the following steps are performed:
[0132] Get the IO path of each controller in the storage end;
[0133] Taking the IO paths in the same controller as one path group to obtain multiple path groups;
[0134] Allocating the plurality of path groups to each logical volume and setting different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups having the highest priorities;
[0135] According to the status and priority of each path group allocated to the logical volume, a corresponding path group is selected to send a data request to the storage end.
[0136] In some embodiments, selecting a corresponding path group according to the status and priority of each path group assigned to the logical volume to send a data request to the storage end further includes:
[0137] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0138] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0139] In some embodiments, sending a data request using an IO path in the path group with the highest priority further includes:
[0140] Get the first parameter;
[0141] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0142] In some embodiments, sending a data request using an IO path in a path group with the highest priority in the remaining path groups further includes:
[0143] Get the second parameter;
[0144] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0145] In some embodiments, it also includes:
[0146] Creating an independent waiting queue for each IO path at the storage end;
[0147] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0148] In some embodiments, it also includes:
[0149] Periodically count each waiting queue to get the pressure of each IO path;
[0150] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0151] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0152] In some embodiments, it also includes:
[0153] Get the total amount of data requests issued by each logical volume;
[0154] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0155] The solution proposed by the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and sets the same priority for the paths within the same controller, thereby standardizing the rules for issuing IOs and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario. It can also dynamically adjust the priority of the path group, reducing the uneven IO distribution caused by high pressure on some IO paths and low pressure on some IO paths when some logical volumes are busy.
[0156] Based on the same inventive concept, according to another aspect of the present invention, Figure 5 As shown, the embodiment of the present invention further provides a computer-readable storage medium 601, the computer-readable storage medium 601 stores a computer program 610, and when the computer program 610 is executed by a processor, the following steps are performed:
[0157] Get the IO path of each controller in the storage end;
[0158] Taking the IO paths in the same controller as one path group to obtain multiple path groups;
[0159] Allocating the plurality of path groups to each logical volume and setting different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups having the highest priorities;
[0160] According to the status and priority of each path group allocated to the logical volume, a corresponding path group is selected to send a data request to the storage end.
[0161] In some embodiments, selecting a corresponding path group according to the status and priority of each path group assigned to the logical volume to send a data request to the storage end further includes:
[0162] In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority;
[0163] In response to an abnormality in the path group with the highest priority, a data request is sent using an IO path in the path group with the highest priority among the remaining path groups.
[0164] In some embodiments, sending a data request using an IO path in the path group with the highest priority further includes:
[0165] Get the first parameter;
[0166] An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
[0167] In some embodiments, sending a data request using an IO path in a path group with the highest priority in the remaining path groups further includes:
[0168] Get the second parameter;
[0169] An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
[0170] In some embodiments, it also includes:
[0171] Creating an independent waiting queue for each IO path at the storage end;
[0172] In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
[0173] In some embodiments, it also includes:
[0174] Periodically count each waiting queue to get the pressure of each IO path;
[0175] Add the IDs of the IO paths to the first linked list in order of pressure from small to large;
[0176] The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
[0177] In some embodiments, it also includes:
[0178] Get the total amount of data requests issued by each logical volume;
[0179] The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
[0180] The solution proposed by the present invention refines the priority of the logical volume path group based on the controller granularity, sets different priorities for the path groups of different controllers, and sets the same priority for the paths within the same controller, thereby standardizing the rules for issuing IOs and solving the problems of resource waiting and uneven IO distribution caused by multiple logical volumes occupying a certain path at the same time in a fault scenario. It can also dynamically adjust the priority of the path group, reducing the uneven IO distribution caused by high pressure on some IO paths and low pressure on some IO paths when some logical volumes are busy.
[0181] Finally, it should be noted that a person skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing related hardware through a computer program, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods.
[0182] Furthermore, it should be appreciated that the computer-readable storage medium (eg, memory) herein may be either a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memory.
[0183] It will also be appreciated by those skilled in the art that various exemplary logic blocks, modules, circuits and algorithm steps described in conjunction with the disclosure herein can be implemented as electronic hardware, computer software or a combination of the two. In order to clearly illustrate this interchangeability of hardware and software, a general description has been given to the functions of various schematic components, blocks, modules, circuits and steps. Whether this function is implemented as software or hardware depends on specific applications and the design constraints imposed on the entire system. Those skilled in the art can implement the function in various ways for each specific application, but this implementation decision should not be interpreted as causing a departure from the disclosed scope of the embodiments of the present invention.
[0184] The above are exemplary embodiments disclosed in the present invention, but it should be noted that various changes and modifications may be made without departing from the scope disclosed in the embodiments of the present invention as defined in the claims. The functions, steps and / or actions of the method claims according to the disclosed embodiments described herein do not need to be performed in any particular order. In addition, although the elements disclosed in the embodiments of the present invention may be described or required in individual form, they may also be understood as multiple unless explicitly limited to the singular.
[0185] It should be understood that, as used herein, the singular forms "a", "an" are intended to include the plural forms as well, unless the context clearly supports an exception. It should also be understood that, as used herein, "and / or" refers to any and all possible combinations including one or more of the associated listed items.
[0186] The serial numbers of the embodiments disclosed in the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0187] A person skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware or by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.
[0188] A person skilled in the art should understand that the discussion of any of the above embodiments is only exemplary and is not intended to imply that the scope of the disclosure of the embodiments of the present invention (including the claims) is limited to these examples; under the concept of the embodiments of the present invention, the technical features in the above embodiments or different embodiments can also be combined, and there are many other changes in different aspects of the embodiments of the present invention as above, which are not provided in detail for the sake of simplicity. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present invention should be included in the protection scope of the embodiments of the present invention.
Claims
1. A method for sending a data request to a logical volume, characterized in that: The following steps are involved: Get the IO path of each controller in the storage end; Taking the IO paths in the same controller as one path group to obtain multiple path groups; Allocating the plurality of path groups to each logical volume and setting different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups having the highest priorities; Selecting a corresponding path group according to the state and priority of each path group assigned to the logical volume to send a data request to the storage end; Wherein, selecting a corresponding path group according to the state and priority of each path group assigned to the logical volume to send a data request to the storage end further includes: In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority; In response to an exception in the highest priority path group, a data request is sent using an IO path in the highest priority path group among the remaining path groups; Wherein, sending the data request by using the IO path in the path group with the highest priority further includes: Get the first parameter; An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
2. The method according to claim 1, characterized in that Sending a data request using an IO path in a path group with the highest priority among the remaining path groups further includes: Get the second parameter; An IO path for sending the data request in the path group with the highest priority in the remaining path groups is determined according to the second parameter.
3. The method according to claim 1, characterized in that Also includes: Creating an independent waiting queue for each IO path at the storage end; In response to receiving the issued data request, the data request and the corresponding logical volume ID are filled into the corresponding waiting queue.
4. The method according to claim 3, characterized in that Also includes: Periodically count each waiting queue to get the pressure of each IO path; Add the IDs of the IO paths to the first linked list in order of pressure from small to large; The priority of the path group allocated to the corresponding logical volume is adjusted according to the order of the IO paths in the first linked list.
5. The method according to claim 3, characterized in that Also includes: Get the total amount of data requests issued by each logical volume; The IDs of the logical volumes are written into the second linked list from large to small according to the total amount of data requests.
6. A system for sending data requests from a logical volume, characterized in that: include: An acquisition module configured to acquire an IO path in each controller in the storage end; A combining module configured to take the IO paths in the same controller as one path group to obtain a plurality of path groups; an allocation module, configured to allocate the plurality of path groups to each logical volume and set different priorities for the plurality of path groups in each logical volume, wherein different logical volumes are set with different path groups with the highest priorities; A sending module, configured to select a corresponding path group according to the state and priority of each path group assigned to the logical volume to send a data request to the storage end; Among them, the sending module is also configured as: In response to the path group with the highest priority being normal, sending a data request using an IO path in the path group with the highest priority; In response to an exception in the highest priority path group, a data request is sent using an IO path in the highest priority path group among the remaining path groups; Wherein, sending the data request by using the IO path in the path group with the highest priority further includes: Get the first parameter; An IO path in the path group with the highest priority for sending the data request is determined according to the first parameter.
7. A computer device comprising: at least one processor; as well as A memory storing a computer program executable on the processor, wherein the processor executes the steps of the method according to any one of claims 1 to 5 when executing the program.
8. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are performed.
Citation Information
Patent Citations
Method and device for balancing read-write load of multi-controller storage array
CN106873907A
Data reconstruction method and system, equipment and medium
CN112650444A
