Data packet transmission method, related device, storage medium and computer program product

By adding container identification information and index information to the data packet, it realizes the rapid perception of packet loss in the intelligent computing center network, solves the problem that the timeout retransmission mechanism in the existing technology cannot quickly perceive packet loss, and improves the packet loss detection efficiency and network performance.

CN119052137AActive Publication Date: 2024-11-29CHINA MOBILE COMM LTD RES INST +1

Patent Information

Application Number
CN202411060198.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2024-11-29
Estimated Expiration
2044-08-02

AI Technical Summary

Technical Problem

The existing timeout retransmission mechanism cannot quickly perceive packet loss in the intelligent computing center network, resulting in waste of resources and performance impact.

Method used

By adding container identification information and packet index information to the data packet, the sending end encapsulates the data packet and judges whether there is packet loss based on this information on the receiving end, so as to quickly sense packet loss.

Benefits of technology

It improves the efficiency of packet loss detection, reduces the degree of out-of-order of data packets, alleviates the pressure on the receiving device, and improves network performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119052137A_ABST
    Figure CN119052137A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a data packet transmission method, related equipment, a storage medium and a computer program product. The method comprises the steps that sending end equipment acquires N first data packets in a to-be-transmitted data stream; wherein N is a positive integer; performing packaging processing on each first data packet to obtain N second data packets; wherein each second data packet comprises first information and second information, the first information is used for identifying first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used for identifying first index information of the data packet under each piece of first container identification information; sending the N second data packets to a receiving end device; and the receiving end equipment judges whether a packet loss behavior exists or not based on the first information and the second information, so that the packet loss condition can be quickly sensed, and the packet loss detection efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of transmission and Internet Protocol (IP) technology, and in particular to a data packet transmission method, related equipment, storage medium and computer program product. Background Art

[0002] At present, in the intelligent computing center network, in order to avoid congestion of network links, it is more inclined to adopt a packet-by-packet load balancing method. Although the packet-by-packet load balancing method can ensure that the load levels of each network link are basically the same, the data packets in the network link are out of order. Therefore, an efficient sorting mechanism and packet loss detection mechanism are needed to reorder and detect data packets. The current packet loss detection mechanism mainly adopts a timeout retransmission mechanism. The timeout retransmission mechanism needs to enable a timer (timer) based on each queue pair (Queue Pair, QP), and then start timing for the packet sequence number (Packet Sequence Number, PSN) in sequence. First, the timing will be turned on for the data packet with PSN 0. If it exceeds the set time of the timer, the data packet with PSN 0 will be retransmitted; if the data packet is received within the set time of the timer, the pointer corresponding to the timer will be transferred to the data packet with PSN 1, and so on.

[0003] However, the above timeout retransmission mechanism has only one timer. When the data packet received by the receiving end is lost, it is necessary to wait for the timer to time out to trigger retransmission. The packet loss cannot be detected quickly, thereby greatly wasting resources. Summary of the invention

[0004] In order to solve the problem that the current packet loss detection mechanism cannot quickly sense packet loss, the embodiments of the present application provide a data packet transmission method, related equipment, storage medium and computer program product, which can quickly sense packet loss, thereby improving the efficiency of packet loss detection.

[0005] The technical solution of the embodiment of the present application is implemented as follows:

[0006] In a first aspect, an embodiment of the present application provides a method for transmitting a data packet, the method being applied to a sending end device, the method comprising:

[0007] Obtain N first data packets in the data stream to be transmitted; wherein N is a positive integer;

[0008] Encapsulating each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0009] The N second data packets are sent to a receiving device.

[0010] In a second aspect, an embodiment of the present application provides a method for transmitting a data packet, the method being applied to a receiving device, the method comprising:

[0011] Receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0012] Determine whether there is packet loss based on the first information and the second information.

[0013] In a third aspect, an embodiment of the present application provides a sending end device, the sending end device comprising: an acquisition unit, an encapsulation unit, and a sending unit; wherein:

[0014] The acquisition unit is used to acquire N first data packets in the data stream to be transmitted; wherein N is a positive integer;

[0015] The encapsulation unit is configured to encapsulate each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packets, and the second information is used to identify first index information of the data packets under each of the first container identification information;

[0016] The sending unit is used to send the N second data packets to a receiving end device.

[0017] In a fourth aspect, an embodiment of the present application provides a sending end device, the sending end device comprising: a first processor and a first memory; wherein,

[0018] The first memory is used to store a computer program that can be run on the processor;

[0019] The first processor is used to execute the above-mentioned data packet transmission method when running the computer program.

[0020] In a fifth aspect, an embodiment of the present application provides a receiving end device, the receiving end device comprising: a receiving unit and a judging unit; wherein:

[0021] The receiving unit is configured to receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0022] The judging unit is configured to judge whether there is packet loss based on the first information and the second information.

[0023] In a sixth aspect, an embodiment of the present application provides a receiving end device, the receiving end device comprising: a second processor and a second memory; wherein,

[0024] The second memory is used to store a computer program that can be run on the processor;

[0025] The second processor is used to execute the data packet transmission method described above when running the computer program.

[0026] In a seventh aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program code is stored. When the computer program code is executed by a computer, the data packet transmission method as described above is implemented.

[0027] In an eighth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the data packet transmission method as described above.

[0028] The embodiments of the present application provide a data packet transmission method, related devices, storage media and computer program products, wherein a transmitting end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; each first data packet is encapsulated to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; the N second data packets are sent to a receiving end device; and the receiving end device determines whether there is packet loss based on the first information and the second information. It can be seen that the sending end device can encapsulate each first data packet in the data stream to be transmitted to obtain N second data packets, each second data packet includes first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, and the first container identification information is associated with the transmission path of the data packet, so that the path transmitted by each data packet can be perceived based on the container identification information, reducing the degree of disorder of the data packet, and then the N second data packets can be sent to the receiving end device, and the receiving end device can determine whether there is packet loss based on the first information and the second information, so that the packet loss situation can be quickly perceived and the efficiency of packet loss detection can be improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 A schematic diagram of data packet sorting in the related art;

[0030] Figure 2 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 1 ;

[0031] Figure 3 A schematic diagram of the data packet structure proposed in the embodiment of the present application;

[0032] Figure 4 A schematic diagram of the number of uplinks proposed in an embodiment of the present application;

[0033] Figure 5 A schematic diagram of a process for generating container identification information corresponding to a data packet proposed in an embodiment of the present application;

[0034] Figure 6 A schematic diagram of a process for determining first index information proposed in an embodiment of the present application;

[0035] Figure 7 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 2 ;

[0036] Figure 8 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 3;

[0037] Fig. 9 Schematic diagram of the structure of the transmitting device proposed in the embodiment of the present application Figure 1 ;

[0038] Fig.10 Schematic diagram of the structure of the transmitting device proposed in the embodiment of the present application Figure 2 ;

[0039] Fig.11 Schematic diagram of the structure of the receiving device proposed in the embodiment of the present application Figure 1 ;

[0040] Fig.12 Schematic diagram of the structure of the receiving device proposed in the embodiment of the present application Figure 2 . DETAILED DESCRIPTION

[0041] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. It is understood that the specific embodiments described herein are only used to explain the related applications, rather than to limit the applications. It should also be noted that, for ease of description, only the parts related to the related applications are shown in the drawings.

[0042] Unlike traditional data centers, the intelligent computing center is mainly used to carry artificial intelligence (AI) model training services. Its communication traffic mainly has the characteristics of a small number of flows and a large single-flow bandwidth. In order to avoid link congestion, the packet-by-packet load balancing method is more suitable for intelligent computing center traffic load balancing than the flow-by-flow load balancing method. Although the packet-by-packet load balancing method can ensure that the load levels of each link are basically the same, the packets in the network link are out of order, and the destination side needs an efficient sorting mechanism and packet loss detection mechanism to reorder and detect packet loss for the data packets coming from the network. The current mainstream end-side reordering and packet loss detection solutions are as follows: Figure 1 A schematic diagram of data packet sorting is shown below. Figure 1 As shown, after receiving the out-of-order message, the destination side will place the PSN in the out-of-order message in the network card, store the data corresponding to the PSN in the memory, cache the PSN information on the network card, and sort according to the PSN information. When all the data packets corresponding to PSN 0 to 7 are received, an acknowledgement character (ACK) will be sent to the sending network card to indicate that all the data packets in this segment have been received. If any data packet in PSN 0 to 7 is not received, even if the data segments in PSN 8 to 15 have been received, it is necessary to wait until the PSN corresponding to the previous data segment has been received and the ACK has been replied before the ACK for PSN 8 to 15 can be replied to the sending device.

