IO processing method, device, equipment and medium
By monitoring the stripe hits and reordering mechanism of the RAID array, identifying and marking the random or continuous attributes of IO requests, the problem of difficulty in identifying continuity caused by disordered IO requests in the RAID system is solved, and data access efficiency is improved.
Patent Information
- Application Number
- CN202411137186.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-19
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2044-08-19
AI Technical Summary
In RAID systems, out-of-order execution of IO requests makes it difficult to accurately identify continuity, resulting in reduced data access efficiency.
By monitoring the stripe hits of the RAID array and combining the reordering mechanism of IO requests, the random or continuous attributes of IO requests are identified and marked, and the monitoring window mechanism is used to allocate IO requests to the corresponding queues and process them according to continuity.
Improves the efficiency of IO request processing, ensures accurate marking even when IO requests are out of order, and improves the overall system performance.
Smart Images

Figure CN119105703B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of storage technology, and in particular to an IO processing method, apparatus, device and medium. Background Art
[0002] In computer architecture, RAID technology is widely adopted for its advantages in improving data storage reliability and performance. However, the randomness and continuity of I / O requests require storage systems to adopt differentiated processing strategies. Inappropriate processing mechanisms can significantly reduce data access efficiency. This is particularly critical in RAID 5 / 6. Traditional marking techniques typically use a sliding window mechanism to monitor the continuity of I / O operations. This method sets the end point of each I / O as the center of the window and expands the window to cover the adjacent area. If the I / O operation occurs within this window, it is marked as continuous, and the center of the window is subsequently updated. However, this method is prone to errors when I / O is executed out of order. This is because the order of the operations is reversed, which may cause originally continuous I / O operations to be misidentified. This misjudgment is particularly common when multiple I / O streams are running simultaneously, because out-of-order execution frequently changes the base position of the sliding window, increasing the complexity of continuity determination.
[0003] In view of this, an IO processing method is needed to ensure that even when IO requests are out of order, requests can be accurately identified and marked, providing precise instructions for subsequent IO processing and improving the overall performance of the system. Summary of the Invention
[0004] In view of this, the present invention provides an IO processing method, apparatus, device and medium technology field to solve the problem that out-of-order execution of IO requests makes it difficult to accurately identify continuity, resulting in reduced efficiency and accuracy.
[0005] In a first aspect, the present invention provides an IO processing method, comprising: reading each IO request from a waiting queue in sequence and determining a starting stripe ID of each IO request; the waiting queue includes a group of IO requests; for a target IO request in each IO request, if the starting stripe ID of the target IO request matches a target monitoring window in each effective monitoring window, the target IO request is allocated to a target IO queue corresponding to the target monitoring window; and the continuity of the IO requests in the IO queue corresponding to each monitoring window is determined and issued.
[0006] In an optional implementation, determining the continuity of IO requests in the IO queue corresponding to each monitoring window and issuing the same includes:
[0007] If the number of IO requests in the target IO queue is 1, the IO requests in the target IO queue are marked as random IO and issued.
[0008] If the number of IO requests in the target IO queue is greater than 1, the IO requests in the target IO queue are marked as continuous IO and sent.
[0009] In an optional embodiment, the IO processing method further includes: if the starting stripe ID of the target IO request does not match any of the valid monitoring windows, determining whether there is an unused monitoring window;
[0010] If there is no unused monitoring window, the target IO request is assigned to the queue to be retrieved.
[0011] In an optional implementation, if there is an unused monitoring window, the target IO request is allocated to the IO queue corresponding to the unused monitoring window.
[0012] In an optional implementation, after reading of each IO request in the waiting queue is completed, the IO requests in the queue to be migrated are allocated to the waiting queue.
[0013] In an optional implementation, after the IO requests in the IO queues corresponding to the respective monitoring windows are issued, the next group of IO requests is obtained and allocated to the waiting queue.
[0014] In a second aspect, the present invention provides an IO processing device, which includes: an IO reading module, which is used to read each IO request from a waiting queue in sequence and determine the starting stripe ID of each IO request; the waiting queue includes a group of IO requests; an IO allocation module, which is used to allocate the target IO request in each IO request to the target IO queue corresponding to the target monitoring window if the starting stripe ID of the target IO request matches the target monitoring window in each effective monitoring window; and a continuity determination module, which is used to determine the continuity of the IO requests in the IO queue corresponding to each monitoring window and issue them.
[0015] In a third aspect, the present invention provides a computer device comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the IO processing method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.
[0016] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the IO processing method of the first aspect or any corresponding embodiment thereof.
[0017] In a fifth aspect, the present invention provides a computer program product, comprising computer instructions for causing a computer to execute the IO processing method of the first aspect or any corresponding embodiment thereof.
[0018] The technical solution provided by one or more embodiments of the present invention effectively identifies and marks the random or continuous attributes of IO requests within the stripe by monitoring the stripe hit status of the RAID array and combining the reordering mechanism of IO requests. First, each IO request is read from the waiting queue in turn, and its starting stripe ID is determined for each request. In a group of IO requests, the starting stripe ID of the target IO request is matched with the effective monitoring window, and the request will be assigned to the target IO queue corresponding to the monitoring window. The requests in the IO queue corresponding to each monitoring window are evaluated to determine whether these requests are continuous, and finally the IO requests are issued. The present invention improves the efficiency of IO request processing, ensuring that even in the case of disordered IO requests, accurate marking of requests can be achieved, providing precise indications for subsequent IO processing, and improving the overall performance of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the specific embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0020] Figure 1 is a schematic structural diagram of a data storage system according to an embodiment of the present invention;
[0021] Figure 2 is a flowchart of an IO processing method according to an embodiment of the present invention;
[0022] Figure 3 is another flowchart of an IO processing method according to an embodiment of the present invention;
[0023] Figure 4 This is a schematic diagram of an architecture for IO request continuity according to an embodiment of the present invention;
[0024] Figure 5 This is a flowchart of specific implementation steps of a method for IO continuity according to an embodiment of the present invention;
[0025] Figure 6 is a structural block diagram of an IO processing device according to an embodiment of the present invention;
[0026] Figure 7Schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0027] To make the purpose, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative efforts shall fall within the scope of protection of the present invention.
[0028] Please refer to Figure 1 , which shows a schematic diagram of the structure of a data storage system according to an embodiment of the present invention. The data storage system comprises a server 101, which is equipped with a disk array (RAID). A disk array is a large-capacity disk group composed of many independent disks. The synergistic effect of data provided by individual disks improves the performance of the entire disk system. Using this technology, data is divided into multiple segments and stored separately on different hard disks.
[0029] RAID technology is widely adopted for its advantages in improving data storage reliability and performance. However, the randomness and continuity of I / O requests require storage systems to adopt differentiated processing strategies. Inappropriate processing mechanisms can significantly reduce data access efficiency. Traditional marking technologies typically use a sliding window mechanism to monitor the continuity of I / O operations. This method sets the end point of each I / O as the center of the window and expands the window to cover the adjacent area. If the I / O operation occurs within this window, it is marked as continuous, and the center of the window is subsequently updated. However, this method is prone to errors when I / O is executed out of order. This is because the reversed order may cause originally continuous I / O operations to be unable to be correctly identified.
[0030] In order to solve the above problems, an embodiment of the present invention provides an IO processing method, which classifies IOs and then identifies and marks the random / continuous characteristics of IOs to achieve the effect of accurately and efficiently identifying and marking the continuity of IO requests.
[0031] According to an embodiment of the present invention, an IO processing method embodiment is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0032] In this embodiment, an IO processing method is provided. Figure 2 is a flow chart of an IO processing method according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:
[0033] S201 , reading each IO request from a waiting queue in sequence, and determining a starting stripe ID of each IO request; the waiting queue includes a group of IO requests.
[0034] As you can understand, the waiting queue is an IO buffer used to cache received IO commands, read IO requests one by one, and determine the starting stripe ID for each request. The stripe ID identifies the location of data on the storage device and, for RAID systems, determines the physical storage location of the data. An IO request group refers to the collection of all pending IO requests currently in the waiting queue. This step is fundamental to the process and provides necessary information for subsequent IO request processing.
[0035] S202 , for a target IO request in each IO request, if the starting stripe ID of the target IO request matches the target monitoring window in each valid monitoring window, the target IO request is allocated to a target IO queue corresponding to the target monitoring window.
[0036] It's important to note that after reading an I / O request and determining the starting stripe ID, the target I / O request's starting stripe ID is checked and matched against the effective monitoring window. A monitoring window is a mechanism for tracking and processing specific stripe IDs. If the stripe ID of a target I / O request matches a monitoring window, the I / O request is assigned to the target I / O queue associated with that monitoring window. This queue is used to cache and process I / O requests within that specific monitoring window.
[0037] S203: Determine the continuity of IO requests in the IO queues corresponding to the respective monitoring windows and issue them.
[0038] It should be noted that after the target I / O requests are assigned to the queues corresponding to the monitoring windows, the continuity of the I / O requests in these queues is determined. Continuity refers to whether the I / O requests target consecutive data blocks or addresses. I / O requests are issued based on this continuity determination, and there are corresponding processing methods for whether the requests are continuous or random.
[0039] In summary, by monitoring the stripe hits of the RAID array and combining the reordering mechanism of IO requests, the random or continuous attributes of IO requests within the stripe can be effectively identified and marked. First, each IO request is read from the waiting queue in turn, and its starting stripe ID is determined for each request. In a group of IO requests, the starting stripe ID of the target IO request is matched with the effective monitoring window, and the request will be assigned to the target IO queue corresponding to the monitoring window. The requests in the IO queue corresponding to each monitoring window are evaluated to determine whether these requests are continuous, and finally the IO requests are issued. The present invention improves the efficiency of IO request processing, ensures that even in the case of disordered IO requests, accurate marking of requests can be achieved, provides precise indications for subsequent IO processing, and improves the overall performance of the system.
[0040] Figure 3 is a flow chart of an IO processing method according to an embodiment of the present invention. Figure 3 As shown, the process includes the following steps:
[0041] 301 , read each IO request from the waiting queue in sequence, and determine the starting stripe ID of each IO request; the waiting queue includes a group of IO requests.
[0042] 302A, for a target IO request in each IO request, if the starting stripe ID of the target IO request matches a target monitoring window in each effective monitoring window, the target IO request is allocated to a target IO queue corresponding to the target monitoring window.
[0043] Among them, step 301 and step 302A are the same as above Figure 2 The implementation methods of the steps in the illustrated embodiments are similar and will not be repeated here.
[0044] 303A, determine the continuity of IO requests in the IO queue corresponding to each monitoring window and issue them.
[0045] In some optional implementations, if the number of IO requests in the target IO queue is 1, the IO request in the target IO queue is marked as a random IO and issued.
[0046] If the number of IO requests in the target IO queue is greater than 1, the IO requests in the target IO queue are marked as continuous IO and sent.
[0047] The target IO queue refers to the queue corresponding to the monitoring window, which is used to temporarily store IO requests that match the monitoring window. The number of IO requests is 1, which means that there is only one IO request waiting to be processed in the target IO queue. This may be because the request is generated independently, or it is the only request being processed in the current monitoring window. This single IO request is identified as a random IO, indicating that the request is not part of a continuous IO. Sending refers to taking the request marked as random IO out of the waiting state and sending it to the storage device for execution, including removing the request from the queue in the memory and sending the specific read and write operation instructions of the request to the disk or other storage media.
[0048] If the number of I / O requests is greater than 1, it indicates that there are multiple I / O requests waiting to be processed in the queue corresponding to the current monitoring window. These requests are identified and marked as continuous I / O. "Continuous" here means that these requests may be for consecutive data blocks or addresses on the storage device, or that they arrive in a logical order. Once these requests are marked as continuous I / O, they are dispatched—that is, removed from the queue and sent to the storage device for execution.
[0049] 302B: If the starting stripe ID of the target IO request does not match any valid monitoring window, determine whether there is an unused monitoring window.
[0050] The server can check the starting stripe ID of a target IO request to see if it matches the effective monitoring window. If the stripe ID of the target IO request does not match any of the set monitoring windows, it means that there is no existing monitoring window to process this request.
[0051] 303B: If there is no unused monitoring window, the target IO request is assigned to the queue to be retrieved.
[0052] The server checks and finds that there is no matching monitoring window, and there is no available monitoring window in the system to allocate to this request. It then assigns the target IO request to a specific queue, usually called the waiting queue. The waiting queue is used to cache the IO commands to be migrated.
[0053] Therefore, for IO requests that cannot be matched with the existing monitoring window temporarily, these requests can be temporarily stored in the waiting queue to maintain an efficient IO processing process and ensure that all requests can be properly processed in the end.
[0054] 303C: If there is an unused monitoring window, the target IO request is allocated to the IO queue corresponding to the unused monitoring window.
[0055] If there are unused monitoring windows, then for target I / O requests whose starting stripe IDs do not match those in the effective monitoring windows, these requests are assigned to the I / O queues corresponding to these unused monitoring windows. This ensures that I / O requests are effectively managed and processed even in the case of monitoring window mismatches.
[0056] In a possible implementation, after reading of each IO request in the waiting queue is completed, the IO requests in the queue to be migrated are allocated to the waiting queue.
[0057] After all IO requests in the waiting queue are read and processed, the system will reallocate the IO requests in the to-be-migrated queue back to the waiting queue so that it can try to process them again when conditions permit.
[0058] Furthermore, after the IO requests in the IO queues corresponding to the respective monitoring windows are issued, the next group of IO requests is obtained and allocated to the waiting queue.
[0059] After the IO requests in the IO queues corresponding to each monitoring window have been issued and processed, the system will obtain a new set of IO requests and assign them to the waiting queue. This step ensures the continuity of IO request processing, allowing new requests to enter the processing flow, thereby maintaining the storage system's efficiency in processing IO requests.
[0060] These implementations reorder IO through migration and combine the random / continuous characteristics of IO marked with stripes as boundaries, increasing the probability of centralized processing of IO on the same stripe and reducing the mutual exclusion caused by processing the same stripe in batches. This greatly reduces resource overhead, improves IO processing performance, reduces disk-side load, and extends disk life.
[0061] Please refer to Figure 4 , which shows a schematic diagram of an architecture of IO request continuity involved in an embodiment of the present invention, through Figure 4 The architecture shown can implement various methods in the embodiments of the present invention such as Figure 4 As shown,
[0062] WaitQ is the IO buffer used to cache received IO commands; Metadata stores metadata information; the LbaAnalysis module calculates and locates the physical starting position of the IO access space by parsing metadata; the Classification module is responsible for IO classification and migration; the Mintior Window monitoring window is used to filter IO; ClassQ is used to cache classified IO commands; HoldQ is used to cache IO commands to be migrated; and the Mark Feature is responsible for marking IO continuity and delivering it downward.
[0063] Please refer to Figure 5 , which shows a flowchart of specific implementation steps of a method for IO continuity involved in an embodiment of the present invention. Figure 5 As shown, the continuity of IO requests can be identified through the following steps:
[0064] 1. Before the system starts working, it initializes the maximum number of IOs in a single group and the number of ClassQ queues according to the business situation;
[0065] 2. After starting work, if there is IO in the WaitQ queue, it is read out and the stripe ID where the IO starts is determined based on the metadata information;
[0066] 3. A classification check is performed based on the starting stripe ID of the IO, comparing it with all valid monitoring windows. If the stripe IDs are the same, the IO is delivered to the ClassQ pointed to by the matching monitoring window. If the starting stripe ID of the IO does not match the information of any monitoring window, and if there are unused monitoring windows, the stripe ID is registered and bound, and the IO is then delivered to the corresponding ClassQ. Otherwise, the IO is cached in the HoldQ and suspended.
[0067] 4. After all IOs in a group are classified, the IOs in the HoldQ are moved back to the WaitQ and formed into a new group with subsequent IOs, waiting for the next reclassification. At the same time, the status of all ClassQs is checked in sequence. If there is only one IO in a ClassQ, the IO is marked as random and issued. If there are more than one IO in a ClassQ, all IOs are marked as continuous and issued.
[0068] 5. When all IOs in ClassQ are issued, it means that the current Group has been processed. The information in the monitoring window is cleared and recycled, and the IO processing of the next Group begins.
[0069] In summary, by monitoring the stripe hits of the RAID array and combining the reordering mechanism of IO requests, the random or continuous attributes of IO requests within the stripe can be effectively identified and marked. First, each IO request is read from the waiting queue in turn, and its starting stripe ID is determined for each request. In a group of IO requests, the starting stripe ID of the target IO request is matched with the effective monitoring window, and the request will be assigned to the target IO queue corresponding to the monitoring window. The requests in the IO queue corresponding to each monitoring window are evaluated to determine whether these requests are continuous, and finally the IO requests are issued. The present invention improves the efficiency of IO request processing, ensures that even in the case of disordered IO requests, accurate marking of requests can be achieved, provides precise indications for subsequent IO processing, and improves the overall performance of the system.
[0070] This embodiment also provides an IO processing device for implementing the above-mentioned embodiments and preferred embodiments. Details already described will not be repeated here. As used below, the term "module" may refer to a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation using hardware, or a combination of software and hardware, is also possible and contemplated.
[0071] This embodiment provides an IO processing device, such as Figure 6 As shown, including:
[0072] The IO reading module 601 is used to read each IO request from the waiting queue in sequence and determine the starting stripe ID of each IO request; the waiting queue includes a group of IO requests;
[0073] The IO allocation module 602 is configured to allocate the target IO request in each IO request to the target IO queue corresponding to the target monitoring window if the starting stripe ID of the target IO request matches the target monitoring window in each effective monitoring window;
[0074] The continuity determination module 603 is used to determine the continuity of IO requests in the IO queue corresponding to each monitoring window and issue the result.
[0075] In some optional implementations, the continuity determination module 603 includes:
[0076] The first request marking unit is configured to mark the IO request in the target IO queue as a random IO and issue the request if the number of IO requests in the target IO queue is 1.
[0077] The first request marking unit is configured to mark the IO requests in the target IO queue as continuous IO requests and issue them if the number of IO requests in the target IO queue is greater than 1.
[0078] In some optional implementations, the IO processing device further includes:
[0079] The window matching unit is configured to determine whether there is an unused monitoring window if the starting stripe ID of the target IO request does not match any of the valid monitoring windows.
[0080] The relocation allocation unit is configured to allocate the target IO request to the queue to be relocated if there is no unused monitoring window.
[0081] In some optional embodiments, the method further includes:
[0082] The first fetch allocation subunit is configured to allocate the target IO request to an IO queue corresponding to the unused monitoring window if there is an unused monitoring window.
[0083] The second fetch allocation subunit is configured to allocate the IO requests in the to-be-fetched queue to the waiting queue after the reading of each IO request in the waiting queue is completed.
[0084] The third migration allocation sub-unit is configured to obtain the next set of IO requests and allocate them to the waiting queue after the IO requests in the IO queues corresponding to the monitoring windows are issued.
[0085] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0086] The IO processing device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0087] The embodiment of the present invention also provides a computer device having the above Figure 6 The IO processing device shown.
[0088] See also Figure 7 , Figure 7 is a structural diagram of a computer device provided by an optional embodiment of the present invention, such as Figure 7As shown, the computer device includes: one or more processors 10, memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components utilize different buses to communicate with each other and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in the memory or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Equally, multiple computer devices can be connected, and each device provides part of the necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 7 A processor 10 is taken as an example.
[0089] The processor 10 may be a central processing unit, a network processor, or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit, a programmable logic device, or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic, or any combination thereof.
[0090] The memory 20 stores instructions that can be executed by at least one processor 10, so as to enable at least one processor 10 to execute the method shown in the above embodiment.
[0091] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and application programs required for at least one function; the data storage area may store data created based on the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely located relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0092] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid-state drive; the memory 20 may also include a combination of the above types of memory.
[0093] The computer device further includes an input device 30 and an output device 40. The processor 10, the memory 20, the input device 30 and the output device 40 may be connected via a bus or other means. Figure 7 The bus connection is taken as an example.
[0094] The input device 30 can receive input digital or character information and generate key signal input related to user settings and function control of the computer device, such as a touch screen, a keypad, a mouse, a trackpad, a touch pad, an indicator stick, one or more mouse buttons, a trackball, a joystick, etc. The output device 40 can include a display device, an auxiliary lighting device (e.g., an LED), and a tactile feedback device (e.g., a vibration motor). The above-mentioned display device includes but is not limited to a liquid crystal display, a light emitting diode, a display, and a plasma display. In some optional embodiments, the display device can be a touch screen.
[0095] The embodiment of the present invention also provides a computer-readable storage medium. The above-mentioned method according to the embodiment of the present invention can be implemented in hardware, firmware, or implemented as a computer code that can be recorded in a storage medium, or implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and downloaded through a network and will be stored in a local storage medium, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state drive, etc.; further, the storage medium can also include a combination of the above-mentioned types of memory. It can be understood that a computer, a processor, a microprocessor controller or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor or hardware, the method shown in the above embodiment is implemented.
[0096] A portion of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the form in which the computer program instruction exists in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc. Accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium that can be accessed by the computer.
[0097] Although the embodiments of the present invention have been described with reference to the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention. Such modifications and variations are all within the scope defined by the appended claims.
Claims
1. An IO processing method, characterized in that: The method comprises: Reading each IO request from a waiting queue in sequence and determining a starting stripe ID of each IO request; the waiting queue includes a group of IO requests; For a target IO request in each of the IO requests, if the starting stripe ID of the target IO request matches the target monitoring window in each of the effective monitoring windows, the target IO request is allocated to the target IO queue corresponding to the target monitoring window; If the number of IO requests in the target IO queue is 1, the IO request in the target IO queue is marked as random IO and issued; If the number of IO requests in the target IO queue is greater than 1, the IO requests in the target IO queue are marked as continuous IO and issued; If the starting stripe ID of the target IO request does not match any valid monitoring window, determining whether there is an unused monitoring window; If there is an unused monitoring window, the unused monitoring window is bound to the stripe ID corresponding to the target IO request, and the target IO request is allocated to the IO queue corresponding to the unused monitoring window; The method further comprises: If there is no unused monitoring window, the target IO request is allocated to the queue to be retrieved.
2. The method according to claim 1, characterized in that The method further comprises: After all IO requests in the waiting queue are read, the IO requests in the queue to be migrated are allocated to the waiting queue.
3. The method according to claim 2, characterized in that The method further comprises: After the IO requests in the IO queues corresponding to the monitoring windows are issued, the next group of IO requests is obtained and allocated to the waiting queue.
4. An IO processing device, characterized in that: The device comprises: An IO reading module is used to read each IO request from a waiting queue in sequence and determine a starting stripe ID of each IO request; the waiting queue includes a group of IO requests; an IO allocation module, configured to allocate, for a target IO request among the IO requests, to a target IO queue corresponding to the target monitoring window if a starting stripe ID of the target IO request matches a target monitoring window among the effective monitoring windows; a continuity determination module, configured to mark the IO requests in the target IO queue as random IOs and issue them if the number of IO requests in the target IO queue is 1; and mark the IO requests in the target IO queue as continuous IOs and issue them if the number of IO requests in the target IO queue is greater than 1; The IO allocation module is further configured to determine whether there is an unused monitoring window if the starting stripe ID of the target IO request does not match any of the valid monitoring windows; If there is an unused monitoring window, the unused monitoring window is bound to the stripe ID corresponding to the target IO request, and the target IO request is allocated to the IO queue corresponding to the unused monitoring window; The IO allocation module is further used to: If there is no unused monitoring window, the target IO request is allocated to the queue to be retrieved.
5. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the method according to any one of claims 1 to 3 by executing the computer instructions.
6. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 3.
Citation Information
Patent Citations
IO scheduling method, device and equipment and computer readable storage medium
CN113655970A
Task processing method, device and equipment and readable storage medium
CN117453134A