[go: up one dir, main page]

CN113419669B - IO request processing method, device, electronic device and computer readable medium - Google Patents

IO request processing method, device, electronic device and computer readable medium Download PDF

Info

Publication number
CN113419669B
CN113419669B CN202110172628.XA CN202110172628A CN113419669B CN 113419669 B CN113419669 B CN 113419669B CN 202110172628 A CN202110172628 A CN 202110172628A CN 113419669 B CN113419669 B CN 113419669B
Authority
CN
China
Prior art keywords
request
original
return
storage
node
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110172628.XA
Other languages
Chinese (zh)
Other versions
CN113419669A (en
Inventor
杨丰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN202110172628.XA priority Critical patent/CN113419669B/en
Publication of CN113419669A publication Critical patent/CN113419669A/en
Application granted granted Critical
Publication of CN113419669B publication Critical patent/CN113419669B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/061Improving I/O performance
    • G06F3/0611Improving I/O performance in relation to response time
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • G06F3/0635Configuration or reconfiguration of storage systems by changing the path, e.g. traffic rerouting, path reconfiguration
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Computer And Data Communications (AREA)
  • Debugging And Monitoring (AREA)

Abstract

本申请实施例提供了一种IO请求处理方法、装置、电子设备及计算机可读介质,涉及计算机技术领域。所述方法包括:接收计算节点发送的原始IO请求,对原始IO请求进行克隆,得到第一IO请求;如果在原始IO请求对应的第一超时时间到达时,接收到针对第一IO请求的返回,将针对第一IO请求的返回发送至计算节点;如果在第一超时时间到达时,未接收到针对第一IO请求的返回,对原始IO请求进行克隆,得到第二IO请求;将第二IO请求发送至分布式存储集群中的其他存储节点,以通过其他存储节点获取针对第二IO请求的返回,并发送至计算节点。本申请在存储集群内部发生网络单点故障时,可以降低时延,以实现对业务IO的快速响应。

The embodiments of the present application provide an IO request processing method, device, electronic device and computer-readable medium, which relate to the field of computer technology. The method includes: receiving an original IO request sent by a computing node, cloning the original IO request to obtain a first IO request; if a return for the first IO request is received when the first timeout period corresponding to the original IO request arrives, the return for the first IO request is sent to the computing node; if a return for the first IO request is not received when the first timeout period arrives, the original IO request is cloned to obtain a second IO request; the second IO request is sent to other storage nodes in the distributed storage cluster to obtain the return for the second IO request through other storage nodes, and send it to the computing node. When a single point of network failure occurs within the storage cluster, the present application can reduce latency to achieve a rapid response to business IO.

Description

IO request processing method and device, electronic equipment and computer readable medium
Technical Field
The embodiment of the application relates to the technical field of computers, in particular to an input/output (IO) request processing method, an apparatus, electronic equipment and a computer readable medium.
Background
Enterprise-level users typically have high demands on availability, performance, etc. of distributed storage, and particularly on availability metrics (including latency, data consistency, failure self-healing rate, etc.). At present, the mainstream manufacturer can well guarantee availability indexes such as data consistency, fault self-healing rate and the like. However, the lack of an effective solution on the low-latency index requirement, which is a network single-point failure rather than a common failure, often causes time-out or even interruption of user traffic, and does not satisfy the current strong demand of enterprise-level users on low-latency response.
When a network single point fault occurs in the storage cluster, an Input/Output (IO) retry is initiated by a dependent computing node or an IO termination command/IO reset request is sent, so that IO response delay of the computing node cannot be ensured, and user service is often blocked, and even overtime interruption is caused.
Disclosure of Invention
The application aims to provide an IO request processing method, an IO request processing device, electronic equipment and a computer readable medium, which are used for solving the technical problem that the processing IO request has longer delay when network single-point faults occur in a storage cluster in the prior art.
According to a first aspect of an embodiment of the present application, there is provided an IO request processing method applied to a1 st storage node in a distributed storage cluster, including:
receiving an original IO request sent by a computing node, and cloning the original IO request to obtain a first IO request;
If a first timeout time corresponding to the original IO request arrives, receiving a return for the first IO request, and sending the return for the first IO request to the computing node;
if the return for the first IO request is not received when the first timeout time is reached, cloning the original IO request to obtain a second IO request;
And sending the second IO request to other storage nodes in the distributed storage cluster, so as to acquire a return for the second IO request through the other storage nodes, and sending the return for the second IO request to the computing node.
According to a second aspect of an embodiment of the present application, there is provided an IO request processing apparatus applied to a1 st storage node in a distributed storage cluster, including:
The IO request cloning module is used for receiving an original IO request sent by the computing node, and cloning the original IO request to obtain a first IO request;
The first return sending module is used for sending the return for the first IO request to the computing node if the return for the first IO request is received when the first timeout time corresponding to the original IO request is reached;
the IO request sending module is used for cloning the original IO request to obtain a second IO request if the return of the first IO request is not received when the first timeout time is reached; sending the second IO request to other storage nodes in the distributed storage cluster to acquire a return for the second IO request through the other storage nodes;
And the second return sending module is used for sending the return for the second IO request to the computing node.
According to a third aspect of an embodiment of the present application, there is provided an electronic device including a processor, a memory, a communication interface, and a communication bus, the processor, the memory, and the communication interface completing communication with each other through the communication bus;
The memory is configured to store at least one executable instruction, where the executable instruction causes the processor to perform the method for processing an IO request according to the first aspect of the foregoing embodiment.
According to a fourth aspect of embodiments of the present application, there is provided a computer readable medium having stored thereon a computer program which, when executed by a processor, implements the IO request processing method according to the first aspect of the above embodiments.
According to the IO request processing method, when a network single-point fault occurs in the storage cluster, the original IO request is cloned, the cloned IO request is sent to other storage nodes in the storage cluster, and the other storage nodes are used for processing, so that the delay of the IO request can be actively controlled. The application fully utilizes the advantages of distributed storage multi-node service, realizes the quick response to the service IO request of the computing node, solves the problem of user service damage caused by single-point faults of the network in the storage cluster, and meets the requirement of users on low-delay high-availability indexes.
Drawings
Other features, objects and advantages of the present application will become more apparent upon reading of the detailed description of non-limiting embodiments, made with reference to the accompanying drawings in which:
FIG. 1 is a schematic diagram of a related art system in which a single point network single point failure causes a user service to be damaged;
FIG. 2 is a flowchart of a method for processing IO requests according to an embodiment of the present application;
FIG. 3 is a flowchart of a method for processing IO requests according to an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of a scenario of an IO request processing method according to an embodiment of the present application;
FIG. 5 is a schematic diagram of a scenario of timeout adaptation in an embodiment of the present application;
FIG. 6 is a schematic diagram of an IO request processing device according to an embodiment of the present application;
Fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The application is described in further detail below with reference to the drawings and examples. It is to be understood that the specific embodiments described herein are merely configured to illustrate the related application, and are not limiting of the application. It should be noted that, for convenience of description, only the portions related to the present application are shown in the drawings.
It should be noted that, without conflict, the embodiments of the present application and features of the embodiments may be combined with each other. The application will be described in detail below with reference to the drawings in connection with embodiments.
With the development of information technology, the amount of data to be stored is increasing. The distributed storage system adopts an expandable system structure, and utilizes a plurality of storage servers to share the storage load, so that the reliability, availability and access efficiency of the system are improved, and the system is easy to expand.
In a storage system based on the SCSI (Small Computer system interface) protocol, a distributed storage cluster may contain multiple storage nodes, and a computing node may send IO requests (read requests or write requests) to the storage nodes to read data from or write data to the hard disk via the storage nodes. SCSI is an independent processor standard for system-level interfaces between computers and their peripherals (hard disk, floppy drive, optical drive, printer, scanner, etc.).
Referring to fig. 1, fig. 1 is a schematic diagram of a related art system in which a single point of network single point of failure causes a user service to be damaged. Where a LUN is a number that is used to identify a logical unit that is a device addressed by SCSI. That is, the storage system partitions the physical hard disk into portions having logical addresses, and allows the compute nodes to access, and such a partition is a LUN. It can be seen that the storage node 1 has a network single point of failure, in this case, if the relying computing node initiates an IO retry, or sends a termination IO command/reset IO request, the IO response delay of the computing node cannot be actively ensured, which easily causes user traffic to be blocked, and even causes a timeout interrupt.
In order to solve the above problems, embodiments of the present application provide a method, an apparatus, an electronic device, and a computer readable medium for processing an IO request, which can actively control a delay of processing the IO request when a network single point failure occurs in a storage group, so as to implement a fast response to a service IO of a computing node.
The following first describes in detail an IO request processing method according to an embodiment of the present application.
The IO request processing method of the embodiment of the application can be applied to the 1 st storage node in the distributed storage cluster, wherein the distributed storage cluster can generally comprise a plurality of storage nodes, and the 1 st storage node can be any storage node in the distributed storage cluster.
Referring to fig. 2, fig. 2 is a flowchart of a method for processing an IO request according to an embodiment of the present application, which may include the following steps:
Step S210, an original IO request sent by a computing node is received, and cloning is carried out on the original IO request to obtain a first IO request.
In the embodiment of the application, when a user uses a disk of a storage system, the basic operation includes reading data of the disk or writing data into the disk, and each read and write request is an IO request. When a user reads data or writes data through the computing node, an IO request can be sent to the storage node, the storage node receiving the IO request is the 1 st storage node, and the IO request sent to the 1 st storage node by the computing node is the original IO request. Cloning the original IO request refers to cloning an IO request with the same attribute as the original IO request, namely the attribute of a first IO request obtained by cloning is identical to the attribute of the original IO request.
For example, if the original IO request is a read request, the original IO request includes the address to be read, which data to be read, and so on. Then the address to be read in the first IO request and which data to read are cloned to be the same as the address to be read in the original IO request and which data to read.
Step S220, if a return for the first IO request is received when the first timeout corresponding to the original IO request arrives, the return for the first IO request is sent to the computing node.
In the embodiment of the application, after the first IO request is obtained, the 1 st storage node can read data or write data through the first path, and after successful reading or successful writing, the 1 st storage node can receive the return of the first IO request, otherwise, the return of the first IO request cannot be received.
It should be noted that, the first timeout period corresponding to the original IO request refers to the longest time for responding to the original IO request. The first timeout time is attribute information of the original IO request, so that after cloning, the first timeout time corresponding to the first IO request is the first timeout time corresponding to the original IO request. If the first timeout time arrives, a return for the first IO request is received, which means that there is no delay, and the service requirement can be satisfied, and the return for the first IO request is directly sent to the computing node.
Wherein receiving a return for the first IO request upon arrival of the first timeout includes receiving a return for the first IO request upon arrival of the first timeout, i.e., the time at which the return for the first IO request was received is before the arrival of the first timeout, and receiving a return for the first IO request upon arrival of the first timeout. For example, assuming a first timeout time of 5 seconds, if a return for the first IO request is received within 5 seconds (3 seconds, 4 seconds, 5 seconds, etc.), the return for the first IO request is sent to the compute node.
In step S230, if the return for the first IO request is not received when the first timeout period arrives, the original IO request is cloned, and a second IO request is obtained.
Corresponding to the foregoing process, if the return for the first IO request is not received when the first timeout period arrives, this indicates that a delay occurs, and a single point of failure of the network may occur, which cannot meet the service requirement. If the computing node retries, or sends a terminate IO command/reset IO request, a delay still occurs, possibly because the failure is not timely eliminated.
In order to avoid the problem, the application re-clones the original IO request to obtain a second IO request, and processes the second IO request through other storage nodes in the distributed storage cluster. Of course, the original IO request, the first IO request, and the second IO request are all identical in attribute.
Step S240, the second IO request is sent to other storage nodes in the distributed storage cluster, so as to obtain a return for the second IO request through the other storage nodes, and send the return for the second IO request to the computing node.
In the embodiment of the present application, after the second IO request is obtained, the 1 st storage node may send the second IO request to other storage nodes in the distributed storage cluster, where the other storage nodes may be any storage node except the 1 st storage node. For example, when the second IO request is sent to the 2 nd storage node, the 2 nd storage node may read data or write data through the second path. Likewise, after the read or write is successful, a return to the second IO request may be received, otherwise, a return to the second IO request may not be received.
If the 2 nd storage node receives the return for the second IO request, the return for the second IO request may be sent to the 1 st storage node, and further, the 1 st storage node sends the return for the second IO request to the storage node.
If the 2 nd storage node does not receive the return for the second IO request, the 1 st storage node cannot receive the return for the second IO request, and the 1 st storage node can be recloned to further acquire the return for the second IO request through other storage nodes.
In yet another alternative embodiment, if the 1 st storage node does not receive the return for the first IO request when the first timeout period expires, the original IO request may be cloned multiple times to obtain multiple second IO requests, and the multiple second IO requests are sent to different storage nodes respectively, so that the return for the second IO requests is obtained through multiple different storage nodes at the same time. In this way, the time delay can be further shortened.
According to the IO request processing method, when a network single-point fault occurs in the storage cluster, the original IO request is cloned, the cloned IO request is sent to other storage nodes in the storage cluster, and the other storage nodes are used for processing, so that the delay of the IO request can be actively controlled. The application fully utilizes the advantages of distributed storage multi-node service, realizes the quick response to the service IO request of the computing node, solves the problem of user service damage caused by single-point faults of the network in the storage cluster, and meets the requirement of users on low-delay high-availability indexes.
Referring to fig. 3, fig. 3 is a flowchart of another method for processing an IO request according to an embodiment of the present application, which may include the following steps:
step S310, an original IO request sent by a computing node is received, and cloning is carried out on the original IO request to obtain a first IO request.
In the embodiment of the application, after the original IO request sent by the computing node is received, the information of the original IO request can be recorded in the IO local linked list. The information of the original IO request comprises the complete content of the original IO request (comprising the address and data of the request and the like) and the receiving moment. Thus, cloning can be performed according to the original IO request in the IO local linked list, and a first IO request is obtained.
Step S320, determining whether a return for the first IO request is received when the first timeout time arrives.
As described above, if the return for the first IO request is received when the first timeout corresponding to the original IO request arrives, indicating that no delay occurs, step S330 may be performed, and if the return for the first IO request is not received when the first timeout arrives, indicating that delay occurs, step S340 may be performed.
In the embodiment of the application, the first timeout time corresponding to the original IO requests of different types can be different so as to adapt to different service requirements. For example, for the administration class command, the first timeout time may be longer, for example, 20 seconds, 30 seconds, etc. For read requests that require a relatively high response, the first timeout may be shorter, for example, 1 second, 2 seconds, etc.
Step S330, send the return for the first IO request to the compute node.
Step S340, cloning the original IO request to obtain a second IO request.
And step S350, sending a second IO request to an ith storage node in the distributed storage cluster, wherein the initial value of i is 2.
In the embodiment of the present application, after step S340 is performed for the first time, the second IO request may be sent to the 2 nd storage node. The 2 nd storage node is any other storage node except the 1 st storage node in the distributed storage cluster. Since the embodiment of the present application includes a loop process, after the second execution of step S340, the second IO request may be sent to the 3 rd storage node, and so on.
Step S360, determining whether to receive a return for the second IO request sent by the ith storage node when the first timeout period arrives.
In the embodiment of the present application, if the 1 st storage node receives the return for the second IO request sent by the i-th storage node when the first timeout period arrives, which means that the i-th storage node has received the return for the second IO request, no time delay occurs in the i-th storage node, and step S370 is executed. If the ith storage node does not receive the return for the second IO request when the first timeout period has arrived, indicating that a delay has occurred also at the ith storage node, step S380 may be performed.
When the original IO request is a read request, the return to the first/second IO request includes the read content and the read status, and when the original IO request is a write request, the return to the first/second IO request includes the write status. The status of the read may be successful or failed, and the status of the write may be successful or failed.
Step S370, send the return for the second IO request to the compute node.
In step S380, it is determined whether the value of i is equal to n.
Step S390, the value of i is added to 1, and the process returns to step S340.
In the embodiment of the present application, n may represent the total number of times of processing the IO request, for example, may be 2, 3, or 5. Assuming that the value of n is 3, in the case that the 1 st storage node has time delay, the 1 st storage node has processed the first IO request once, then the original IO request may be cloned, and the 2 nd storage node may process the second IO request obtained. If no time delay occurs, the 2 nd storage node sends the return of the second IO request to the 1 st storage node, and if the time delay occurs, the original IO request is cloned again by executing the circulating process, and the obtained second IO request is processed by the 3 rd storage node. If the time delay still occurs, the 3 rd storage node indicates that the time delay is longer, the circulation process is not executed any more, and the flow is ended.
In addition, n may also represent the total number of storage nodes in the distributed storage cluster, where n is an integer greater than 1. When the value of i is smaller than n, which indicates that there are storage nodes in the distributed storage cluster that have not processed the second IO request, the above-mentioned loop process may be executed, and the second IO request is obtained by recloning, and is processed. When the value of i is equal to n, it means that all storage nodes in the distributed storage cluster process the second IO request, and still do not receive the return of the second IO request, and at this time, it may happen that faults occur in the distributed storage cluster, and quick response to service IO cannot be guaranteed.
In the embodiment of the application, after the return of the first/second IO request is sent to the computing node, the response to the original IO request is completed, so that the information of the original IO request in the IO local chain table can be cleared, and the occupied storage space is avoided.
In the embodiment of the application, the first overtime time can be adaptively updated to meet the change of the time delay requirement of different services, and the method specifically comprises the following steps:
The first timeout period is assumed to be a value preset according to the service requirement, or may be a value already adaptively adjusted according to the previous service requirement. In the case that the user feels the time delay, the computing node can send a termination IO command to the 1 st storage node, and the IO request sent before is expected to return to the computing node side for retry. If the 1 st storage node receives a termination IO command for the original IO request sent by the computing node, the first timeout time cannot meet the requirement of the user. The first timeout may be updated according to a time of receipt of the terminate IO command and a time of receipt of the original IO request.
Specifically, if the 1 st storage node does not receive the termination IO command sent by the computing node when the first timeout period arrives, it indicates that the first timeout period can meet the service requirement of the user, and the first timeout period may not be updated. If the 1 st storage node receives the termination IO command sent by the computing node when the first timeout time arrives, or receives the termination IO command before the first timeout time arrives, which indicates that the first timeout time cannot meet the service requirement of the user, the first timeout time can be updated according to the receiving time of the termination IO command and the receiving time of the original IO request.
In an alternative implementation manner, the product of the difference between the receiving time of the termination IO command and the receiving time of the original IO request and a preset coefficient is taken as a second timeout time, wherein the preset coefficient is greater than 0 and less than 1, and the first timeout time is updated to be the second timeout time. Thus, when the same type of IO request is received next time and the first timeout time arrives, the return for the IO request is received, and the service requirement of the user can be met.
In the embodiment of the application, after updating the first timeout, the first timeout may also be sent to other storage nodes in the distributed storage cluster. Thus, when other storage nodes receive the IO request sent by the computing node, the other storage nodes can respond to the IO request in time according to the updated first timeout time, and time delay is avoided.
According to the IO request processing method provided by the embodiment of the application, when a network single-point fault occurs in the storage cluster, the original IO request is cloned, the cloned IO request is sent to other storage nodes in the storage cluster, and the processing is performed through the other storage nodes, so that the delay of the IO request can be actively controlled. The application fully utilizes the advantages of distributed storage multi-node service, realizes the quick response to the service IO request of the computing node, solves the problem of user service damage caused by single-point faults of the network in the storage cluster, and meets the requirement of users on low-delay high-availability indexes. In addition, the timeout time of different types of IO requests can be self-adapted in real time according to the termination IO command issued by the computing node, and the requirement change of the service of the computing node on IO delay can be timely met.
Referring to fig. 4, fig. 4 is a schematic view of a scenario of an IO request processing method according to an embodiment of the present application, and the above process is described in the following with reference to fig. 4.
As shown in fig. 4, when a user wants to read data from a disk, or write data to a disk, an original IO request may be sent to storage node 1 by a computing node. After receiving the original IO request, the storage node 1 records the information of the original IO request into an IO local linked list. Assuming that the original IO request is a read request, an address to be read by the original IO request, data to be read, and a receiving time of the original IO request may be recorded in an IO local linked list.
The storage node 1 may clone the original IO request to obtain a first IO request and read the data through the path 1. However, due to the failure, the storage node 1 will not receive a return for the first IO request when the first timeout has arrived. Then, the storage node 1 clones the original IO request again to obtain a second IO request, and sends the second IO request to the storage node 2 through the path 2, and the storage node 2 can read data through the path 3.
If the storage node 2 receives a return for the second IO request when the first timeout period has arrived, the return for the second IO request may be sent to the storage node 1, and the storage node 1 sends the return for the second IO request to the computing node, and the flow ends.
If the storage node 2 does not receive a return for the second IO request when the first timeout period has arrived, similarly, the storage node 1 may further clone the original IO request again to obtain the second IO request, send the second IO request to the storage node 3 through the path 4, and obtain the return for the second IO request through the storage node 3.
Similarly, the return for the second IO request may also be obtained by the storage node 4, the storage node 5, or the like, and sent to the computing node. And then, the information of the original IO request in the IO local chain table can be cleared, so that the storage space is saved.
According to the process, when a network single-point fault occurs, the application can actively control the time delay so as to realize quick response to service IO.
Referring to fig. 5, fig. 5 is a schematic diagram of a scenario of timeout adaptation in an embodiment of the present application, and the above procedure is exemplarily described with reference to fig. 5.
As shown in fig. 5, after the user has sent the original IO request to the storage node 1 through the computing node, if the user perceives a timeout, a termination IO command may be sent to the storage node 1, where the original IO request sent before is expected to be returned to the computing node side for retry. The storage node 1 calculates a second timeout time according to the receiving time of the termination IO command and the receiving time of the original IO request stored in the IO local linked list, and updates the first timeout time to the second timeout time. Of course, the second timeout is smaller than the difference between the receive time of the terminating IO command and the receive time of the original IO request. In this way, according to the updated first timeout time, the return for the IO request is sent to the computing node, so that the service requirement of the user can be met.
According to the process, the method and the device can perform real-time timeout time self-adaption according to the termination IO command issued by the computing node, so that the change of the demand of business application of the computing node on IO delay is timely met.
Corresponding to the embodiment of the method, the embodiment of the application also provides an IO request processing device which is applied to the 1 st storage node in the distributed storage cluster. Referring to fig. 6, fig. 6 is a schematic structural diagram of an IO request processing apparatus according to an embodiment of the present application, which may include:
The IO request cloning module 610 is configured to receive an original IO request sent by a computing node, and clone the original IO request to obtain a first IO request;
a first return sending module 620, configured to send a return for the first IO request to the computing node if a return for the first IO request is received when a first timeout time corresponding to the original IO request arrives;
the IO request sending module 630 is configured to, if the return for the first IO request is not received when the first timeout time arrives, clone the original IO request to obtain a second IO request;
A second return sending module 640, configured to send a return for the second IO request to the computing node.
In an optional embodiment, the IO request processing apparatus further includes:
The information recording module is used for recording the information of the original IO request into the IO local linked list after receiving the original IO request sent by the computing node;
and the information clearing module is used for clearing the information of the original IO request in the IO local chain table after sending the return for the first/second IO request to the computing node.
In an alternative embodiment, the information of the original IO request comprises the receiving time of the original IO request;
the IO request processing device of the embodiment of the application further comprises:
And the timeout time updating module is used for updating the first timeout time according to the receiving time of the termination IO command and the receiving time of the original IO request if the termination IO command for the original IO request sent by the computing node is received.
In an alternative embodiment, the timeout period updating module is specifically configured to take a product of a difference between a time of receiving the termination IO command and a time of receiving the original IO request and a preset coefficient as a second timeout period, where the preset coefficient is greater than 0 and less than 1, and update the first timeout period to the second timeout period.
In an optional embodiment, the IO request processing apparatus further includes:
and the timeout time sending module is used for sending the first timeout time to other storage nodes in the distributed storage cluster.
In an alternative embodiment, the IO request sending module 630 includes:
the cloning unit is used for cloning the original IO request to obtain a second IO request;
A sending unit, configured to send a second IO request to an ith storage node, where an initial value of i is 2;
The receiving unit is used for receiving the return of the second IO request sent by the ith storage node if the return of the second IO request is received by the ith storage node when the first timeout time is reached;
And the circulation unit is used for adding 1 to the value of i and returning to the cloning unit until the value of i is equal to n, wherein n is an integer greater than 1, if the ith storage node does not receive the return of the second IO request when the first timeout time arrives.
In an alternative embodiment, the first timeout times corresponding to the different types of original IO requests are different.
In an alternative embodiment, the return for the first/second IO request includes read contents and read status if the original IO request is a read request, and the return for the first/second IO request includes write status if the original IO request is a write request.
The IO request processing device provided in this embodiment is configured to implement the corresponding IO request processing method in the foregoing multiple method embodiments, and has the beneficial effects of the corresponding method embodiments, which are not described herein again.
It should be noted that, according to implementation requirements, each module/step described in the embodiments of the present application may be split into more modules/steps, or two or more modules/steps or part of operations of the modules/steps may be combined into new modules/steps, so as to achieve the purposes of the embodiments of the present application.
Fig. 7 is a schematic diagram of an electronic device according to an embodiment of the present application, where the electronic device may include a processor 702, a communication interface 704, a memory 706, and a communication bus 708.
Wherein the processor 702, the communication interface 704, and the memory 706 communicate with each other via a communication bus 708.
Communication interface 704 for communicating with other electronic devices or servers.
The processor 702 is configured to execute the program 710, and may specifically perform relevant steps in the embodiments of the method for processing an IO request.
In particular, program 710 may include program code including computer-operating instructions.
The processor 702 may be a Central Processing Unit (CPU) or an Application-specific integrated Circuit (ASIC) or one or more integrated circuits configured to implement embodiments of the present application. The one or more processors included in the smart device may be the same type of processor, such as one or more CPUs, or different types of processors, such as one or more CPUs and one or more ASICs.
Memory 706 for storing programs 710. The memory 706 may comprise high-speed RAM memory or may further comprise non-volatile memory (non-volatile memory), such as at least one disk memory.
The program 710 may be specifically configured to cause the processor 702 to perform the corresponding steps in the above-described embodiments of the method for processing an IO request.
The specific implementation of each step in the program 710 may refer to the corresponding steps and corresponding descriptions in the units in the above-mentioned preferred method embodiment, which are not repeated herein. It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the apparatus and modules described above may refer to corresponding procedure descriptions in the foregoing method embodiments, which are not repeated herein.
As a further aspect, the present application also provides a computer readable medium, which may be comprised in the apparatus described in the above embodiments, or may be present alone, without being assembled into the apparatus. The computer-readable medium carries one or more programs that when executed implement the method of IO request processing.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code configured to perform the method shown in the flow chart. In such embodiments, the computer program may be downloaded and installed from a network via a communication portion, and/or installed from a removable medium. The above-described functions defined in the method of the application are performed when the computer program is executed by a central processor.
The computer readable medium according to the present application may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable medium can be, for example but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of a computer-readable storage medium may include, but are not limited to, an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access storage medium (RAM), a read-only storage medium (ROM), an erasable programmable read-only storage medium (EPROM or flash memory), an optical fiber, a portable compact disc read-only storage medium (CD-ROM), an optical storage medium, a magnetic storage medium, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present application, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, radio frequency, etc., or any suitable combination of the foregoing.
The expressions "first", "second", "said first" or "said second" as used in the various embodiments of the application may modify various components without regard to order and/or importance, but these expressions do not limit the respective components. The above description is only configured for the purpose of distinguishing an element from other elements. For example, the first user device and the second user device represent different user devices, although both are user devices. For example, a first element could be termed a second element, and, similarly, a second element could be termed a first element, without departing from the scope of the present disclosure.
The above description is only illustrative of the preferred embodiments of the present application and of the principles of the technology employed. It will be appreciated by persons skilled in the art that the scope of the application referred to in the present application is not limited to the specific combinations of the technical features described above, but also covers other technical features formed by any combination of the technical features described above or their equivalents without departing from the inventive concept described above. Such as the above-mentioned features and the technical features disclosed in the present application (but not limited to) having similar functions are replaced with each other.

Claims (11)

1. An input/output IO request processing method is applied to a1 st storage node in a distributed storage cluster, and comprises the following steps:
the 1 st storage node receives an original IO request sent by a computing node, and clones the original IO request to obtain a first IO request;
If the 1 st storage node receives the return of the first IO request when the first timeout time corresponding to the original IO request is reached, sending the return of the first IO request to the computing node;
if the first timeout time arrives, the 1 st storage node does not receive the return of the first IO request, and clones the original IO request to obtain a second IO request;
The 1 st storage node sends the second IO request to other storage nodes in the distributed storage cluster, so that the return of the second IO request is obtained through the other storage nodes, and the return of the second IO request is sent to the computing node, wherein the other storage nodes are any storage nodes except the 1 st storage node in the distributed storage cluster.
2. The method of claim 1, wherein the method further comprises:
After receiving the original IO request sent by the computing node, recording information of the original IO request into an IO local linked list;
After sending a return for the first/second IO request to the compute node, the information of the original IO request in the IO local linked list is purged.
3. The method of claim 2, wherein the information of the original IO request includes a receipt time of the original IO request;
The method further comprises the steps of:
And if a termination IO command for the original IO request sent by the computing node is received, updating the first timeout time according to the receiving time of the termination IO command and the receiving time of the original IO request.
4. The method of claim 3, wherein the updating the first timeout period based on the receive time of the terminate IO command and the receive time of the original IO request comprises:
Taking the product of the difference value between the receiving time of the termination IO command and the receiving time of the original IO request and a preset coefficient as a second timeout time, wherein the preset coefficient is more than 0 and less than 1;
updating the first timeout to the second timeout.
5. A method according to claim 3, wherein after said updating of said first timeout period, the method further comprises:
And sending the first timeout time to other storage nodes in the distributed storage cluster.
6. The method of claim 1, wherein the cloning the original IO request to obtain a second IO request, sending the second IO request to other storage nodes in the distributed storage cluster to obtain a return for the second IO request through the other storage nodes, comprises:
Cloning the original IO request to obtain a second IO request, and sending the second IO request to an ith storage node, wherein the initial value of i is 2;
if the ith storage node receives the return for the second IO request when the first timeout time arrives, receiving the return for the second IO request sent by the ith storage node;
and if the first timeout time is reached, the ith storage node does not receive the return of the second IO request, adding 1 to the value of i, and returning to the step of cloning the original IO request to obtain the second IO request until the value of i is equal to n, wherein n is an integer greater than 1.
7. The method of claim 1, wherein the first timeout times corresponding to the original IO requests of different types are different.
8. The method of claim 1, wherein, if the original IO request is a read request, the return for the first/second IO request includes read content and read status;
If the original IO request is a write request, the return for the first/second IO request includes a status of write.
9. An IO request processing apparatus, applied to a1 st storage node in a distributed storage cluster, includes:
The IO request cloning module is positioned in the 1 st storage node and is used for receiving an original IO request sent by a computing node, cloning the original IO request and obtaining a first IO request;
the first return sending module is located in the 1 st storage node and is used for sending the return for the first IO request to the computing node if the return for the first IO request is received when a first timeout time corresponding to the original IO request arrives;
The IO request sending module is positioned in the 1 st storage node and used for cloning the original IO request to obtain a second IO request if the return of the first IO request is not received when the first timeout time arrives; sending the second IO request to other storage nodes in the distributed storage cluster to acquire a return for the second IO request through the other storage nodes, wherein the other storage nodes are any storage nodes except the 1 st storage node in the distributed storage cluster;
And the second return sending module is positioned in the 1 st storage node and is used for sending the return aiming at the second IO request to the computing node.
10. An electronic device comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete communication with each other through the communication bus;
the memory is configured to store at least one executable instruction, where the executable instruction causes the processor to perform the IO request processing method according to any one of claims 1 to 8.
11. A computer readable medium having stored thereon a computer program which when executed by a processor implements the IO request processing method according to any one of claims 1 to 8.
CN202110172628.XA 2021-02-08 2021-02-08 IO request processing method, device, electronic device and computer readable medium Active CN113419669B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110172628.XA CN113419669B (en) 2021-02-08 2021-02-08 IO request processing method, device, electronic device and computer readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110172628.XA CN113419669B (en) 2021-02-08 2021-02-08 IO request processing method, device, electronic device and computer readable medium

Publications (2)

Publication Number Publication Date
CN113419669A CN113419669A (en) 2021-09-21
CN113419669B true CN113419669B (en) 2025-03-14

Family

ID=77711801

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110172628.XA Active CN113419669B (en) 2021-02-08 2021-02-08 IO request processing method, device, electronic device and computer readable medium

Country Status (1)

Country Link
CN (1) CN113419669B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN119473403A (en) * 2025-01-17 2025-02-18 山东云海国创云计算装备产业创新中心有限公司 Read and write request processing method and device, storage medium and electronic device

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106598488A (en) * 2016-11-24 2017-04-26 北京小米移动软件有限公司 Distributed data reading method and device

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5892970A (en) * 1996-07-01 1999-04-06 Sun Microsystems, Inc. Multiprocessing system configured to perform efficient block copy operations
JP3698031B2 (en) * 2000-08-10 2005-09-21 日本電気株式会社 Remote access method to secondary storage device
CN1199461C (en) * 2002-07-26 2005-04-27 华为技术有限公司 Image processing method for conference television system
US7206836B2 (en) * 2002-09-23 2007-04-17 Sun Microsystems, Inc. System and method for reforming a distributed data system cluster after temporary node failures or restarts
CN103023805A (en) * 2012-11-22 2013-04-03 北京航空航天大学 MapReduce system
CN110908604B (en) * 2019-11-08 2021-06-29 浪潮电子信息产业股份有限公司 A request processing delay adjustment method, device, electronic device and storage medium
CN111049883B (en) * 2019-11-15 2022-09-06 北京金山云网络技术有限公司 Data reading method, device and system of distributed table system
CN111355814B (en) * 2020-04-21 2024-04-19 上海润欣科技股份有限公司 Load balancing method, device and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106598488A (en) * 2016-11-24 2017-04-26 北京小米移动软件有限公司 Distributed data reading method and device

Also Published As

Publication number Publication date
CN113419669A (en) 2021-09-21

Similar Documents

Publication Publication Date Title
CN103885895A (en) Write Performance in Fault-Tolerant Clustered Storage Systems
US20120011100A1 (en) Snapshot acquisition processing technique
US10831741B2 (en) Log-shipping data replication with early log record fetching
US9881018B2 (en) File management in thin provisioning storage environments
CN112130748B (en) Data access method, network card and server
US10776173B1 (en) Local placement of resource instances in a distributed system
US12265443B2 (en) Block-storage service supporting multi-attach and health check failover mechanism
JP6299266B2 (en) Data storage method, storage system, program, and storage apparatus
US10846094B2 (en) Method and system for managing data access in storage system
US20220357870A1 (en) Object Tiering In A Distributed Storage System
CN113419669B (en) IO request processing method, device, electronic device and computer readable medium
US10733201B1 (en) Dynamic provisioning for data replication groups
CN118377741B (en) Atomic operation execution system, method and device
US10367886B2 (en) Information processing apparatus, parallel computer system, and file server communication program
US10725874B2 (en) Storage system and connection control device
US8850117B2 (en) Storage apparatus and method maintaining at least an order of writing data
CN107045426B (en) Multi-copy reading method and system
CN109992447A (en) Data copy method, device and storage medium
WO2017098591A1 (en) System comprising computer and storage device, and method for control of system
CN113886097A (en) Data processing method and device
CN111142795A (en) Control method, control device and control device for write operation of distributed storage system
CN113867928A (en) Load balancing method, device and server
US20240168898A1 (en) Distributed queue multi-bus on multi-cpu chips
CN113364615B (en) Method, device, equipment and computer readable medium for rolling upgrade
US10855610B2 (en) Information processing apparatus, information processing system, information processing method, and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40058762

Country of ref document: HK

GR01 Patent grant
GR01 Patent grant