[0043] As for the packet loss detection and retransmission scheme, the timeout retransmission mechanism is currently mainly used. This mechanism requires enabling a timer based on each pair of QPs, and starting the timing of PSN in sequence. First, the timer will be started for the data packet with PSN of 0. If the timer is exceeded, the data packet with PSN of 0 will be retransmitted; if a data packet is received within the timer, the pointer corresponding to the timer will be transferred to the data packet with PSN of 1, and so on.

[0044] The disorder problem in the current intelligent computing center network is one of the key issues affecting the efficiency of AI cluster training. Although the current network card side supports the disorder reordering function, the current solution is not enough to meet the disorder reordering and packet retransmission requirements of the intelligent computing center based on the packet-by-packet traffic load sharing method. The current solution has the following main problems: (1) The order of data packets sent by the current sender to the network is random, and it is impossible to perceive the path taken by each data packet. There is currently no operation and maintenance means. Moreover, the more links there are, the greater the disorder of data packets, and the greater the pressure on the receiving end; (2) In the current solution, the ACK confirmation of the previous data segment must be completed before the cache on the network card side can be released and the subsequent ACK confirmation of the following data segments can be made. Especially when the queue depth and window size of the QP are full, if a certain PSN in the front is still not received, the ability of the entire QP queue to receive data packets will be suspended, and wait for the data packet to time out and trigger retransmission to obtain the PSN. Therefore, in this case, packet interruption will affect performance; (3) The current timeout retransmission mechanism has only one timer. When the data packet received by the receiving end network card is lost, it is necessary to wait for the timer to time out and trigger retransmission. It is impossible to quickly detect packet loss. Therefore, in scenarios with a large degree of packet loss, resources are greatly wasted. Therefore, it is urgent to propose a technical solution that can quickly detect packet loss.

[0045] In order to solve the problem that the current packet loss detection and retransmission scheme cannot quickly perceive packet loss, the embodiments of the present application provide a data packet transmission method, related equipment, storage medium and computer program product, wherein a sending end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; each first data packet is encapsulated to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; the N second data packets are sent to a receiving end device; the receiving end device determines whether there is packet loss based on the first information and the second information. It can be seen that the sending device can encapsulate each first data packet in the data stream to be transmitted to obtain N second data packets, each second data packet includes first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information. Since the first container identification information is associated with the transmission path of the data packet, the path transmitted by each data packet can be perceived based on the container identification information, thereby reducing the disorder of the data packet, and then the N second data packets can be sent to the receiving device. The receiving device can determine whether there is packet loss based on the first information and the second information, so that the packet loss situation can be quickly perceived and the efficiency of packet loss detection can be improved.

[0046] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.

[0047] The present application provides a data packet transmission method, which is applied to a sending end device. Figure 2 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 1 ,like Figure 2 As shown, the data packet transmission method may include the following steps:

[0048] Step 101: Obtain N first data packets in a data stream to be transmitted; wherein N is a positive integer.

[0049] In an embodiment of the present application, the transmitting end device may obtain N first data packets in the data stream to be transmitted.

[0050] It should be noted that, in the embodiment of the present application, when the transmitting end device obtains N first data packets in the data stream to be transmitted, it can perform packet splitting processing on the data stream to be transmitted to obtain the N first data packets in the data stream to be transmitted.

[0051] Step 102: encapsulate each first data packet to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information.

[0052] In an embodiment of the present application, after obtaining N first data packets in the data stream to be transmitted, the transmitting end device may encapsulate each first data packet to obtain N second data packets.

[0053] It should be noted that, in the embodiments of the present application, Figure 3 This is a schematic diagram of the data packet structure proposed in the embodiment of the present application, such as Figure 3 As shown, each first data packet includes first information (Container_ID) and second information (index); wherein the first information and the second information are located between the IP header and the Media Access Control (MAC) header of each first data packet; wherein R is a reserved field, and Header represents a newly added data packet header.

[0054] It should be noted that, in an embodiment of the present application, when the sending end device encapsulates each first data packet to obtain N second data packets, it can first determine the preset value interval corresponding to the first container identification information; wherein the preset value interval is associated with the number of links; then, based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, the first container identification information corresponding to each first data packet can be determined, and the first index information of the data packet under the same first container identification information can be determined; and then, each first data packet can be encapsulated based on the first container identification information and the first index information to obtain N second data packets.

[0055] It should be noted that, in the embodiment of the present application, the preset value interval corresponding to the first container identification information is associated with the number of links, and the number of links may be the number of uplinks from the leaf switch to the spine switch. Figure 4 A schematic diagram of the number of uplinks proposed in the embodiment of the present application, such as Figure 4 As shown, the number of uplinks from the leaf switch to the spine switch is 4, so the preset value range of the first container identification information (Container_ID) can be set to [0, 3]; if the network is a multi-level CLOS architecture, ContainerID can expand the value range of Container_ID according to the scale of the network, that is, the number of all paths from the leaf switch to the top-level spine switch.

[0056] It should be noted that in the embodiments of the present application, the sending device may obtain the number of links by being issued by a centralized control system or by being notified by an Ethernet Virtual Private Network (EVPN) protocol. The present application does not specifically limit the type of method in which the sending device obtains the number of links.

[0057] It should be noted that, in an embodiment of the present application, after determining the preset value interval corresponding to the first container identification information, the sending end device can determine the first container identification information corresponding to each first data packet based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, and determine the first index information of the data packets under the same first container identification information.

[0058] It should be noted that, in an embodiment of the present application, when the sending end device determines the first container identification information corresponding to each first data packet based on a preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, it can determine the first value based on the packet sequence number corresponding to each first data packet and the total number of first data packets; wherein the first value is obtained by performing a first preset operation based on the packet sequence number corresponding to each first data packet and the total number of first data packets; and then the first container identification information corresponding to each first data packet can be determined based on the first value and the preset value interval.

[0059] For example, in the embodiments of the present application, Figure 5 This is a schematic diagram of the process of generating container identification information corresponding to a data packet proposed in an embodiment of the present application, such as Figure 5 As shown, the PSNs corresponding to the segmented first data packets are 0, 1, 2, ..., 15, respectively, and the preset value interval corresponding to the first container identification information is [0, 3], namely, Container_0, Container_1, Container_2, Container_3. Then, a first preset operation can be performed based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value, and then the size of the first value can be matched with the first container identification information, so that the first container identification information corresponding to each first data packet can be determined.

[0060] Exemplarily, in an embodiment of the present application, the transmitting device may perform a first preset operation based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value. The formula of the first preset operation may be as shown in the following formula (1). Assuming that the PSN of the first data packet is 0, 0 can be modulo 16 (PSN_num), and the result is 0, that is, the Container_ID corresponding to the data packet with a PSN of 0 is 0. Assuming that the PSN of the first data packet is 1, 1 modulo 16 is 1, and the result is 1, then the Container_ID corresponding to the data packet with a PSN of 1 is 1. Similarly, the Container_ID corresponding to each first data packet may be obtained, that is, each first data packet may be placed in turn in the container corresponding to the corresponding Container_ID.

[0061] Container_ID=PSN%PSN_num (1)

[0062] Among them, Container_ID represents the first container identification information, PSN represents the PSN of each first data packet, and PSN_num represents the total number of first data packets.

[0063] It should be noted that, in the embodiment of the present application, after determining the first container identification information corresponding to each first data packet, the transmitting end device may determine the first index information of the data packet under the same first container identification information.

[0064] Further, in an embodiment of the present application, when determining the first index information of the data packets under the same first container identification information, the transmitting end device may first determine the packet sequence number corresponding to each data packet under the same first container identification information; and then determine the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information.

[0065] It should be noted that, in an embodiment of the present application, when the sending end device determines the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information, it can determine the second value based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; wherein the second value is obtained by performing a second preset operation based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; and then the first index information can be determined based on the second value.

[0066] For example, in the embodiments of the present application, Figure 6 This is a schematic diagram of a process for determining the first index information proposed in an embodiment of the present application, such as Figure 6As shown, a second preset operation can be performed based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information to obtain a second value, and then the first index information can be determined based on the size of the second value. The second preset operation can be shown as the following formula (2). Assuming that the packet sequence number corresponding to one of the data packets under the same first container identification information (Container_1) is 9 and the number of links is 4, then the result of 9 / 4 is 2.25, and then 2.25 is rounded to 2, that is, the size of the second value is 2, and the corresponding index information is also 2. By analogy, the second value corresponding to each data packet under the same first container identification information can be obtained, and thus the index information of each data packet under the same first container identification information can be obtained, which is 0, 1, 2, and 3, respectively.

[0067] index = PSN / path_num (2)

[0068] Among them, path_num represents the number of links, and index represents the first index information.

[0069] That is to say, in the embodiment of the present application, the sending end device can sequentially place each first data packet into the corresponding Container_ID through the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID through the above formula (2), that is, the present application can quickly sort each data packet according to formula (1) and formula (2). Different from the current sorting method at the traditional hardware level (network card), the present application can sort according to the set formula rules, thereby greatly improving the efficiency of out-of-order rearrangement and reducing the cache pressure on the end side.

[0070] Step 103: Send N second data packets to a receiving device.

[0071] In an embodiment of the present application, after the transmitting end device encapsulates each first data packet to obtain N second data packets, the N second data packets may be sent to the receiving end device.

[0072] It should be noted that, in the embodiment of the present application, when the transmitting end device sends N second data packets to the receiving end device, the data packets under the same first container identification information may be sent to the receiving end device through the same data link.

[0073] That is to say, in the embodiment of the present application, data packets under the same first container identification information (Container_ID) take the same path, and data packets under different Container_IDs take different paths, and the data packets are evenly distributed to the network link, so that the path passed by each data packet can be perceived, the disorder of the data packets can be reduced, and the pressure on the receiving device can be relieved.

[0074] It should be noted that, in an embodiment of the present application, a sending device can receive a first retransmission request sent by a receiving device; wherein the first retransmission request carries a packet sequence number corresponding to a lost data packet; wherein the lost data packet includes one or more data packets in a second data packet; and then the corresponding lost data packet can be retransmitted to the receiving device based on the packet sequence number corresponding to the lost data packet.

[0075] It should be noted that, in an embodiment of the present application, the transmitting device may also receive a second retransmission request sent by the receiving device; wherein the second retransmission request carries at least one first container identification information; and retransmits a data packet corresponding to at least one first container identification information to the receiving device.

[0076] It should be noted that, in an embodiment of the present application, if the second retransmission request sent by the receiving device and received by the sending device carries at least one first container identification information, it indicates that the link corresponding to the first container identification information fails, so the sending device can retransmit all data packets corresponding to the at least one first container identification information to the receiving device.

[0077] In summary, the sending end device can sequentially place each first data packet into the corresponding Container_ID through the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID through the above formula (2), that is, the present application can quickly sort each data packet according to formula (1) and formula (2). Different from the current sorting method at the traditional hardware level, the present application can sort according to the set formula rules, thereby greatly improving the efficiency of disorderly reordering, thereby reducing the cache pressure on the end side, and then the data packets under the same first container identification information (Container_ID) can take the same path, and the data packets under different Container_IDs can take different paths, so that the data packets can be evenly distributed to the network link, and the path passed by each data packet can be sensed, reducing the disorder of the data packets, and thus relieving the pressure on the receiving end device.

[0078] An embodiment of the present application provides a data packet transmission method, which is applied to a sending end device, wherein the sending end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; each first data packet is encapsulated to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; and the N second data packets are sent to a receiving end device. It can be seen that the sending end device can encapsulate each first data packet to obtain N second data packets, each second data packet including first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information, that is, the present application can identify the first container identification information corresponding to each first data packet based on the first information, and can also identify the first index information of the data packet under the same first container identification information based on the second information, so that each first data packet can be quickly sorted to improve the efficiency of data packet reordering, and the first container identification information is associated with the transmission path of the data packet, so that the path transmitted by each data packet can be perceived based on the container identification information, reducing the degree of disorder of the data packet.

[0079] Based on the above embodiment, another embodiment of the present application provides a data packet transmission method, which is applied to a receiving device. Figure 7 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 2 ,like Figure 7 As shown, the data packet transmission method may include the following steps:

[0080] Step 201: Receive N second data packets sent by a sending end device; wherein each second data packet includes first information and second information; the first information is used to identify first container identification information corresponding to each second data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information.

[0081] In an embodiment of the present application, the receiving device may receive N second data packets sent by the sending device.

[0082] Step 202: Determine whether there is packet loss based on the first information and the second information.

[0083] In an embodiment of the present application, after receiving N second data packets sent by the sending device, the receiving device can determine whether there is packet loss based on the first information and the second information.

[0084] It should be noted that, in an embodiment of the present application, when the receiving device determines whether there is packet loss based on the first information and the second information, it can determine the second container identification information corresponding to the second data packet currently received based on the first information, and determine the second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; and then it can be determined whether there is packet loss based on the second index information.

[0085] Illustratively, in an embodiment of the present application, the receiving device may determine the second container identification information corresponding to the second data packet currently received based on the first information. Assuming that the second container identification information corresponding to the data packet currently received is Container_2, the second index information of the data packet currently received under Container_2 may be determined, and further, whether there is packet loss behavior may be determined based on the second index information.

[0086] It should be noted that in an embodiment of the present application, when the receiving device determines whether there is packet loss based on the second index information, if the second index information is consistent with the third index information, it is determined that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, it is determined that there is packet loss.

[0087] Exemplarily, in an embodiment of the present application, the receiving end device may set the expected third index information corresponding to the data packet under each container identification information to start from 0. Assuming that the second container identification information corresponding to the currently received data packet is Container_2, it may then be determined whether the second index information of the currently received data packet under Container_2 is consistent with the expected third index information. If the second index information is consistent with the third index information, it is determined that there is no packet loss behavior. If the second index information is inconsistent with the third index information, for example, the second index information is greater than the third index information, it may be determined that there is packet loss behavior.

[0088] Further, in an embodiment of the present application, after determining that packet loss occurs, the receiving device can determine the packet sequence number of the second data packet corresponding to the second index information; then, based on the packet sequence number of the second data packet and the number of links, the packet sequence number corresponding to the lost data packet can be determined; and then, a first retransmission request can be sent to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

[0089] Exemplarily, in an embodiment of the present application, assuming that the second index information of the currently received data packet under the corresponding container identification information (Container_1) is 3, and the expected third index information is 2, and the second index information is greater than the third index information, it is determined that packet loss occurs, and then it can be determined that the packet sequence number of the second data packet corresponding to the second index information is 13. Assuming that the number of links is 4, the packet sequence number corresponding to the lost data packet can be determined based on the packet sequence number of the second data packet corresponding to the second index information and the number of links. The calculation formula for the packet sequence number corresponding to the lost data packet is shown in the following formula (3). Based on formula (3), it can be determined that the packet sequence number corresponding to the lost data packet is 9.

[0090] PSN corresponding to the lost data packet = PSN_1-path_num (3)

[0091] Among them, path_num represents the number of links, and PSN_1 represents the packet sequence number of the second data packet corresponding to the second index information.

[0092] Further, in an embodiment of the present application, after the receiving device determines the packet sequence number corresponding to the lost data packet based on the packet sequence number of the second data packet and the number of links, it can send a first retransmission request to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

[0093] That is to say, in an embodiment of the application, the receiving device can determine whether there is packet loss based on the first information and the second information in each second data packet, so that it can quickly sense whether there is packet loss, and when it is determined that there is packet loss, obtain the packet sequence number corresponding to the lost data packet, and then send a first retransmission request carrying the packet sequence number of the lost data packet to the sending device, so that the sending device retransmits, that is, the present application can quickly sense whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0094] It should be noted that, in an embodiment of the present application, the receiving device can traverse the data packets corresponding to each first container identification information; when there is at least one data packet corresponding to the first container identification information that has not been received, a second retransmission request can be sent to the sending device; wherein the second retransmission request carries at least one first container identification information.

[0095] It should be noted that, in the embodiment of the present application, when there is a situation where no data packet corresponding to at least one first container identification information is received, it is considered that a link corresponding to at least one first container identification information fails, and all data packets in the container corresponding to at least one first container identification information need to be retransmitted.

[0096] In summary, the receiving device can determine the second container identification information corresponding to the second data packet currently received based on the first information, and determine the second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; and then it can be determined whether there is packet loss based on the second index information, and if the second index information is consistent with the third index information, it is determined that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, it is determined that there is packet loss, and then the packet sequence number of the second data packet corresponding to the second index information can be determined; and then the packet sequence number corresponding to the lost data packet can be determined based on the packet sequence number of the second data packet and the number of links; a first retransmission request can be sent to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet, so that the sending device retransmits, that is, the present application can quickly perceive whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0097] The embodiment of the present application provides a data packet transmission method, which is applied to a receiving device, and the receiving device receives N second data packets sent by a sending device; wherein each second data packet includes first information and second information; the first information is used to identify the first container identification information corresponding to each second data packet, and the first container identification information is associated with the transmission path of the second data packet, and the second information is used to identify the first index information of the data packet under each first container identification information; based on the first information and the second information, it is judged whether there is packet loss. It can be seen that the first information in the second data packet can identify the first container identification information corresponding to the data packet, and the second information in the second data packet is used to identify the first index information of the data packet under the same first container identification information, so that it can be judged whether there is packet loss based on the first information and the second information, thereby improving the efficiency of packet loss detection.

[0098] Based on the above embodiments, another embodiment of the present application provides a data packet transmission method, which is applied to a sending end device and a receiving end device. Figure 8 The data packet transmission method proposed in the embodiment of the present application is shown in FIG. Figure 3 ,like Figure 8 As shown, the data packet transmission method may include the following steps:

[0099] Step 301: A transmitting device obtains N first data packets in a data stream to be transmitted, wherein N is a positive integer.

[0100] It should be noted that, in the embodiment of the present application, when the transmitting end device obtains N first data packets in the data stream to be transmitted, it can perform packet splitting processing on the data stream to be transmitted to obtain the N first data packets in the data stream to be transmitted.

[0101] Step 302: The sending end device encapsulates each first data packet to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information.

[0102] It should be noted that, in the embodiments of the present application, Figure 3 As shown, each first data packet includes first information (Container_ID) and second information (index); wherein the first information and the second information are located between the IP header and the MAC header of each first data packet.

[0103] It should be noted that, in an embodiment of the present application, when the sending end device encapsulates each first data packet to obtain N second data packets, it can first determine the preset value interval corresponding to the first container identification information; wherein the preset value interval is associated with the number of links; then, based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, the first container identification information corresponding to each first data packet can be determined, and the first index information of the data packet under the same first container identification information can be determined; and then, each first data packet can be encapsulated based on the first container identification information and the first index information to obtain N second data packets.

[0104] It should be noted that, in the embodiment of the present application, the preset value interval corresponding to the first container identification information is associated with the number of links, and the number of links can be the number of uplinks from the leaf switch to the spine switch, such as Figure 4 As shown, the number of uplinks from the leaf switch to the spine switch is 4, so the preset value range of the first container identification information (Container_ID) can be set to [0, 3]; if the network is a multi-level CLOS architecture, ContainerID can expand the value range of Container_ID according to the scale of the network, that is, the number of all paths from the leaf switch to the top-level spine switch.

[0105] It should be noted that in the embodiments of the present application, the sending end device may obtain the number of links by being issued by a centralized control system or by being notified by an EVPN protocol. The present application does not specifically limit the type of method in which the sending end device obtains the number of links.

[0106] It should be noted that, in an embodiment of the present application, after determining the preset value interval corresponding to the first container identification information, the sending end device can determine the first container identification information corresponding to each first data packet based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, and determine the first index information of the data packets under the same first container identification information.

[0107] It should be noted that, in an embodiment of the present application, when the sending end device determines the first container identification information corresponding to each first data packet based on a preset value interval, the packet sequence number corresponding to each first data packet, and the total number of first data packets, it can determine the first value based on the packet sequence number corresponding to each first data packet and the total number of first data packets; wherein the first value is obtained by performing a first preset operation based on the packet sequence number corresponding to each first data packet and the total number of first data packets; and then the first container identification information corresponding to each first data packet can be determined based on the first value and the preset value interval.

[0108] For example, in the embodiments of the present application, Figure 5 As shown, the PSNs corresponding to the segmented first data packets are 0, 1, 2, ..., 15, respectively, and the preset value interval corresponding to the first container identification information is [0, 3], namely, Container_0, Container_1, Container_2, Container_3. Then, a first preset operation can be performed based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value, and then the size of the first value can be matched with the first container identification information, so that the first container identification information corresponding to each first data packet can be determined.

[0109] Exemplarily, in an embodiment of the present application, the transmitting device may perform a first preset operation based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value. The formula for the first preset operation may be as shown in the above formula (1). Assuming that the PSN of the first data packet is 0, then 0 can be modulo 16 (PSN_num), and the result is 0, that is, the Container_ID corresponding to the data packet with a PSN of 0 is 0. Assuming that the PSN of the first data packet is 1, 1 modulo 16 is 1, then the Container_ID corresponding to the data packet with a PSN of 1 is 1. Similarly, the Container_ID corresponding to each first data packet may be obtained, that is, each first data packet may be placed in turn in the container corresponding to the corresponding Container_ID.

[0110] It should be noted that, in the embodiment of the present application, after determining the first container identification information corresponding to each first data packet, the transmitting end device may determine the first index information of the data packet under the same first container identification information.

[0111] Further, in an embodiment of the present application, when determining the first index information of the data packets under the same first container identification information, the transmitting end device may first determine the packet sequence number corresponding to each data packet under the same first container identification information; and then determine the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information.

[0112] It should be noted that, in an embodiment of the present application, when the sending end device determines the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information, it can determine the second value based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; wherein the second value is obtained by performing a second preset operation based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; and then the first index information can be determined based on the second value.

[0113] For example, in the embodiments of the present application, Figure 6 As shown, a second preset operation can be performed based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information to obtain a second value, and then the first index information can be determined based on the size of the second value. The second preset operation can be as shown in the above formula (2). Assuming that the packet sequence number corresponding to one of the data packets under the same first container identification information (Container_1) is 9 and the number of links is 4, then the result of 9 / 4 is 2.25, and then 2.25 is rounded to 2, that is, the size of the second value is 2, and the corresponding index information is also 2. By analogy, the second value corresponding to each data packet under the same first container identification information can be obtained, and thus the index information of each data packet under the same first container identification information can be obtained, which is 0, 1, 2, and 3 respectively.

[0114] That is to say, in the embodiment of the present application, the sending end device can sequentially place each first data packet into the corresponding Container_ID through the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID through the above formula (2), that is, the present application can quickly sort each data packet according to formula (1) and formula (2). Different from the current sorting method at the traditional hardware level (network card), the present application can sort according to the set formula rules, thereby greatly improving the efficiency of out-of-order rearrangement and reducing the cache pressure on the end side.

[0115] Step 303: The sending end device sends N second data packets to the receiving end device.

[0116] It should be noted that, in the embodiment of the present application, when the transmitting end device sends N second data packets to the receiving end device, the data packets under the same first container identification information may be sent to the receiving end device through the same data link.

[0117] That is to say, in the embodiment of the present application, data packets under the same first container identification information (Container_ID) take the same path, and data packets under different Container_IDs take different paths, and the data packets are evenly distributed to the network link, so that the path passed by each data packet can be perceived, the disorder of the data packets can be reduced, and the pressure on the receiving device can be relieved.

[0118] It should be noted that, in an embodiment of the present application, a sending device can receive a first retransmission request sent by a receiving device; wherein the first retransmission request carries a packet sequence number corresponding to a lost data packet; wherein the lost data packet includes one or more data packets in a second data packet; and then the corresponding lost data packet can be retransmitted to the receiving device based on the packet sequence number corresponding to the lost data packet.

[0119] It should be noted that, in an embodiment of the present application, the transmitting device may also receive a second retransmission request sent by the receiving device; wherein the second retransmission request carries at least one first container identification information; and retransmits a data packet corresponding to at least one first container identification information to the receiving device.

[0120] It should be noted that, in an embodiment of the present application, if the second retransmission request sent by the receiving device and received by the sending device carries at least one first container identification information, it indicates that the link corresponding to the first container identification information fails, so the sending device can retransmit all data packets corresponding to the at least one first container identification information to the receiving device.

[0121] Step 304: The receiving device determines whether there is packet loss based on the first information and the second information.

[0122] It should be noted that, in an embodiment of the present application, when the receiving device determines whether there is packet loss based on the first information and the second information, it can determine the second container identification information corresponding to the second data packet currently received based on the first information, and determine the second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; and then it can be determined whether there is packet loss based on the second index information.

[0123] Illustratively, in an embodiment of the present application, the receiving device may determine the second container identification information corresponding to the second data packet currently received based on the first information. Assuming that the second container identification information corresponding to the data packet currently received is Container_2, the second index information of the data packet currently received under Container_2 may be determined, and further, whether there is packet loss behavior may be determined based on the second index information.

[0124] It should be noted that in an embodiment of the present application, when the receiving device determines whether there is packet loss based on the second index information, if the second index information is consistent with the third index information, it is determined that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, it is determined that there is packet loss.

[0125] Exemplarily, in an embodiment of the present application, the receiving end device may set the expected third index information corresponding to the data packet under each container identification information to start from 0. Assuming that the second container identification information corresponding to the currently received data packet is Container_2, it may then be determined whether the second index information of the currently received data packet under Container_2 is consistent with the expected third index information. If the second index information is consistent with the third index information, it is determined that there is no packet loss behavior. If the second index information is inconsistent with the third index information, for example, the second index information is greater than the third index information, it may be determined that there is packet loss behavior.

[0126] Further, in an embodiment of the present application, after determining that packet loss occurs, the receiving device can determine the packet sequence number of the second data packet corresponding to the second index information; then, based on the packet sequence number of the second data packet and the number of links, the packet sequence number corresponding to the lost data packet can be determined; and then, a first retransmission request can be sent to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

[0127] Exemplarily, in an embodiment of the present application, assuming that the second index information of the currently received data packet under the corresponding container identification information (Container_1) is 3, and the expected third index information is 2, and the second index information is greater than the third index information, it is determined that packet loss occurs, and then it can be determined that the packet sequence number of the second data packet corresponding to the second index information is 13. Assuming that the number of links is 4, the packet sequence number corresponding to the lost data packet can be determined based on the packet sequence number of the second data packet corresponding to the second index information and the number of links. The calculation formula for the packet sequence number corresponding to the lost data packet is shown in the above formula (3). Based on formula (3), it can be determined that the packet sequence number corresponding to the lost data packet is 9.

[0128] Further, in an embodiment of the present application, after the receiving device determines the packet sequence number corresponding to the lost data packet based on the packet sequence number of the second data packet and the number of links, it can send a first retransmission request to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

[0129] That is to say, in an embodiment of the application, the receiving device can determine whether there is packet loss based on the first information and the second information in each second data packet, so that it can quickly sense whether there is packet loss, and when it is determined that there is packet loss, obtain the packet sequence number corresponding to the lost data packet, and then send a first retransmission request carrying the packet sequence number of the lost data packet to the sending device, so that the sending device retransmits, that is, the present application can quickly sense whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0130] It should be noted that, in an embodiment of the present application, the receiving device can traverse the data packets corresponding to each first container identification information; when there is at least one data packet corresponding to the first container identification information that has not been received, a second retransmission request can be sent to the sending device; wherein the second retransmission request carries at least one first container identification information.

[0131] It should be noted that, in the embodiment of the present application, when there is a situation where no data packet corresponding to at least one first container identification information is received, it is considered that a link corresponding to at least one first container identification information fails, and all data packets in the container corresponding to at least one first container identification information need to be retransmitted.

[0132] In summary, the sending end device can sequentially place each first data packet into the container corresponding to the Container_ID through the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID through the above formula (2), that is, the present application can quickly sort each data packet according to formula (1) and formula (2). Different from the current sorting method at the traditional hardware level, the present application can sort according to the set formula rules, thereby greatly improving the efficiency of disorderly rearrangement, thereby reducing the cache pressure on the end side, and then the data packets under the same first container identification information (Container_ID) can take the same path, and the data packets under different Container_IDs can take different paths, so that the data packets can be evenly distributed to the network link, and the path passed by each data packet can be sensed, reducing the disorder of the data packets, thereby alleviating the pressure on the receiving end device; the receiving end device can determine the current receiving end based on the first information. The method comprises the steps of: determining the second container identification information corresponding to the received second data packet, and determining the second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; and then judging whether there is packet loss based on the second index information, and if the second index information is consistent with the third index information, then judging that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, then judging that there is packet loss, and then determining the packet sequence number of the second data packet corresponding to the second index information; and then determining the packet sequence number corresponding to the lost data packet based on the packet sequence number of the second data packet and the number of links; and sending a first retransmission request to the sending end device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet, so that the sending end device retransmits, that is, the present application can quickly perceive whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0133] An embodiment of the present application provides a data packet transmission method, which is applied to a sending end device and a receiving end device, the sending end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; each first data packet is encapsulated to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; the N second data packets are sent to the receiving end device; the receiving end device determines whether there is packet loss based on the first information and the second information. It can be seen that the sending end device can encapsulate each first data packet in the data stream to be transmitted to obtain N second data packets, each second data packet includes first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, the first container identification information is associated with the transmission path of the second data packet, and the second information is used to identify the first index information of the data packet under each first container identification information. Since the first container identification information is associated with the transmission path of the data packet, the path transmitted by each data packet can be perceived based on the container identification information, thereby reducing the disorder of the data packet, and then the N second data packets can be sent to the receiving end device. The receiving end device can determine whether there is packet loss based on the first information and the second information, so that the packet loss situation can be quickly perceived and the efficiency of packet loss detection can be improved.

[0134] Based on the above embodiments, another embodiment of the present application provides a data packet transmission method, which can achieve efficient end-side disorder reordering by adding data packets to a container and designing data packet distribution, rapid perception of packet loss and retransmission principles; Next, taking the write operation of Remote Direct Memory Access (RDMA) as an example, the following processes may be specifically included: (1) message encapsulation; (2) data packet link distribution; (3) end-side network card packet loss judgment and retransmission; (4) ACK reception and data upload; Among them, the message encapsulation may include the following contents: When the sender (sender device) starts to send traffic to the receiver (receiver device), the sender card side needs to cut the data stream (data stream to be transmitted) and add Container_ID (first information), index (second information) and R field between the IP and MAC headers of each data packet. The specific message format is as above Figure 3As shown, Container_ID (first information) is used to identify the path ID for forwarding the data packet, index (second information) is used to identify the index (first index information) of the data packet in the Container (first container identification information), R is a reserved field, and Header represents a newly added data packet header.

[0135] It should be noted that, in the embodiment of the present application, the value process of ContainerID and index value is as follows: the value of Container_ID (first container identification information) is related to path_num (number of links); wherein PSN is the PSN value in the RDMA BTH header (assuming that the RDMA BTH PSN of each data packet is 0, 1, 2, 3, .... in sequence); PSN_num (number of links) is the number of uplinks from the leaf switch to the spine switch (the number of leaf uplinks can be issued by the centralized control system or notified by the EVPN protocol), as shown above Figure 4 As shown, the number of leaf upstream links is 4, so the value range (preset value interval) of Container_ID (first container identification information) can be set to [0, 3]; if the network is a multi-level CLOS architecture, the value range of Container_ID is expanded according to the network scale, that is, the number of all paths from leaf to the root aggregation device.

[0136] It should be noted that in the embodiments of the present application, the sending end device may obtain the number of links by being issued by a centralized control system or by being notified by an EVPN protocol. The present application does not specifically limit the type of method in which the sending end device obtains the number of links.

[0137] It should be noted that, in the embodiment of the present application, the sending end can sequentially and cyclically place each data packet (first data packet) after the data stream is segmented into Container_0, Container_1, Container_2, and Container_3, that is, the Container_ID where the data packet is stored can be expressed by the above formula (1). Assuming that the PSN sequence is [0, 15], the division method is as above. Figure 5 shown.

[0138] For example, in the embodiments of the present application, Figure 5As shown, the PSNs corresponding to the segmented first data packets are 0, 1, 2, ..., 15, respectively, and the preset value interval corresponding to the first container identification information is [0, 3], namely, Container_0, Container_1, Container_2, Container_3. Then, a first preset operation can be performed based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value, and then the size of the first value can be matched with the first container identification information, so that the first container identification information corresponding to each first data packet can be determined.

[0139] Exemplarily, in an embodiment of the present application, the transmitting device may perform a first preset operation based on the packet sequence number corresponding to each data packet and the total number of first data packets (16) to obtain a first value. The formula of the first preset operation may be as shown in the above formula (1). Assuming that the PSN of the first data packet is 0, then 0 may be modulo 16 (PSN_num), and the result is 0, that is, the Container_ID corresponding to the data packet with PSN of 0 is 0. Assuming that the PSN of the first data packet is 1, 1 may be modulo 16 (PSN_num), and the result is 1, then the Container_ID corresponding to the data packet with PSN of 1 is 1. Similarly, the Container_ID corresponding to each first data packet may be obtained, that is, each first data packet may be placed in the container corresponding to the corresponding Container_ID in sequence.

[0140] It should be noted that in the embodiment of the present application, after determining the first container identification information corresponding to each first data packet, the sending end device also needs to mark the data packet corresponding to each Container_ID with an index value (first index information), that is, the container corresponding to each Container_ID is set to 0, 1, .... 3 in sequence according to the storage order of the data packets.

[0141] Further, in an embodiment of the present application, when determining the first index information of the data packets under the same first container identification information, the transmitting device may first determine the packet sequence number corresponding to each data packet under the same first container identification information (Container_ID); and then determine the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information.

[0142] It should be noted that, in an embodiment of the present application, when the sending end device determines the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information, it can determine the second value based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; wherein the second value is obtained by performing a second preset operation based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information; and then the first index information can be determined based on the second value.

[0143] For example, in the embodiments of the present application, Figure 6 As shown, a second preset operation can be performed based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information to obtain a second value, and then the first index information can be determined based on the size of the second value. The second preset operation can be as shown in the above formula (2). Assuming that the packet sequence number corresponding to one of the data packets under the same first container identification information (Container_1) is 9 and the number of links is 4, then the result of 9 / 4 is 2.25, and then 2.25 is rounded to 2, that is, the size of the second value is 2, and the corresponding index information is also 2. By analogy, the second value corresponding to each data packet under the same first container identification information can be obtained, and thus the index information of each data packet under the same first container identification information can be obtained, which is 0, 1, 2, and 3 respectively.

[0144] That is, in the embodiment of the present application, the transmitting end device can sequentially place each first data packet into the corresponding Container_ID by the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID by the above formula (2), that is, the present application can be based on the formula

[0145] (1) and formula (2) quickly sort each data packet. Different from the current sorting method at the traditional hardware level (network card), the present application can sort according to the set formula rules, thereby greatly improving the efficiency of out-of-order rearrangement and reducing the cache pressure on the end side.

[0146] It should be noted that, in the embodiment of the present application, the data packet link distribution may include the following contents: encapsulating the data packet carrying the Container_ID (first information) and the index field (second information)

[0147] After the encapsulated data packet (first data packet) is sent to the network side device, the data packets under the same Container_ID (first container identification information) take the same path, and the data packets with different Container_IDs take different paths, so that the data packets are evenly distributed to the network link.

[0148] That is to say, in the embodiment of the present application, data packets under the same first container identification information (Container_ID) take the same path, and data packets under different Container_IDs take different paths, and the data packets are evenly distributed to the network link, so that the path passed by each data packet can be perceived, the disorder of the data packets can be reduced, and the pressure on the receiving device can be relieved.

[0149] Further, in an embodiment of the present application, the end-side network card packet loss judgment and retransmission may include the following contents: After the receiving end (receiving end device) receives the Container from the network side, the NIC (receiving end network card) will check the PSN in the newly added Header inside the Container to determine whether there is packet loss. The judgment principle is as follows: 1. The receiving end device determines the Container_ID (second container identification information) to which the received data packet (the second data packet currently received) belongs. The Container_ID to which the received data packet belongs can be determined by the above formula (1); 2. The expected index (third index information) of each Container_ID is set to start from 0. According to the above formula (2) Determine whether the second index information of the second data packet currently received under the second container identification information is the expected index (third index information). If so, continue to check. If index (second index information)> expected index, the PSN of the lost data packet can be obtained by the above formula (3), and then the data packet with the lost PSN can be retransmitted; if there are multiple consecutive PSNs corresponding to lost indices, the above formula (3) needs to be looped continuously; 3. If it is detected that all data packets corresponding to a certain Container_ID are not received, it is considered that the link corresponding to the Container_ID is faulty, and all data packets in the Container corresponding to the Container_ID need to be retransmitted.

[0150] It should be noted that, in the embodiment of the present application, the first container identification information includes the second container identification information, the second container identification information may be the container identification information corresponding to the currently received data packet, and the preset value interval corresponding to the first container identification information is associated with the number of links, such as Figure 4 As shown, the number of uplinks from the leaf switch to the spine switch is 4, so the preset value interval of the first container identification information (Container_ID) can be set to [0, 3], namely Container_0, Container_1, Container_2, and Container_3.

[0151] Illustratively, in an embodiment of the present application, the receiving device may determine the second container identification information corresponding to the second data packet currently received based on the first information. Assuming that the second container identification information corresponding to the data packet currently received is Container_2, the second index information of the data packet currently received under Container_2 may be determined, and further, whether there is packet loss behavior may be determined based on the second index information.

[0152] It should be noted that in an embodiment of the present application, when the receiving device determines whether there is packet loss based on the second index information, if the second index information is consistent with the third index information, it is determined that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, it is determined that there is packet loss.

[0153] Exemplarily, in an embodiment of the present application, the receiving end device may set the expected third index information corresponding to the data packet under each container identification information to start from 0. Assuming that the second container identification information corresponding to the currently received data packet is Container_2, it may then be determined whether the second index information of the currently received data packet under Container_2 is consistent with the expected third index information. If the second index information is consistent with the third index information, it is determined that there is no packet loss behavior. If the second index information is inconsistent with the third index information, for example, the second index information is greater than the third index information, it may be determined that there is packet loss behavior.

[0154] Further, in an embodiment of the present application, after determining that packet loss occurs, the receiving device can determine the packet sequence number of the second data packet corresponding to the second index information; then, based on the packet sequence number of the second data packet and the number of links, the packet sequence number corresponding to the lost data packet can be determined; and then, a first retransmission request can be sent to the sending device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

[0155] Exemplarily, in an embodiment of the present application, assuming that the second index information of the currently received data packet under the corresponding container identification information (Container_1) is 3, and the expected third index information is 2, and the second index information is greater than the third index information, it is determined that packet loss occurs, and then it can be determined that the packet sequence number of the second data packet corresponding to the second index information is 13. Assuming that the number of links is 4, the packet sequence number corresponding to the lost data packet can be determined based on the packet sequence number of the second data packet corresponding to the second index information and the number of links. The calculation formula for the packet sequence number corresponding to the lost data packet is shown in the above formula (3). Based on formula (3), it can be determined that the packet sequence number corresponding to the lost data packet is 9.

[0156] That is to say, in an embodiment of the application, the receiving device can determine whether there is packet loss based on the first information and the second information in each second data packet, so that it can quickly sense whether there is packet loss, and when it is determined that there is packet loss, obtain the packet sequence number corresponding to the lost data packet, and then send a first retransmission request carrying the packet sequence number of the lost data packet to the sending device, so that the sending device retransmits, that is, the present application can quickly sense whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0157] It should be noted that, in an embodiment of the present application, the receiving device can traverse the data packets corresponding to each first container identification information; when there is at least one data packet corresponding to the first container identification information that has not been received, a second retransmission request can be sent to the sending device; wherein the second retransmission request carries at least one first container identification information.

[0158] It should be noted that, in the embodiment of the present application, when there is a situation where none of the data packets corresponding to at least one first container identification information is received, it is considered that the link corresponding to the at least one first container identification information is faulty, and it is necessary to retransmit all the data packets in the container corresponding to the at least one first container identification information. For example, the receiving device can traverse the data packets corresponding to Container_0, Container_1, Container_2, and Container_3. When the data packets corresponding to Container_0, Container_1, and Container_2 are all received, but the data packet corresponding to Container_3 is not received, it means that all the data packets corresponding to Container_3 are lost, and all the data packets corresponding to Container_3 need to be retransmitted.

[0159] It should be noted that, in the embodiment of the present application, ACK reception and data transmission may include the following contents: the NIC (receiving network card) caches the PSN in each verified data packet into the QP queue of the NIC, and caches the data into the memory. When the data packet of the corresponding data segment is completely received, the receiving network card (NIC) sends an ACK message to the sending network card (NIC), releases the cache of the PSN corresponding to the QP queue in the receiving NIC, and after the sending end receives the ACK of the last message, it sends the CQE to the application; after the receiving end receives the write immediate data message, it sends the data to the memory to complete the RDMA Write operation.

[0160] It should be noted that, in the embodiment of the present application, the NIC (receiving network card) caches the PSN in each verified data packet into the QP queue of the NIC, and caches the data into the memory. The data packets cached into the QP queue of the NIC in the embodiment of the present application are already sorted data packets, that is, the received data packets can be automatically sorted by the above formula (1) and the above formula (2), and then the sorted data packets can be cached into the network card without the need for the network card to sort the data packets, thereby avoiding sorting the data packets at a fixed hardware level, greatly improving the efficiency of out-of-order rearrangement, and thus reducing the cache pressure on the end side.

[0161] In summary, the sending end device can sequentially place each first data packet into the container corresponding to the Container_ID through the above formula (1), and determine the first index information corresponding to each data packet under the same Container_ID through the above formula (2), that is, the present application can quickly sort each data packet according to formula (1) and formula (2). Different from the current sorting method at the traditional hardware level, the present application can sort according to the set formula rules, thereby greatly improving the efficiency of disorderly rearrangement, thereby reducing the cache pressure on the end side, and then the data packets under the same first container identification information (Container_ID) can take the same path, and the data packets under different Container_IDs can take different paths, so that the data packets can be evenly distributed to the network link, and the path passed by each data packet can be sensed, reducing the disorder of the data packets, thereby alleviating the pressure on the receiving end device; the receiving end device can determine the current receiving end based on the first information. The method comprises the steps of: determining the second container identification information corresponding to the received second data packet, and determining the second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; and then judging whether there is packet loss based on the second index information, and if the second index information is consistent with the third index information, then judging that there is no packet loss; wherein the third index information includes the expected index information; or, if the second index information is inconsistent with the expected third index information, then judging that there is packet loss, and then determining the packet sequence number of the second data packet corresponding to the second index information; and then determining the packet sequence number corresponding to the lost data packet based on the packet sequence number of the second data packet and the number of links; and sending a first retransmission request to the sending end device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet, so that the sending end device retransmits, that is, the present application can quickly perceive whether there is packet loss based on the first information and the second information in the second data packet, thereby greatly improving the efficiency of packet loss detection.

[0162] An embodiment of the present application provides a data packet transmission method, which is applied to a sending end device and a receiving end device, the sending end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; each first data packet is encapsulated to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; the N second data packets are sent to the receiving end device; the receiving end device determines whether there is packet loss based on the first information and the second information. It can be seen that the sending device can encapsulate each first data packet in the data stream to be transmitted to obtain N second data packets, each second data packet includes first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information. Since the first container identification information is associated with the transmission path of the data packet, the path transmitted by each data packet can be perceived based on the container identification information, thereby reducing the disorder of the data packet, and then the N second data packets can be sent to the receiving device. The receiving device can determine whether there is packet loss based on the first information and the second information, so that the packet loss situation can be quickly perceived and the efficiency of packet loss detection can be improved.

[0163] Based on the above embodiments, the present application provides a transmitting end device, Fig. 9 The structure diagram of the sending device Figure 1 ,like Fig. 9 As shown, the sending end device 10 includes: an acquisition unit 11, a packaging unit 12, and a sending unit 13; wherein,

[0164] The acquisition unit 11 is used to acquire N first data packets in the data stream to be transmitted; wherein N is a positive integer;

[0165] The encapsulation unit 12 is used to encapsulate each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0166] The sending unit 13 is used to send the N second data packets to a receiving end device.

[0167] In the embodiments of the present application, further, Fig.10 The structure diagram of the sending device Figure 2 ,like Fig.10 As shown, the sending device 10 proposed in the embodiment of the present application may also include a first processor 14, a first memory 15 storing executable instructions of the first processor 14, and further, the sending device 10 may also include a first communication interface 16, and a first bus 17 for connecting the first processor 14, the first memory 15 and the first communication interface 16.

[0168] In the embodiment of the present application, the first processor 14 can be at least one of an application-specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a central processing unit (CPU), a controller, a microcontroller, and a microprocessor. It can be understood that for different devices, the electronic device used to implement the above-mentioned processor function can also be other, and the embodiment of the present application is not specifically limited. The transmitting end device 10 can also include a first memory 15, which can be connected to the first processor 14, wherein the first memory 15 is used to store executable program code, the program code includes computer operation instructions, and the first memory 15 may include a high-speed RAM memory, and may also include a non-volatile memory, for example, at least two disk memories.

[0169] In the embodiment of the present application, the first bus 17 is used to connect the first communication interface 16, the first processor 14 and the first memory 15, and the mutual communication between these devices.

[0170] In the embodiment of the present application, the first memory 15 is used to store instructions and data.

[0171] Further, in an embodiment of the present application, the above-mentioned first processor 14 is used to obtain N first data packets in the data stream to be transmitted; wherein N is a positive integer; encapsulate each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify the first container identification information corresponding to each of the first data packets, the first container identification information is associated with the transmission path of the second data packet, and the second information is used to identify the first index information of the data packet under each of the first container identification information; and the N second data packets are sent to the receiving end device.

[0172] In practical applications, the first memory 15 may be a volatile memory, such as a random access memory (RAM); or a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk (HDD) or a solid-state drive (SSD); or a combination of the above types of memories, and provide instructions and data to the first processor 14.

[0173] An embodiment of the present application provides a sending end device, the sending end device obtains N first data packets in a data stream to be transmitted; wherein N is a positive integer; encapsulates each first data packet to obtain N second data packets; wherein each second data packet includes first information and second information, the first information is used to identify first container identification information corresponding to each first data packet, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each first container identification information; and the N second data packets are sent to a receiving end device. It can be seen that the sending end device can encapsulate each first data packet to obtain N second data packets, each second data packet including first information and second information, the first information is used to identify the first container identification information corresponding to each first data packet, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information, that is, the present application can identify the first container identification information corresponding to each first data packet based on the first information, and can also identify the first index information of the data packet under the same first container identification information based on the second information, so that each first data packet can be quickly sorted to improve the efficiency of data packet reordering, and the first container identification information is associated with the transmission path of the data packet, so that the path transmitted by each data packet can be perceived based on the container identification information, reducing the degree of disorder of the data packet.

[0174] An embodiment of the present application provides a computer-readable storage medium having a program stored thereon, which implements the data packet transmission method as described above when the program is executed by a processor.

[0175] Specifically, a program instruction corresponding to a data packet transmission method in this embodiment may be stored on a storage medium such as a CD, a hard disk, or a USB flash drive. When a program instruction corresponding to a data packet transmission method in the storage medium is read or executed by an electronic device, the following steps are included:

[0176] Obtain N first data packets in the data stream to be transmitted; wherein N is a positive integer;

[0177] Encapsulating each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0178] The N second data packets are sent to a receiving device.

[0179] The embodiment of the present application further provides a computer program product, including a computer program, which can be executed by the first processor 14 of the sending device 10 to complete the steps of any of the aforementioned methods.

[0180] In the embodiments of the present application, further, Fig.11 Schematic diagram of the receiving device structure Figure 1 ,like Fig.11 As shown, the receiving end device 20 includes: a receiving unit 21 and a judging unit 22; wherein,

[0181] The receiving unit 21 is configured to receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0182] The determining unit 22 is configured to determine whether there is packet loss based on the first information and the second information.

[0183] In the embodiments of the present application, further, Fig.12 Schematic diagram of the receiving device structure Figure 2 ,like Fig.12 As shown, the receiving device 20 proposed in the embodiment of the present application may also include a second processor 23, a second memory 24 storing executable instructions of the second processor 23, and further, the receiving device 20 may also include a second communication interface 25, and a second bus 26 for connecting the second processor 23, the second memory 24 and the second communication interface 25.

[0184] In the embodiment of the present application, the second processor 23 can be at least one of an application-specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a central processing unit (CPU), a controller, a microcontroller, and a microprocessor. It can be understood that for different devices, the electronic device used to implement the above-mentioned processor function can also be other, and the embodiment of the present application does not specifically limit it. The receiving end device 20 can also include a second memory 24, which can be connected to the second processor 23, wherein the second memory 24 is used to store executable program code, the program code includes computer operation instructions, and the second memory 24 may include a high-speed RAM memory, and may also include a non-volatile memory, for example, at least two disk memories.

[0185] In the embodiment of the present application, the second bus 26 is used to connect the second communication interface 25, the second processor 23 and the second memory 24, and the mutual communication between these devices.

[0186] In the embodiment of the present application, the second memory 24 is used to store instructions and data.

[0187] Further, in an embodiment of the present application, the above-mentioned second processor 23 is used to receive N second data packets sent by a sending end device; wherein each of the second data packets includes first information and second information; the first information is used to identify the first container identification information corresponding to each of the second data packets, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information; based on the first information and the second information, it is determined whether there is packet loss behavior.

[0188] In practical applications, the second memory 24 may be a volatile memory, such as a random access memory (RAM); or a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk (HDD) or a solid-state drive (SSD); or a combination of the above types of memories, and provide instructions and data to the second processor 23.

[0189] The embodiment of the present application provides a receiving device, which receives N second data packets sent by a sending device; wherein each second data packet includes first information and second information; the first information is used to identify the first container identification information corresponding to each second data packet, the first container identification information is associated with the transmission path of the data packet, and the second information is used to identify the first index information of the data packet under the same first container identification information; based on the first information and the second information, it is determined whether there is packet loss. It can be seen that the first information in the second data packet can identify the first container identification information corresponding to the data packet, and the second information in the second data packet is used to identify the first index information of the data packet under the same first container identification information, so that it can be determined whether there is packet loss based on the first information and the second information, thereby improving the efficiency of packet loss detection.

[0190] An embodiment of the present application provides a computer-readable storage medium having a program stored thereon, which implements the data packet transmission method as described above when the program is executed by a processor.

[0191] Specifically, a program instruction corresponding to a data packet transmission method in this embodiment may be stored on a storage medium such as a CD, a hard disk, or a USB flash drive. When a program instruction corresponding to a data packet transmission method in the storage medium is read or executed by an electronic device, the following steps are included:

[0192] Receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information;

[0193] Determine whether there is packet loss based on the first information and the second information.

[0194] The embodiment of the present application further provides a computer program product, including a computer program, which can be executed by the second processor 23 of the receiving device 20 to complete the steps of any of the aforementioned methods.

[0195] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of hardware embodiments, software embodiments, or embodiments in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) that contain computer-usable program code.

[0196] The present application is described with reference to implementation flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the process in the flowchart. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0197] These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which is implemented in the implementation flow diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0198] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operation steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for executing the steps in the flowchart. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0199] The above description is only a preferred embodiment of the present application and is not intended to limit the protection scope of the present application.

Claims

1. A data packet transmission method, characterized in that: The method is applied to a transmitting end device, and the method comprises: Obtain N first data packets in the data stream to be transmitted; wherein N is a positive integer; Encapsulating each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information; The N second data packets are sent to a receiving device.

2. The method according to claim 1, characterized in that Each of the first data packets includes the first information and the second information; wherein the first information and the second information are located between an Internet Protocol IP header and a Media Access Control MAC header of each of the first data packets, and encapsulating each of the first data packets to obtain N second data packets includes: Determine a preset value interval corresponding to the first container identification information; wherein the preset value interval is associated with the number of links; Determine first container identification information corresponding to each first data packet based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of the first data packets, and determine first index information of the data packets under the same first container identification information; Each of the first data packets is encapsulated based on the first container identification information and the first index information to obtain the N second data packets.

3. The method according to claim 2, characterized in that The determining the first container identification information corresponding to each first data packet based on the preset value interval, the packet sequence number corresponding to each first data packet, and the total number of the first data packets includes: Determine a first value based on the packet sequence number corresponding to each of the first data packets and the total number of the first data packets; wherein the first value is obtained by performing a first preset operation based on the packet sequence number corresponding to each of the first data packets and the total number of the first data packets; The first container identification information corresponding to each of the first data packets is determined based on the first value and the preset value interval.

4. The method according to claim 2, characterized in that: The determining the first index information of the data packets under the same first container identification information includes: Determine a packet sequence number corresponding to each data packet under the same first container identification information; The first index information is determined based on a packet sequence number and a link quantity corresponding to each data packet under the same first container identification information.

5. The method according to claim 4, characterized in that The determining the first index information based on the packet sequence number and the number of links corresponding to each data packet under the same first container identification information includes: Determine a second value based on the packet sequence number corresponding to each data packet under the same first container identification information and the number of links; wherein the second value is obtained by performing a second preset operation based on the packet sequence number corresponding to each data packet under the same first container identification information and the number of links; The first index information is determined based on the second value.

6. The method according to claim 1, characterized in that The sending the N second data packets to the receiving end device includes: The data packet under the same first container identification information is sent to the receiving end device through the same data link.

7. The method according to claim 1, characterized in that The method further comprises: Receiving a first retransmission request sent by the receiving end device; wherein the first retransmission request carries a packet sequence number corresponding to a lost data packet; wherein the lost data packet includes one or more data packets in the second data packet; The corresponding lost data packet is retransmitted to the receiving end device based on the packet sequence number corresponding to the lost data packet.

8. The method according to claim 1, characterized in that The method further comprises: receiving a second retransmission request sent by the receiving end device; wherein the second retransmission request carries at least one first container identification information; The data packet corresponding to the at least one first container identification information is retransmitted to the receiving end device.

9. A data packet transmission method, characterized in that: The method is applied to a receiving end device, and the method comprises: Receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information; Determine whether there is packet loss based on the first information and the second information.

10. The method according to claim 9, characterized in that The determining whether there is packet loss based on the first information and the second information includes: Determine second container identification information corresponding to a currently received second data packet based on the first information, and determine second index information of the second data packet under the second container identification information based on the second information; wherein the first container identification information includes the second container identification information; Determine whether there is packet loss based on the second index information.

11. The method according to claim 10, characterized in that The determining whether there is packet loss based on the second index information includes: If the second index information is consistent with the third index information, it is determined that there is no packet loss behavior; wherein the third index information includes expected index information; or, If the second index information is inconsistent with the expected third index information, it is determined that packet loss occurs.

12. The method according to claim 11, characterized in that The method further comprises: Determine a packet sequence number of a second data packet corresponding to the second index information; Determine a packet sequence number corresponding to the lost data packet based on the packet sequence number of the second data packet and the number of links; Send the first retransmission request to the sending end device; wherein the first retransmission request carries the packet sequence number corresponding to the lost data packet.

13. The method according to claim 9, characterized in that The method further comprises: Traversing each data packet corresponding to the first container identification information; When there is a case where none of the data packets corresponding to at least one first container identification information is received, a second retransmission request is sent to the sending end device; wherein the second retransmission request carries the at least one first container identification information.

14. A transmitting end device, characterized in that: The sending end device includes: an acquisition unit, a packaging unit, and a sending unit; wherein, The acquisition unit is used to acquire N first data packets in the data stream to be transmitted; wherein N is a positive integer; The encapsulation unit is configured to encapsulate each of the first data packets to obtain N second data packets; wherein each of the second data packets includes first information and second information, the first information is used to identify first container identification information corresponding to each of the first data packets, the first container identification information is associated with a transmission path of the second data packets, and the second information is used to identify first index information of the data packets under each of the first container identification information; The sending unit is used to send the N second data packets to a receiving end device.

15. A transmitting end device, characterized in that: The transmitting end device comprises: a first processor and a first memory; wherein, The first memory is used to store a computer program that can be run on the processor; The first processor is configured to execute the method according to any one of claims 1 to 8 when running the computer program.

16. A receiving device, characterized in that: The receiving end device comprises: a receiving unit and a judging unit; wherein, The receiving unit is configured to receive N second data packets sent by a transmitting end device; wherein each of the second data packets includes first information and second information; the first information is used to identify first container identification information corresponding to each of the second data packets, the first container identification information is associated with a transmission path of the second data packet, and the second information is used to identify first index information of the data packet under each of the first container identification information; The judging unit is configured to judge whether there is packet loss based on the first information and the second information.

17. A receiving device, characterized in that: The receiving end device comprises: a second processor and a second memory; wherein, The second memory is used to store a computer program that can be run on the processor; The second processor is configured to execute the method according to any one of claims 9 to 13 when running the computer program.

18. A computer-readable storage medium, characterized in that: The storage medium stores computer program codes, which, when executed by a computer, execute the method described in any one of claims 1 to 8 or 9 to 13.

19. A computer program product comprising a computer program, characterized in that The computer program implements the method according to any one of claims 1-8 or 9-13 when executed by a processor.

Citation Information

Patent Citations

  • Communication method between containers, electronic equipment and computer readable storage medium

    CN113489770A

  • Packet loss detection method and device, and storage medium

    CN114389972A

  • Concurrent transmission of multiple extents during backup of extent-eligible files

    US20220237084A1

  • Data retransmission processing method and apparatus, computer device, and storage medium

    WO2022247550A1

Cited By

  • Data transmission method based on remote direct memory access, computer equipment and medium

    CN120670364A