WO2021254307A1 - 确定报文发送路径的方法及装置 - Google Patents

确定报文发送路径的方法及装置 Download PDF

Info

Publication number
WO2021254307A1
WO2021254307A1 PCT/CN2021/100032 CN2021100032W WO2021254307A1 WO 2021254307 A1 WO2021254307 A1 WO 2021254307A1 CN 2021100032 W CN2021100032 W CN 2021100032W WO 2021254307 A1 WO2021254307 A1 WO 2021254307A1
Authority
WO
WIPO (PCT)
Prior art keywords
information
message
path
processed
entry
Prior art date
Application number
PCT/CN2021/100032
Other languages
English (en)
French (fr)
Inventor
佟兴
高红亮
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2021254307A1 publication Critical patent/WO2021254307A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/12Shortest path evaluation
    • H04L45/121Shortest path evaluation by minimising delays
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/06Deflection routing, e.g. hot-potato routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/12Shortest path evaluation
    • H04L45/124Shortest path evaluation using a combination of metrics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/54Organization of routing tables

Definitions

  • This application relates to the field of communication technology, and in particular to a method and device for determining a message transmission path.
  • the message transmission device at the sending end receives a message to be processed and sends the message to the destination message transmission device corresponding to the message to be processed, if one of the two message transmission devices is If there are multiple transmission paths between them, the message transmission device at the sending end needs to determine a transmission path so that the message to be processed can be sent to the destination message transmission device through the transmission path.
  • the message transmission device at the sending end after receiving the message to be processed, the message transmission device at the sending end usually obtains the equivalent path table of the message to be processed according to the message information of the message to be processed.
  • the equivalent path table includes multiple transmission paths.
  • the message transmission device at the sending end can select a piece of path information in the equal cost path table, and subsequently can use the transmission path corresponding to the path information to send the to-be-processed message to the destination message transmission device.
  • it is easy to send a large number of packets in the same transmission path causing some transmission paths to have a large traffic load, causing congestion and packet loss or increasing transmission delay problems, while some transmission paths have a relatively high traffic load. Small, resulting in low network bandwidth utilization.
  • the present application provides a method and device for determining a message transmission path, so as to solve the problems of packet loss due to congestion, large transmission delay, and low network bandwidth utilization due to improper selection of the transmission path during message transmission.
  • the present application provides a method for determining a message transmission path, the method is applied to a first message processing apparatus, and the method includes: obtaining a first equivalent path table of a message to be processed, and a first The aggregation flow table and the first exact matching flow table; the first aggregation flow table includes first entry information; the first exact matching flow table includes second entry information; according to the message of the message to be processed Field and the first entry information determine the first information; determine the second information based on the message field, the second entry information, and the first information; determine the second information based on the second information and the first information
  • the equivalent path table determines the first sending path of the message to be processed.
  • the item information determines the first information.
  • the second information is determined according to the message fields of the message to be processed, the first information, and the entry information of the first exact matching flow table.
  • the table determines the first sending path of the message to be processed.
  • the transmission path indicated by the information is used as the first transmission path, or when the traffic load of the transmission path indicated by the current information is large, a relatively idle transmission path may be used as the first transmission path, so that the first message processing device corresponds to multiple transmission paths.
  • the traffic load in the two sending paths is relatively uniform, which avoids the problems of large load traffic in some sending paths, packet loss or increased transmission delay, and also avoids the small traffic load of some sending paths and the occurrence of network bandwidth utilization. Lower question.
  • the determining the second information according to the message field, the second entry information, and the first information includes: when the When the second entry information includes the first secret key matching the message field, it is determined whether to use the third information according to the entry content corresponding to the first secret key; the third information is the first secret The new information included in the entry content corresponding to the key; when the third information is used, the first delay difference is obtained; the first delay difference is the new and old path included in the entry content corresponding to the first secret key Delay difference; Obtain a second delay difference; The second delay difference is the time when the message to be processed arrives at the first message processing device and the previous message in the flow where the message arrives at the first message The time interval of the text processing device; when the second time delay difference is greater than the first time delay difference, it is determined that the third information is the second information.
  • the entry content corresponding to the secret key matching the message field can be used to determine whether to use the new information. That is, determine whether the sending path can be changed. In the case of determining that the new information can be used, further determine whether it will affect the sending order of the packets in the stream where the packets to be processed is located. If it does not affect the sending order of the packets in the stream where it is located, then The transmission path can be determined based on the new information, thereby using a transmission path with a lighter load to send the message to be processed, reducing the transmission delay of the message.
  • the method further includes: when the third information is not used, acquiring fourth information; the fourth information is the first secret Current information included in the content of the entry corresponding to the key; determining that the fourth information is the second information.
  • the entry content corresponding to the secret key matching the message field can be used to determine whether to use the new information. That is, it is determined whether the transmission path needs to be changed, and when it is determined that no new information is needed, the transmission path is determined according to the current information, which avoids the problem of low traffic load of the transmission path corresponding to the current information and low network bandwidth utilization.
  • the method further includes: acquiring fourth information when the second delay difference is less than or equal to the first delay difference;
  • the fourth information is current information included in the content of the entry corresponding to the first secret key; it is determined that the fourth information is the second information.
  • the current information is used to determine the sending path, thereby avoiding the confusion of the sending order of the packets in the stream due to the replacement of the path, and ensuring the accuracy of the replacement sending path Spend.
  • the determining the second information according to the message field, the second entry information, and the first information includes: when the When the second entry information does not include the first secret key matching the message field, it is determined that the first information is the second information.
  • the flow in which the message to be processed is an elephant flow is determined by matching the message field of the message to be processed with the secret key of the first exact matching flow table.
  • the first exact matching flow table does not
  • the secret key that matches the message field of the message to be processed is included, it means that the flow of the message to be processed is not an elephant flow.
  • the sending path can be determined according to the current information, which can avoid the small traffic load of the sending path corresponding to the current information. , The problem of low network bandwidth utilization has occurred.
  • the determining the first information according to the message field of the message to be processed and the first entry information includes: determining the first information A first number of entries included in the entry information; hash calculation of the message field of the message to be processed to generate a first calculation result; generate a first calculation result according to the first calculation result and the first number An index; the first information is determined according to the first index and the first entry information.
  • the process of determining the first information is relatively simple.
  • the determining the first transmission path of the to-be-processed packet according to the second information and the first equivalent path table includes : Determine the second number of path indexes corresponding to the first equivalent path table; perform a hash calculation on the second information to generate a second calculation result; generate according to the second calculation result and the second number Second index; determining the first transmission path of the message to be processed; the first transmission path refers to the path indicated by the path information obtained by matching the first equivalent path table when the path index is the second index Sending path.
  • the determination process of the first transmission path is simpler and has better applicability.
  • the method further includes: adding a message header to the message to be processed, the message header including the second information and the Describe the information of the first transmission path.
  • a message header including the second information and the information of the first transmission path is added to the message to be processed, so that the subsequent message processing device can obtain the message of the message.
  • the message information and the information of the sending path can process the message more simply and quickly.
  • the method further includes: reporting the message to be processed and the first information to a CPU.
  • the message to be processed and the first information can be reported to the CPU, This allows the CPU to subsequently update the first exact matching flow table according to the received reported message and the first information corresponding to the message, so that the first exact matching flow table is more in line with the requirements of the application scenario and has better applicability.
  • the present application provides a device for determining a message transmission path.
  • the device includes: an acquisition module and a processing module; the acquisition module is configured to acquire a first equivalent path table and a first The aggregation flow table and the first exact matching flow table; the first aggregation flow table includes first entry information; the first exact matching flow table includes second entry information; the processing module is configured to The message field of the message to be processed and the first entry information determine the first information; the second information is determined according to the message field, the second entry information, and the first information; and the second information is determined according to the first information.
  • the second information and the first equivalent path table determine the first transmission path of the message to be processed.
  • the device in this implementation manner can obtain the first equal-cost path table, the first aggregation flow table, and the first exact matching flow table of the packet to be processed, and then according to the packet field of the packet to be processed and the value of the first aggregation flow table
  • the entry information determines the first information.
  • the second information is determined according to the message fields of the message to be processed, the first information, and the entry information of the first exact matching flow table.
  • the second information is equivalent to the first
  • the path table determines the first sending path of the message to be processed.
  • the device can choose to correspond to the message to be processed by matching the message field of the message to be processed with the entry information of the first exact matching flow table
  • the transmission path indicated by the current information is used as the first transmission path, or when the traffic load of the transmission path indicated by the current information is large, a relatively idle transmission path can be used as the first transmission path, so that the first message processing device corresponds to
  • the traffic load in the multiple transmission paths is relatively uniform, which avoids the problem of large load traffic in some transmission paths, packet loss or increased transmission delay, and also avoids the small traffic load of some transmission paths and network bandwidth. The problem of low utilization.
  • the processing module is specifically configured to: when the second entry information includes the first secret key matching the message field, according to The entry content corresponding to the first secret key determines whether to use third information; the third information is new information included in the entry content corresponding to the first secret key; when the third information is used, obtain The first delay difference; the first delay difference is the new and old path delay difference included in the entry content corresponding to the first secret key; the second delay difference is obtained; the second delay difference is the The interval between the time when the packet to be processed arrives at the device and the time at which the previous packet in the stream it is in arrives at the device; when the second delay difference is greater than the first delay difference, the third The information is the second information.
  • the device of this implementation mode when the message field of the message to be processed matches the secret key of the first exact matching flow table, it can determine whether to use the new information according to the content of the entry corresponding to the secret key matching the message field , That is, to determine whether the transmission path can be changed, and in the case of determining that the new information can be used, further determine whether it will affect the sending order of the packets in the flow where the packets to be processed is located, if it does not affect the sending order of the packets in the flow where it is located, Then, the transmission path can be determined according to the new information, so that the transmission path with a smaller load is used to send the message to be processed, and the transmission delay of the message is reduced.
  • the processing module is further configured to: when the third information is not used, obtain fourth information; the fourth information is the first Current information included in the entry content corresponding to a secret key; determining that the fourth information is the second information.
  • the device of this implementation mode when the message field of the message to be processed matches the secret key of the first exact matching flow table, it can determine whether to use the new information according to the content of the entry corresponding to the secret key matching the message field , That is, determine whether the transmission path needs to be changed, and when it is determined that no new information is needed, the transmission path is determined according to the current information, which avoids the problem of low traffic load on the transmission path corresponding to the current information and low network bandwidth utilization.
  • the processing module is further configured to: obtain fourth information when the second delay difference is less than or equal to the first delay difference;
  • the fourth information is current information included in the content of the entry corresponding to the first secret key; it is determined that the fourth information is the second information.
  • the device of this implementation mode can compare the transmission delay of the message in the stream where the message to be processed is located with the relationship between the delay between the new and the old path to determine whether changing the transmission path of the message to be processed will cause the message in the stream to be sent
  • the disorder of the sequence When it is determined that it will cause the confusion of the message sending sequence in the stream where it is located, the current information is used to determine the sending path, thereby avoiding the chaos of the message sending sequence in the stream where the path is changed, and ensuring the replacement of the sending path Accuracy.
  • the processing module is specifically configured to: when the second entry information does not include the first secret key that matches the message field, It is determined that the first information is the second information.
  • the device of this implementation mode can determine whether the flow of the message to be processed is an elephant flow by matching the message field of the message to be processed with the secret key of the first exact matching flow table.
  • the first exact matching flow table is When the secret key that matches the message field of the message to be processed is not included, it means that the flow of the message to be processed is not an elephant flow.
  • the transmission path can be determined based on the current information, which can avoid the traffic load of the transmission path corresponding to the current information. Small, the problem of low network bandwidth utilization occurs.
  • the processing module is specifically configured to: determine the first number of entries included in the first entry information; Perform hash calculation on the field of the message to generate a first calculation result; generate a first index according to the first calculation result and the first number; determine the first index according to the first index and the first entry information First information.
  • the device of this implementation manner can determine the first number of table items included in the first table item information; then perform a hash calculation on the message field of the message to be processed to generate the first calculation result; and according to the first calculation result And the first number to generate a first index; finally, the first information is determined according to the first index and the first entry information, and the process of determining the first information is relatively simple.
  • the processing module is specifically configured to: determine the second number of path indexes corresponding to the first equivalent path table; Perform a hash calculation to generate a second calculation result; generate a second index according to the second calculation result and the second number; determine the first transmission path of the message to be processed; the first transmission path refers to When the path index is the second index, match the sending path indicated by the path information obtained from the first equal-cost path table.
  • the device of this implementation manner can determine the second number of path indexes corresponding to the first equivalent path table; then perform a hash calculation on the second information to generate a second calculation result; and according to the second calculation result and the A second index is generated with the second number; finally, the first equivalent-cost path table is matched according to the second index to obtain path information of the first transmission path.
  • the determination process of the first transmission path is simpler and has better applicability.
  • the processing module is further configured to: add a message header to the message to be processed, and the message header includes the second information And the information of the first transmission path.
  • a message header including the second information and the information of the first transmission path is added to the message to be processed, so that the subsequent message processing apparatus can obtain the message of the message.
  • the message information and the information of the sending path can process the message more simply and quickly.
  • the processing module is further configured to: report the message to be processed and the first information to the CPU.
  • the second entry information of the first exact matching flow table does not include a secret key that matches the message field of the message to be processed
  • the message to be processed and the first information can be reported to the CPU
  • the CPU can subsequently update the first exact matching flow table according to the received reported message and the first information corresponding to the message, so that the first exact matching flow table is more in line with the requirements of the application scenario and has better applicability.
  • an embodiment of the present application provides a communication device that includes a processor, and when the processor executes a computer program or instruction in a memory, the method described in the first aspect is executed.
  • an embodiment of the present application provides a communication device.
  • the communication device includes a processor and a memory, where the memory is used to store computer programs or instructions; and the processor is used to execute the computer programs or instructions stored in the memory. Instructions to make the communication device execute the corresponding method as shown in the first aspect.
  • an embodiment of the present application provides a communication device, the communication device includes a processor, a memory, and a transceiver; the transceiver is used for receiving signals or sending signals; the memory is used for storing computer programs or Instruction; the processor is used to call the computer program or instruction from the memory to execute the method described in the first aspect.
  • an embodiment of the present application provides a communication device, the communication device includes a processor and an interface circuit; the interface circuit is configured to receive a computer program or instruction and transmit it to the processor; the processor runs The computer program or instruction is used to perform the corresponding method as shown in the first aspect.
  • an embodiment of the present application provides a computer storage medium, where the computer storage medium is used to store a computer program or instruction, and when the computer program or instruction is executed, the method described in the first aspect is implemented.
  • an embodiment of the present application provides a computer program product including a computer program or instruction.
  • the computer program or instruction When executed, the method described in the first aspect is realized.
  • the present application provides a method and device for determining a message transmission path.
  • the information determines the first information, and then the second information is determined according to the message fields of the message to be processed, the first information and the entry information of the first exact matching flow table, and finally, according to the second information and the first equivalent path table Determine the first sending path of the message to be processed.
  • the transmission path indicated by the information is used as the first transmission path, or when the traffic load of the transmission path indicated by the current information is large, a relatively idle transmission path may be used as the first transmission path, so that the first message processing device corresponds to multiple transmission paths.
  • the traffic load in the two sending paths is relatively uniform, which avoids the problems of large load traffic in some sending paths, packet loss or increased transmission delay, and also avoids the small traffic load of some sending paths and the occurrence of network bandwidth utilization. Lower question.
  • Figure 1 is a schematic diagram of an application scenario provided by this application.
  • FIG. 2 is a schematic structural diagram of an implementation manner of the communication system provided by this application.
  • FIG. 3 is a schematic structural diagram of an implementation manner of a router provided by this application.
  • FIG. 4 is a schematic flowchart of an implementation manner of a method for determining a message transmission path provided by this application;
  • FIG. 5 is a schematic flowchart of an implementation manner of the method for obtaining transmission path quality information provided by this application;
  • FIG. 6 is a schematic diagram of the format of a measurement message provided by this application.
  • FIG. 7 is a schematic flowchart of an implementation manner of the second method for updating the exact matching flow table provided by this application.
  • FIG. 8 is a structural block diagram of an implementation manner of an apparatus for determining a message transmission path provided by this application.
  • FIG. 9 is a structural block diagram of an implementation manner of the system for acquiring transmission path quality information provided by this application.
  • FIG. 10 is a structural block diagram of an implementation manner of a chip provided by this application.
  • the sending end message transmission device needs to select a sending path to send the pending message.
  • Fig. 1 in the application scenario shown in Fig. 1, there are three sending paths between router A and router B, namely path 1, path 2, and path 3.
  • router A receives a pending message sent to router B, before sending the pending message to router B, it needs to select a transmission path from path 1, path 2 and path 3, and then through the transmission path, The pending packets are sent to router B.
  • router A After router A receives the message to be processed, it usually obtains the equivalent path table of the message to be processed according to the message information of the message to be processed.
  • the equivalent path table contains the path 1, path 2, and path 3.
  • router A can select one path information from the three path information in the equal-cost path table, and then send the message to be processed to router B through the transmission path indicated by the path information. In this way, it is easy to send a large number of packets in the same transmission path, causing some transmission paths to have a large traffic load, causing congestion and packet loss or increasing transmission delay problems, while some transmission paths have a relatively high traffic load. Small, resulting in low network bandwidth utilization.
  • this application provides a method and device for determining a message sending path.
  • the communication system may include a first message transmission device 201 and a second message transmission device 202, and there is a network tunnel 203 between the first message transmission device 201 and the second message transmission device 202.
  • the first message transmission device 201 is the source node of the network tunnel 203
  • the second message transmission device 202 is the destination node of the network tunnel 203.
  • the network tunnel 203 may include multiple transmission paths, such as the path 2031 shown in FIG. 2032, 2033, 2034 and 2035.
  • the network tunnel 203 may be a segment routing V6 (segmet routing v6, SRV6) tunnel or a virtual extensive local area network (VXLAN) tunnel, etc.
  • V6 segment routing V6
  • VXLAN virtual extensive local area network
  • Both the first message transmission device 201 and the second message transmission device 202 may be routers.
  • the structure of the router can be seen in Figure 3.
  • Figure 3 is a schematic structural diagram of an implementation manner of the router provided in this application.
  • the router can include: an input interface module 301 and a network processor (NP) 302 , A central processing unit (CPU) 303, a storage module 304, and an output interface module 305.
  • the input interface module 301 can be used to receive messages, such as messages to be processed
  • the output interface module 305 can be used to send messages, such as processed messages to be processed.
  • the specific role of each component in the router Or the function can also refer to the content of the subsequent embodiments, which will not be described in detail here.
  • Figs. 2 and 3 does not constitute a limitation on the structure of the communication system and router of this application.
  • the communication system and router provided in this application may include more More or fewer components, or combinations of certain components, or different component arrangements. This application does not limit this.
  • the network architecture and application scenarios of the communication system described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation to the technical solutions provided in the embodiments of the present application.
  • Those of ordinary skill in the art It can be seen that with the evolution of the network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are equally applicable to similar technical problems.
  • FIG. 4 is a schematic flowchart of an implementation manner of a method for determining a message transmission path provided by this application.
  • the method can be applied to a first message processing device, the first message processing device is located at the sending end, and is used to receive the message to be processed and send the processed message to the destination corresponding to the message to be processed .
  • the first message processing apparatus may be the first message transmission device 201 shown in FIG. 2, or may be the message processing apparatus in the first message transmission device 201, when the first message processing device shown in FIG. 2
  • the transmission device 201 is the router shown in FIG. 3
  • the first packet processing device may be the NP of the router, and the method may include the following steps:
  • Step S101 Obtain the first equivalent path table, the first aggregate flow table, and the first exact matching flow table of the message to be processed.
  • the first equal-cost path table, the first aggregation flow table, and the first exact matching flow table of the message to be processed may all be managed and issued by the CPU connected to the first message processing apparatus, for example, the first message processing
  • the CPU connected to the device may be the CPU of the first message transmission device 201 shown in FIG. 2.
  • the first message transmission device 201 shown in FIG. 2 is the router shown in FIG. 3
  • the first message processing device is connected to The CPU may be the CPU of the router.
  • the first message processing apparatus may obtain the first equivalent path table, the first aggregation flow table, and the first exact matching flow table of the message to be processed according to the message fields of the message to be processed.
  • the message field of the message to be processed may be the destination address of the message to be processed.
  • the message field of the message to be processed may also be a five-tuple of the message to be processed, that is, the source address, destination address, source port number, destination port number, and message protocol of the message to be processed.
  • the first message processing apparatus may check access control lists (ACL) according to the five-tuple of the message to be processed, and obtain the first equivalent path table of the message to be processed.
  • ACL access control lists
  • the specific content of the first equivalent path table, the first aggregated flow table, and the first exact matching flow table of the to-be-processed packet obtained according to the packet field of the to-be-processed packet can also refer to the content of the subsequent embodiments.
  • the first equal-cost path table of the message to be processed includes multiple path information, the number of path information is the same as the number of transmission paths used to transmit the message, and one path information is used to indicate one transmission path.
  • the path information included in the first equal-cost path table may be indicated by a path identifier (for example, a path ID), or may be indicated by other information (for example, a path name, etc.) of the path, which is not limited in this application.
  • the first equivalent-cost path table is a linear table, and the first equivalent-cost path table can usually be matched by a path index to obtain path information corresponding to the path index, such as a path ID. Among them, one path information can correspond to one path index. Specifically, after the path index is obtained, the path index is used as an input value and input into the first equivalent path table to obtain an output value, and the output value is the path information corresponding to the path index.
  • the first equivalent path table includes path IDs.
  • Each path ID corresponds to a path index.
  • the specific path ID can be obtained. For example, after inputting path index 0 into table 1, you can get path 1, and after inputting path index 1 into table 1, you can get path 2, and so on.
  • the first aggregate flow table of the packet to be processed includes first entry information, and the first entry information may include multiple flow indication information for uniquely identifying flows.
  • the flow indications contained in the first aggregate flow table are The information is recorded as the first stream indication information, and the quantity of the first stream indication information can be set according to the requirements of the actual application scenario. For example, the number of the first stream indication information can be set to 64.
  • the first flow indication information may be a flow label (flowlabel) or a source port number.
  • the first packet processing device is a node of the SRV6 tunnel
  • the first flow indication information may be a flow label.
  • the first stream indication information may be the source port number.
  • the first aggregated flow table is also a linear table, and the first aggregated flow table can be matched by the information index to obtain the first flow indication information corresponding to the information index.
  • one first stream indication information can correspond to one or more information indexes, and the number of information indexes can also be set according to the needs of actual application scenarios.
  • the number of information indexes can be set to 64k, when the number of information indexes is 64k
  • the first aggregate flow table has a total of 64k entries. Specifically, after the information index is obtained, the information index is used as an input value and input into the first aggregated flow table to obtain an output value, and the output value is the first flow indication information corresponding to the information index.
  • the first aggregated flow table includes 64 flow labels, and each flow label corresponds to multiple information indexes, and there are a total of 64k information indexes, so the first aggregated flow table has a total of 64k entries.
  • the first exact matching flow table of the message to be processed can also be called the first elephant flow table.
  • the first exact matching flow table includes second entry information, and the second entry information can include multiple secret keys and each secret.
  • the content of the entry corresponding to the key, where the content of the entry corresponding to each secret key may include current flow indication information, whether to use new flow indication information, the delay difference of the path corresponding to the new and old flow indication information, and the new flow indication information, And the flow count, that is, the number of packets in the current flow and so on.
  • the current flow indication information may be referred to as the current information for short, for example, the current information may be the current flow label.
  • the new flow indication information may be referred to as new information for short.
  • the new information may be a new flow label.
  • the delay difference of the path corresponding to the new and old flow indication information may also be referred to as the delay difference of the new and old path.
  • the delay difference of the new and old path may be the delay difference of the path corresponding to the old and new flow labels.
  • Whether to use the new flow indication information can also be referred to simply as whether to use the new information.
  • whether to use the new information can be whether to use the new flow label.
  • the number of entries in the first exact matching flow table can be set according to the requirements of the actual application scenario. However, because the first exact matching flow table usually occupies a large amount of memory, the specification setting of the first exact matching flow table is smaller, for example, the first exact matching flow table.
  • the number of entries that exactly match the flow table can be set to 256.
  • the first exact matching flow table includes 256 secret keys, each secret key corresponds to an entry content, and each entry content includes the current flow label, whether to use the new flow label, and the path corresponding to the old and new flow labels. The delay difference, new flow label and flow count.
  • the current flow indication information and the new flow indication information in the first exact matching flow table are consistent with the content of the first flow indication information in the first aggregation flow table, that is, the first flow indication information in the first aggregation flow table includes the first flow indication information.
  • the current flow indication information in the exact matching flow table also includes the new flow indication information in the first exact matching flow table.
  • the 64 flow labels in the first aggregate flow table shown in Table 2 include the current flow label and the new flow label of the first exact matching flow table shown in Table 3.
  • the specific functions or functions of the first equal-cost path table, the first aggregation flow table, and the first exact matching flow table of the to-be-processed packet may refer to the content of the subsequent embodiments, which will not be described in detail here.
  • Step S102 Determine first information according to the message field of the message to be processed and the first entry information of the first aggregation flow table.
  • the first information can be determined according to the message field of the packet to be processed and the first entry information of the first aggregation flow table.
  • the first information refers to the first aggregation flow.
  • the first entry information of the table contains the first flow indication information corresponding to the message field of the message to be processed.
  • the message field of the message to be processed is used to identify the flow of the message to be processed.
  • the 5-tuple of the message to be processed can be selected as the message field of the message to be processed, or the message to be processed can be selected 3 or 4 parameters in the five-tuple of is used as the message field of the message to be processed.
  • determining the first information according to the message field of the message to be processed and the first entry information can be implemented in the following manner: determining the first number of entries included in the first entry information; and the message to be processed Hash calculation is performed on the message field to generate the first calculation result; the first index is generated according to the first calculation result and the first quantity; the first information is determined according to the first index and the first entry information.
  • hash calculation is performed on the message field of the message to be processed to generate the first calculation result, which can be implemented in the following manner: according to the message field of the message to be processed, the first bit of data is formed, and the first bit of data is regarded as the hash The input value of the Greek calculation model is hashed, and the output value obtained is the first calculation result.
  • the first index is generated according to the first calculation result and the first quantity, which can be implemented in the following manner: perform a remainder calculation on the first calculation result and the first quantity, and determine the obtained remainder as the first index.
  • Determining the first information according to the first index and the first entry information can be implemented in the following manner: according to the first index, the first entry information of the first aggregation flow table is matched to obtain the first information, that is, the first index As an input value, input to the first aggregated flow table to obtain an output value, which is the first information, where the first information is the first flow indication information corresponding to the first index in the first entry information.
  • the step S102 is described below with a specific example.
  • the first aggregated flow table of the message to be processed is shown in Table 2.
  • the first aggregated flow table has 64k entries in total, that is, the first number is 64k, according to the 5-tuple of the message to be processed, that is, the source address , Destination address, source port number, destination port number, and message protocol form the first bit of 128-bit data. If the quintuple of the message to be processed is less than 128 bits, the quintuple can be combined The vacant position other than that is recorded as 0. Then, the 128-bit first bit data is hashed to obtain the first calculation result. The first calculation result is the 32-bit bit data. After that, the 32-bit bit is used.
  • the output value is the first information, that is, the output value is The first stream indication information corresponding to the message to be processed. For example, if the obtained remainder is 2, the first information is flowlabel 3, that is, the first flow indication information corresponding to the packet to be processed is flowlabel 3.
  • Step S103 Determine second information according to the message field, the second entry information of the first exact matching flow table, and the first information.
  • the second entry information of the first exact matching flow table includes the message field of the message to be processed (for example, the message field of the message to be processed).
  • the first secret key that matches the quintuple of) the first secret key refers to the secret key that is the same as the message field of the message to be processed; when the second entry information does not include the first secret key, the first secret key.
  • the one piece of information is determined to be the second piece of information, and the second piece of information is used to determine the sending path of the message to be processed actually sent by the first message processing device, that is, it is used to determine the first sending path of the message to be processed.
  • the first exact matching flow table of the message to be processed is shown in Table 3.
  • Table 3 any one of secret key 1 to secret key 256 is different from the five-tuple of the message to be processed, then it is considered as Table 3. If the second entry information of the first exact matching flow table shown does not contain the first key, the first information is determined to be the second information.
  • the second entry information includes the first secret key
  • the third information refers to the first entry in the second entry information.
  • the content of the entry corresponding to the secret key contains new information, that is, to check the entry content corresponding to the first secret key in the first exact match flow table, and confirm whether the corresponding "new information is used" is "yes”. If "Whether to use new information" corresponds to "No", which means that the third information is not used.
  • the fourth information is obtained.
  • the fourth information refers to the first key corresponding to the second entry information
  • the current information contained in the entry content determines the fourth information as the second information.
  • the first exact matching flow table of the message to be processed is shown in Table 3, and the five-tuple of the message to be processed is the same as key2, it can be seen that the second table entry information includes the first secret key, and the first secret key Is key2, and then check the content of the entry corresponding to key2, "Whether to use the new flow label" is "No", it means that the third information is not used, that is, the new flow label is not used, and then, check the entry content corresponding to key2.
  • the current flow label contained in the entry content corresponding to key2 is flowlabel 26, that is, the fourth information is flowlabel 26, and the second information is flowlabel 26.
  • the third information When the content of the entry corresponding to the first secret key is checked, and it is confirmed that the "whether to use new information" corresponds to "Yes", it means that the third information is used.
  • the first delay difference refers to the old and new path delay difference contained in the entry content corresponding to the first secret key; and, the second delay difference is obtained, and the second delay difference is obtained.
  • the time delay difference refers to the time when the message to be processed reaches the first message processing device, and the time when the previous message of the message to be processed in the flow of the message to be processed reaches the first message processing device, between the two
  • the second delay difference is greater than the first delay difference, it means that the transmission path of the message to be processed is switched from the transmission path indicated by the current information to the transmission path indicated by the new information, which will not cause the message to be processed
  • the sending sequence of the messages in the flow is chaotic, the sending path of the messages to be processed can be switched, and the third information can be determined as the second information.
  • the first exact matching flow table of the message to be processed is shown in Table 3, and the five-tuple of the message to be processed is the same as key1.
  • the second table entry information includes the first secret key, and the first secret key Is key1, and then check the content of the entry corresponding to key1, "Whether to use the new flow label" is "Yes", it means that the third information is used, and the third information is flowlabel 64.
  • Check the content of the entry corresponding to key1 again, " The delay difference of the path corresponding to the new and old flow labels" is 50 microseconds, that is, the first delay difference is 50 microseconds.
  • the transmission path of the message to be processed is switched from the transmission path indicated by the current information to the transmission path indicated by the new information, which will cause the message to be processed in the flow If the sending order of the message is disordered, and the sending path of the message to be processed cannot be switched, the fourth information is obtained, and the fourth information is determined as the second information.
  • the first exact matching flow table of the message to be processed is shown in Table 3, and the five-tuple of the message to be processed is the same as key256.
  • the second table entry information includes the first secret key, and the first secret key Is key256, and then check the content of the entry corresponding to key256, "Whether to use the new flow label" is "Yes", it means that the third information is used, and the third information is flowlabel 63.
  • Check the content of the entry corresponding to key256 again, " The delay difference of the path corresponding to the new and old flow labels" is 30 microseconds, that is, the first delay difference is 30 microseconds.
  • the time interval between the two is 20 microseconds, that is, the second time
  • the delay difference is 20 microseconds. It can be seen that if the second delay difference is less than the first delay difference, the fourth information is obtained.
  • the fourth information is flowlabel 58. If the fourth information is determined as the second information, the second information is flowlabel. 58.
  • the message to be processed and the first information may be reported as sampled data to the first message for processing The CPU to which the device is connected.
  • the second entry information of the first exact matching flow table of the message to be processed does not include the first secret key, it can also be determined first whether the message length of the message to be processed exceeds the preset byte length (for example, 1000 bytes), if the message length of the message to be processed exceeds the preset byte length, the message to be processed and the first information may be reported as sampled data to the CPU connected to the first message processing apparatus.
  • the preset byte length For example, 1000 bytes
  • the second entry information of the first exact matching flow table of the message to be processed does not include the first secret key, it can also be determined first whether the message length of the message to be processed exceeds the preset byte length (for example, 1000 bytes), if the message length of the message to be processed exceeds the preset byte length, the message to be processed can be stored as sampled data, and then the sampled data is reported according to the preset sampling ratio (for example, 1000:1) The CPU connected to the first message processing device.
  • the preset byte length For example, 1000 bytes
  • the foregoing first message processing apparatus may be the NP 302 shown in FIG. 3, and the CPU connected to the first message processing apparatus may be the CPU 303 shown in FIG. 3.
  • the first message processing apparatus may store the message to be processed as sample data in a storage device connected to the first message processing apparatus.
  • the storage device may be the storage module 304 shown in FIG. 3.
  • the entry content corresponding to the first secret key when it is determined that the second entry information of the first exact matching flow table of the message to be processed includes the first secret key, the entry content corresponding to the first secret key will also include Add 1 to the current number corresponding to the "flow count”, and update the current number corresponding to the "flow count” to count the packets contained in the flow in which the packets to be processed are located, and subsequently can be based on the number of packets contained in each flow Determine whether the stream is an elephant stream.
  • Step S104 Determine a first sending path of the message to be processed according to the second information and the first equivalent path table.
  • determining the first transmission path of the to-be-processed message according to the second information and the first equivalent-cost path table can be implemented in the following manner: determining the second number of path indexes corresponding to the first equivalent-cost path table; Perform a hash calculation on the second information to generate a second calculation result; generate a second index according to the second calculation result and the second quantity; determine the first transmission path of the message to be processed; the first transmission path refers to the path index When it is the second index, it matches the sending path indicated by the path information obtained from the first equivalent-cost path table.
  • performing a hash calculation on the second information to generate the second calculation result can be implemented in the following manner: the second bit data is formed according to the second information; the second bit data is used as the input value of the hash calculation model to perform the hash calculation. Greek calculation, the output value obtained is the second calculation result.
  • 128-bit second-bit data can be formed according to the second information and 0.
  • the source address of the sending end and the destination address of the destination end when the first message processing apparatus sends the message to be processed, and 0, form the second bit of data.
  • the source address and the destination address of the SRV6 tunnel may be used according to the second information, and 0, constitute the second bit of data.
  • the source port number and source address of the sending end when the first message processing apparatus sends the message to be processed, and the destination port number and destination address of the destination end may form the second bit of data.
  • the source port number, source address, destination port number, and destination address are the source port number, source address, destination port number, and destination address of the VXLAN tunnel, respectively.
  • the source port number, source address, destination port number, and destination address of the VXLAN tunnel, and 0, form the second bit of data.
  • Generating the second index according to the second calculation result and the second quantity can be implemented in the following manner: performing a remainder calculation on the second calculation result and the second quantity, and determining the obtained remainder as the second index.
  • Determining the first transmission path of the message to be processed can be implemented in the following manner: according to the second index, the first equivalent path table of the message to be processed is matched to obtain the path information of the first transmission path, that is, the second index As the path index is input to the first equivalent path table, the output value obtained is the path information of the first transmission path, that is, the first transmission path of the message to be processed refers to the matching when the path index is the second index The sending path indicated by the path information obtained from the first equal-cost path table.
  • a message header may be added to the message to be processed.
  • the message header includes the second information and the information of the first transmission path.
  • the information of the first transmission path may be the source address and the destination address of the first transmission path.
  • the information of the first transmission path is the information of the SRV6 tunnel. Source address and destination address.
  • the information of the first transmission path may be the source address and the destination address of the VXLAN tunnel.
  • the first equivalent path table, the first aggregation flow table, and the first exact matching flow table of the message to be processed are first obtained, and then the message transmission path of the message to be processed is obtained.
  • the message field and the entry information of the first aggregated flow table determine the first information.
  • the second information is determined according to the message field, the first information, and the entry information of the first exact matching flow table of the message to be processed.
  • the transmission path indicated by the information is used as the first transmission path, or when the traffic load of the transmission path indicated by the current information is large, a relatively idle transmission path may be used as the first transmission path, so that the first message processing device corresponds to multiple transmission paths.
  • the traffic load in the two sending paths is relatively uniform, which avoids the problems of large load traffic in some sending paths, packet loss or increased transmission delay, and also avoids the small traffic load of some sending paths and the occurrence of network bandwidth utilization. Lower question.
  • one or more second equal-cost path tables, one or more second aggregate flow tables, and one or more second exact matching flow tables may be set in the message transmission device at the sending end.
  • the second equal-cost path table, the second aggregation flow table, and the second exact matching flow table all correspond to the message field of the message.
  • the first message processing device at the sending end can obtain the second equivalent path table corresponding to the message field of the message to be processed.
  • the second equivalent-cost path table is determined as the first equivalent-cost path table of the message to be processed.
  • the first message processing apparatus may obtain the second aggregated flow table and the second exact matching flow table corresponding to the message field of the message to be processed, and separately obtain the second aggregated flow table and the second exact matching flow table. Determined to be the first aggregated flow table and the first exact matching flow table.
  • the contents of the second equivalent path table, the second aggregated flow table, and the second exact matching flow table may refer to the contents of the first equivalent path table, the first aggregated flow table, and the first exact matching flow table in the foregoing embodiment. I won't repeat it here.
  • a sender message transmission device can correspond to one or more destination message transmission devices, and the same group of sender message transmission devices and destination message transmission devices can include one or more message transmission channels (
  • the message transmission channel may be a network tunnel), and a message transmission channel may include one or more transmission paths for transmitting messages.
  • a message transmission channel corresponds to a second equal-cost path table, a second aggregation flow table, and a second exact matching flow table
  • the message transmission device at the sending end can, according to the change of the transmission path in the message transmission channel,
  • the second equal-cost path table, the second aggregation flow table, and the second exact matching flow table corresponding to the packet transmission channel are managed.
  • the second equivalent path table, the second aggregation flow table, and the second exact matching flow table corresponding to a message transmission channel of the message transmission device at the sending end are The content of management is explained.
  • the second equal-cost path table, the second aggregation flow table, and the second exact matching flow table corresponding to any packet transmission channel reference may be made to the content of the following embodiments.
  • the first message transmission device 201 shown in FIG. 2 is a sender message transmission device
  • the second message transmission device 202 shown in FIG. 2 is a destination message transmission device
  • the first message There is a message transmission channel between the transmission device 201 and the second message transmission device 202, that is, the network tunnel 203, and the first message transmission device 201 and the second message transmission device 202 are both routers.
  • the first packet transmission device 201 is recorded as the first router, the NP in the first router is recorded as the first NP, and the CPU in the first router is recorded as the first CPU.
  • the second packet transmission device 202 is denoted as a second router, and the NP in the second router is denoted as a second NP.
  • a second equal-cost path table, a second aggregation flow table, and a second exact matching flow table are set in the first router.
  • the second equivalent path table corresponding to the network tunnel 203 remains unchanged. Accordingly, the first equivalent path table of all pending packets transmitted through the network tunnel 203 is the same , Are the second equivalent path table.
  • the second aggregate flow table corresponding to the network tunnel 203 is issued by the first CPU to the first NP when the system is started. During the operation of the first NP, the second aggregate flow table corresponding to the network tunnel 203 will not change. Correspondingly, all the first aggregated flow tables of the to-be-processed packets transmitted through the network tunnel 203 are also the same, and they are all the second aggregated flow tables.
  • the second exact matching flow table corresponding to the network tunnel 203 may be updated according to the quality information of the transmission path included in the network tunnel 203.
  • the quality information of each transmission path includes the packet loss rate and the third delay difference, where the third delay difference refers to the transmission delay difference of the transmission path, that is, the message passes from the sending end of the transmission path to the destination end. The length of time.
  • FIG. 5 is a schematic flowchart of an embodiment of the method for obtaining transmission path quality information provided by this application.
  • the method can include the following steps:
  • Step S201 The first NP generates a measurement message.
  • the measurement packet may include multiple, the number of measurement packets is recorded as the third number, and the third number is equal to the number of flow indication information included in the second aggregation flow table corresponding to the network tunnel 203.
  • the second The flow indication information included in the aggregate flow table is recorded as the second flow indication information.
  • One measurement message corresponds to one second flow indication information. For example, if the second flow indication information included in the second aggregation flow table corresponding to the network tunnel 203 is flowlabel 1, flowlabel 2, ..., flowlabel 64, the number of measurement packets is 64, that is, the third number is 64, and , Flowlabel 1, flowlabel 2, ..., flowlabel 64 respectively correspond to a measurement message.
  • the format of the measurement message is shown in Figure 6.
  • the message field of the measurement message includes media access control (MAC), transmission timestamp, transmission count, and second flow indication information corresponding to the measurement message.
  • MAC media access control
  • transmission timestamp is used to indicate the time when the first NP sends the measurement packet to the second router
  • transmission count is used to indicate that the first NP sends the measurement packet through the transmission path corresponding to the second flow indication information.
  • the first NP may periodically generate measurement packets according to the first preset duration, for example
  • the first preset duration can be set to 10 milliseconds, and a measurement message is generated every 10 milliseconds.
  • the second exact matching flow table corresponding to the network tunnel 203 can be updated periodically.
  • Step S202 The first NP determines the second transmission path of the measurement packet according to the second flow indication information corresponding to the measurement packet and the second equivalent-cost path table.
  • the second transmission path of the measurement packet is determined according to the second flow indication information corresponding to each measurement packet and the second equal-cost path table, and the second transmission path is a network tunnel A transmission path included in 203.
  • the second transmission path of the measurement packet may be correspondingly associated with the second flow indication information of the measurement packet.
  • the second equivalent-cost path table corresponding to the network tunnel 203 remains unchanged, and accordingly, the first equivalent-cost path table of all pending packets transmitted through the network tunnel 203 The same, and both are the second equivalent path table. Therefore, according to the specific implementation manner of determining the second transmission path of the measurement packet according to the second flow indication information and the second equivalent path table corresponding to each measurement packet, refer to the embodiment shown in FIG. 4 according to the second information
  • the specific implementation manner of determining the first transmission path of the to-be-processed message is determined by the first equivalent path table, which will not be repeated here.
  • Step S203 The first NP sends the measurement message to the second router through the second sending path.
  • the first NP After the first NP generates a measurement message every time and determines the second transmission path of each measurement message, it sends the measurement message to the second router through the second transmission path of the measurement message.
  • Step S204 The second NP determines the first time, the second time, and the fourth quantity corresponding to the second flow indication information corresponding to the measurement packet according to the measurement packet received by the second router.
  • the second NP of the second router determines that the first NP sends according to the transmission timestamp, the transmission count and the second flow indication information corresponding to the measurement message contained in the measurement message.
  • the transmission time of the measurement packet is recorded as the first time corresponding to the second flow indication information, and it is determined that when the first NP sends the measurement packet, it has passed the second flow indication information corresponding to the second flow.
  • the number of processed packets to be processed sent by the sending path is recorded as the fourth number corresponding to the second flow indication information.
  • the second NP will also record the number of the measurement packets received by the second router Receiving time, the receiving time is recorded as the second time corresponding to the second stream indication information.
  • Step S205 The second NP determines the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information according to the first time, the second time, and the fourth quantity corresponding to the second flow indication information. .
  • the first NP receives a message to be processed, and before sending the message to the second router through the network tunnel 203, it adds a message header to the message to be processed ,
  • the message header includes the second information, so the processed message to be processed received by the second router includes the second information.
  • the second NP can determine the path received by the second router through the second transmission path corresponding to each second flow indication information according to the second information of the processed packet to be processed received by the second router.
  • the number of processed packets to be processed is recorded as the fifth number corresponding to the second flow indication information.
  • the second NP may determine the packet loss rate and third packet loss rate of the second transmission path corresponding to the second flow indication information according to the first time, the second time, the fourth quantity, and the fifth quantity corresponding to each second flow indication information. Latency is poor.
  • Step S206 The second NP sends the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information to the first router.
  • the second NP may determine the loss of the second transmission path corresponding to the second flow indication information.
  • the packet rate and the third delay difference are sent to the first router together with the second flow indication information.
  • the first NP may also periodically combine each second flow indication information obtained in the same period, and the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information, Correspondingly sent to the first router together.
  • Step S207 The first CPU obtains the quality of the second transmission path corresponding to the second flow indication information according to the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information received by the first router. information.
  • the first CPU of the first router may perform the second transmission according to the second flow indication information.
  • the packet loss rate of the path and the third delay difference are obtained, and the quality information of the second transmission path corresponding to the second flow indication information is acquired.
  • the first CPU may obtain the quality information of the second transmission path corresponding to each second flow indication information among all the second flow indication information included in the second aggregate flow table corresponding to the network tunnel 203 according to the method shown in FIG. 5. After acquiring the quality information of the second transmission path corresponding to each second flow indication information, the first CPU may update the second exact matching flow table corresponding to the network tunnel 203 according to the acquired quality information.
  • the first CPU may periodically obtain each of all the second flow indication information included in the second aggregation flow table corresponding to the network tunnel 203 Quality information of the second transmission path corresponding to the second stream indication information.
  • the first CPU may periodically update the second exact matching flow table corresponding to the network tunnel 203. Taking a cycle as an example, the content of the update of the second exact matching flow table corresponding to the network tunnel 203 by the first CPU is introduced in conjunction with FIG. 7.
  • FIG. 7 is a schematic flowchart of an implementation manner of the second method for updating the exact matching flow table provided by this application.
  • the method can include the following steps:
  • Step S301 Obtain the quality information of the second transmission path corresponding to the second flow indication information included in the second exact matching flow table and the sample data reported by the first NP.
  • the sampled data includes the to-be-processed message and the first information corresponding to the to-be-processed message.
  • the message to be processed included in the sampling data is recorded as a sampling message.
  • Step S302 Update the second exact matching flow table according to the sampling data and the quality information.
  • Updating the second exact matching flow table according to the sampling data and quality information can be implemented in the following manner: updating the free entry of the second exact matching flow table according to the sampling data; updating the entry content of the second exact matching flow table according to the quality information .
  • the free entry of the second exact matching flow table refers to an entry whose entry information in the second exact matching flow table is empty.
  • Updating the free entry of the second exact matching flow table according to the sampled data can be implemented in the following manner: obtaining the message field of the sampled message included in the sampling data; determining whether there is an free entry in the second exact matching flow table; if There is a free entry in the second exact matching flow table, the message field of the sampled message is added to the free entry as the secret key of the second exact matching flow table, and the first information of the sampled message is used as the secret The current information of the content of the entry corresponding to the key is added to the free entry; or, if there is no free entry in the second exact matching flow table, the sampling data is deleted.
  • the sampling message may include multiple, and according to this implementation manner, the second exact matching flow table may be updated according to each sampling message.
  • Updating the entry content of the second exact matching flow table according to the quality information can be implemented in the following manner: according to the quality information, the fifth information and the sixth information are determined, where the fifth information refers to the second transmission path with good quality
  • the second flow indication information the sixth information refers to the second flow indication information corresponding to the second transmission path with poor quality, when the packet loss rate included in the quality information is less than or equal to the packet loss rate threshold and/or the third delay difference is less than or equal to
  • the second transmission path corresponding to the quality information can be determined as a good quality transmission path.
  • the second transmission path corresponding to the quality information can be determined as the poor quality transmission path; the new information in the second exact matching flow table whose current information is the sixth information is updated to the fifth information, and The current information is the new and old path delay difference of the entry content of the sixth information is updated to the difference between the third delay difference corresponding to the sixth information and the third delay difference corresponding to the fifth information, and the current information is the sixth information
  • the "Whether to use the new information" of the table entry content is updated to "Yes".
  • both the packet loss rate threshold and the delay difference threshold can be set according to actual application scenarios.
  • the second exact matching flow table it is also possible to periodically read the flow count included in the second exact matching flow table, and determine whether the flow corresponding to the flow count is an elephant flow according to the flow count. If the flow corresponding to the flow count is not an elephant flow, delete the flow count. The entry corresponding to the flow count. In addition, it can also be determined according to the flow count whether the flow corresponding to the flow count has no new packets arriving within the second preset time period. If no new packets arrive within the second preset time period, delete the flow corresponding to the flow count. Table entry. Among them, if the flow count is greater than or equal to the packet number threshold, it can be determined that the flow corresponding to the flow count is an elephant flow. Both the second preset duration and the message quantity threshold can be set according to actual application scenarios.
  • the methods and operations implemented by the message processing device, NP or CPU can also be implemented by components (such as chips or circuits) that can be used in the message processing device, NP or CPU.
  • each network element such as a message processing device, NP or CPU, etc.
  • each network element includes a hardware structure or a software module corresponding to each function, or a combination of the two.
  • the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software-driven hardware depends on the specific application and design constraint conditions of the technical solution. Professionals and technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered as going beyond the scope of this application.
  • the embodiment of this application can divide the message processing device, NP or CPU, etc. into functional modules according to the above method examples.
  • each functional module can be divided corresponding to each function, or two or more functions can be integrated.
  • a processing module In a processing module.
  • the above-mentioned integrated modules can be implemented in the form of hardware or software function modules. It should be noted that the division of modules in the embodiments of the present application is illustrative, and is only a logical function division, and there may be other division methods in actual implementation. The following is an example of dividing each function module corresponding to each function.
  • FIG. 8 is a structural block diagram of an implementation manner of an apparatus for determining a message transmission path provided by this application.
  • the device 800 may include: an acquisition module 801 and a processing module 802.
  • the device 800 can be used to perform the actions performed by the first packet processing device in the above method embodiment.
  • the obtaining module 801 may be used to obtain the first equivalent path table, the first aggregate flow table, and the first exact matching flow table of the message to be processed; the first aggregate flow table includes first entry information ; The first exact matching flow table includes second entry information.
  • the processing module 802 may be configured to determine first information according to the message fields of the message to be processed and the first entry information; according to the message fields, the second entry information, and the The first information determines the second information; the first sending path of the message to be processed is determined according to the second information and the first equivalent path table.
  • the processing module 802 is specifically configured to: when the second entry information includes the first secret key that matches the field of the message, determine whether or not according to the entry content corresponding to the first secret key Use the third information; the third information is the new information included in the entry content corresponding to the first secret key; when the third information is used, the first delay difference is obtained; the first delay difference Is the time delay difference between the old and new paths included in the entry content corresponding to the first secret key; obtains the second delay difference; the second delay difference is the time when the message to be processed arrives at the device and the flow where it is The interval between the time when the previous message arrives at the device; when the second delay difference is greater than the first delay difference, it is determined that the third information is the second information.
  • the processing module 802 is further configured to: when the third information is not used, obtain fourth information; the fourth information is current information included in the content of the entry corresponding to the first secret key; It is determined that the fourth information is the second information.
  • the processing module 802 is further configured to: when the second delay difference is less than or equal to the first delay difference, obtain fourth information; the fourth information corresponds to the first secret key The current information included in the table entry content; determine that the fourth information is the second information.
  • the processing module 802 is specifically configured to determine that the first information is the second information when the second entry information does not include the first key matching the message field.
  • the processing module 802 is specifically configured to: determine the first number of entries included in the first entry information; perform a hash calculation on the message field of the message to be processed to generate a first calculation Result; generating a first index according to the first calculation result and the first number; determining the first information according to the first index and the first entry information.
  • the processing module 802 is specifically configured to: determine the second number of path indexes corresponding to the first equivalent path table; perform a hash calculation on the second information to generate a second calculation result; The second calculation result and the second number generate a second index; determine the first transmission path of the message to be processed; the first transmission path means that when the path index is the second index, it matches the The sending path indicated by the path information obtained from the first equal-cost path table.
  • the processing module 802 is further configured to: add a message header to the message to be processed, and the message header includes the second information and the information of the first transmission path.
  • the processing module 802 is further configured to report the message to be processed and the first information to the CPU.
  • the device 800 can implement the steps or procedures executed by the first message processing device in the method shown in FIG. 4 corresponding to the embodiment of the present application, and the device 800 may include a device for executing the first message processing device in the method shown in FIG. 4 A module of a method executed by a message processing device.
  • each module in the device 800 and other operations and/or functions described above are used to implement the corresponding steps of the method shown in FIG. 4.
  • the acquiring module 801 in the device 800 may be used to execute step S101 in the method shown in FIG. 4
  • the processing module 802 may be used to execute step S102 to step S104 in the method shown in FIG.
  • the system 900 may include: a first message processing device 901, a second message processing device 902, and a processing device 903. Among them, the first packet processing device 901 and the processing device 903 are located at the sending end, and the second packet processing device 902 is located at the destination end.
  • the system 900 can be used to execute the actions performed by the first NP, the second NP, and the first CPU in the method embodiment shown in FIG. 5 above.
  • the first packet processing device 901 may be configured to: generate a measurement packet; determine the second transmission path of the measurement packet according to the second flow indication information and the second equivalent path table corresponding to the measurement packet; The measurement message is sent to the second message processing apparatus 902 through the second sending path.
  • the second packet processing device 902 may be configured to: according to the received measurement packet, determine the first time, the second time, and the fourth quantity corresponding to the second flow indication information corresponding to the measurement packet; The first time, the second time, and the fourth quantity corresponding to the second flow indication information determine the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information; send to the first packet processing device The packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information.
  • the processing means 903 may be configured to: according to the packet loss rate and the third delay difference of the second transmission path corresponding to the second flow indication information received by the first message processing means 901, obtain the second flow indication information corresponding to the second flow indication information. 2. Send the quality information of the path.
  • the system 900 can implement the steps or processes executed by the first NP, the second NP, and the first CPU in the method shown in FIG. In the method shown in 5, the first NP, the second NP, and the device of the method executed by the first CPU.
  • each device in the system 900 and other operations and/or functions described above are used to implement the corresponding steps of the method shown in FIG. 5.
  • the first message processing device 901 in the system 900 may be used to perform steps S201 to S203 in the method shown in FIG. 5
  • the second message processing device 902 may be used to perform steps in the method shown in FIG. 5 From S204 to step S206, the processing device 903 may be used to execute step S207 in the method shown in FIG. 5.
  • the present application also provides a device for updating the second exact matching flow table.
  • the update device may include a processing module.
  • the updating apparatus may execute the function of the first CPU in the method embodiment shown in FIG. 7, or implement the steps or processes executed by the first CPU in the method embodiment shown in FIG. 7.
  • the processing module of the update device may be used to: obtain the quality information of the second transmission path corresponding to the second flow indication information included in the second exact matching flow table and the sampling data reported by the first message processing device; The sampling data and the quality information update the second exact matching flow table.
  • the updating device may implement the steps or processes executed by the first CPU in the method shown in FIG. 7 corresponding to the embodiment of the present application, and the updating device may include the first CPU for executing the method shown in FIG.
  • the module of the method to be executed The module of the method to be executed.
  • each module in the update device and other operations and/or functions described above are used to implement the corresponding steps of the method shown in FIG. 7.
  • the processing module in the update device can be used to execute step S301 to step S302 in the method shown in FIG. 7.
  • the embodiment of the present application also provides a processing device, including a processor and an interface.
  • the processor may be used to execute the method in the foregoing method embodiment.
  • the aforementioned processing device may be a chip.
  • FIG. 10 is a structural block diagram of an embodiment of the chip provided by this application.
  • the chip shown in FIG. 10 may be a general-purpose processor or a special-purpose processor.
  • the chip 1000 includes a processor 1001.
  • the processor 1001 may be used to support the device shown in FIG. 8 to execute the technical solution shown in FIG. 4, to support the device shown in FIG. 9 to execute the technical solution shown in FIG. 5, and to support the aforementioned update device to execute the technical solution shown in FIG. Technical solutions.
  • the chip 1000 may also include a transceiver 1002.
  • the transceiver 1002 is used to receive the control of the processor 1001, and is used to support the device shown in FIG. 8 to execute the technical solution shown in FIG. 4, and to support the The device executes the technical solution shown in FIG. 5 and supports the above-mentioned update device to execute the technical solution shown in FIG. 7.
  • the chip 1000 shown in FIG. 10 may further include: a storage medium 1003.
  • the chip shown in Figure 10 can be implemented using the following circuits or devices: one or more field programmable gate arrays (FPGA), programmable logic devices (PLD) , Application specific integrated circuit (ASIC), system on chip (SoC), central processor unit (CPU), network processor (NP), digital signal processing circuit (digital signal processor, DSP), microcontroller (microcontroller unit, MCU), controller, state machine, gate logic, discrete hardware components, any other suitable circuits, or capable of performing various functions described throughout this application Any combination of circuits.
  • FPGA field programmable gate arrays
  • PLD programmable logic devices
  • ASIC Application specific integrated circuit
  • SoC system on chip
  • CPU central processor unit
  • NP network processor
  • DSP digital signal processing circuit
  • microcontroller microcontroller unit, MCU
  • controller state machine, gate logic, discrete hardware components, any other suitable circuits, or capable of performing various functions described throughout this application Any combination of circuits.
  • each step of the above method can be completed by an integrated logic circuit of hardware in the processor or instructions in the form of software.
  • the steps of the method disclosed in the embodiments of the present application may be directly embodied as being executed and completed by a hardware processor, or executed and completed by a combination of hardware and software modules in the processor.
  • the software module can be located in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, or electrically erasable programmable memory, registers.
  • the storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware. In order to avoid repetition, it will not be described in detail here.
  • the processor in the embodiment of the present application may be an integrated circuit chip with signal processing capability.
  • the steps of the foregoing method embodiments can be completed by hardware integrated logic circuits in the processor or instructions in the form of software.
  • the above-mentioned processor may be a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components .
  • DSP digital signal processor
  • ASIC application specific integrated circuit
  • FPGA field programmable gate array
  • the methods, steps, and logical block diagrams disclosed in the embodiments of the present application can be implemented or executed.
  • the general-purpose processor may be a microprocessor or the processor may also be any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present application can be directly embodied as being executed and completed by a hardware decoding processor, or executed and completed by a combination of hardware and software modules in the decoding processor.
  • the software module can be located in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, or electrically erasable programmable memory, registers.
  • the storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
  • the memory in the embodiments of the present application may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memory.
  • the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (programmable ROM, PROM), an erasable programmable read-only memory (erasable PROM, EPROM), a Erase programmable read-only memory (electrically EPROM, EEPROM) or flash memory.
  • the volatile memory may be random access memory (RAM), which is used as an external cache.
  • RAM random access memory
  • static random access memory static random access memory
  • dynamic RAM dynamic RAM
  • DRAM dynamic random access memory
  • synchronous dynamic random access memory synchronous DRAM, SDRAM
  • double data rate synchronous dynamic random access memory double data rate SDRAM, DDR SDRAM
  • enhanced synchronous dynamic random access memory enhanced SDRAM, ESDRAM
  • synchronous connection dynamic random access memory serial DRAM, SLDRAM
  • direct rambus RAM direct rambus RAM
  • the embodiments of the present application also provide a computer program product.
  • the computer program product includes: a computer program or instruction.
  • the computer program or instruction runs on a computer, the computer executes FIG. 4 , The method of any one of the embodiments shown in FIG. 5 and FIG. 7.
  • the embodiment of the present application also provides a computer storage medium that stores a computer program or instruction, and when the computer program or instruction runs on a computer, the computer executes FIG. 4 , The method of any one of the embodiments shown in FIG. 5 and FIG. 7.
  • the computer program product includes one or more computer programs or instructions.
  • the computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices.
  • the computer program or instruction may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium.
  • the computer program or instruction may be downloaded from a website, computer,
  • the server or data center is connected to another website, computer, server or data center through wired (such as coaxial cable, optical fiber, digital subscriber line (digital subscriber line, DSL)) or wireless (such as infrared, wireless, microwave, etc.) transmission.
  • the computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server or a data center integrated with one or more available media.
  • the usable medium may be a magnetic medium (for example, a floppy disk, a hard disk, and a magnetic tape), an optical medium (for example, a high-density digital video disc (digital video disc, DVD)), or a semiconductor medium (for example, a solid state disk (solid state disc, SSD)) etc.
  • a magnetic medium for example, a floppy disk, a hard disk, and a magnetic tape
  • an optical medium for example, a high-density digital video disc (digital video disc, DVD)
  • a semiconductor medium for example, a solid state disk (solid state disc, SSD)
  • component used in this specification are used to denote computer-related entities, hardware, firmware, a combination of hardware and software, software, or software in execution.
  • the component may be, but is not limited to, a process, a processor, an object, an executable file, a thread of execution, a program, and/or a computer running on a processor.
  • the application running on the computing device and the computing device can be components.
  • One or more components may reside in processes and/or threads of execution, and components may be located on one computer and/or distributed between two or more computers.
  • these components can be executed from various computer readable media having various data structures stored thereon.
  • a component can be based on, for example, a signal having one or more data packets (e.g. data from two components that interact with another component in a local system, a distributed system, and/or a network, such as the Internet that interacts with other systems through signals) Communicate through local and/or remote processes.
  • data packets e.g. data from two components that interact with another component in a local system, a distributed system, and/or a network, such as the Internet that interacts with other systems through signals
  • the disclosed system, device, and method can be implemented in other ways.
  • the device embodiments described above are only illustrative.
  • the division of the modules is only a logical function division, and there may be other divisions in actual implementation, for example, multiple modules or components may be combined or It can be integrated into another system, or some features can be ignored or not implemented.
  • the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may be in electrical, mechanical or other forms.
  • the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the objectives of the solutions of the embodiments.
  • the functional modules in the various embodiments of the present application may be integrated into one processing unit, or each module may exist alone physically, or two or more modules may be integrated into one unit.
  • the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer readable storage medium.
  • the technical solution of this application essentially or the part that contributes to the existing technology or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including Several instructions are used to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (read-only memory, ROM), random access memory (random access memory, RAM), magnetic disk or optical disk and other media that can store program code .
  • the device for determining the message transmission path, the system for acquiring the quality information of the transmission path, the device for updating the second exact matching flow table, the computer storage medium, the computer program product, and the chip provided in the above embodiments of the present application are all used to execute the above provided Therefore, the beneficial effects that can be achieved can refer to the corresponding beneficial effects of the method provided above, which will not be repeated here.
  • the device for determining the message transmission path, the system for acquiring the quality information of the transmission path, the second accurate matching flow table update device, computer storage media, computer program products, and chip embodiments are basically similar to the implementation of the method. Example, so the description is relatively simple, and the relevant details can be referred to the description in the method embodiment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本申请公开了一种确定报文发送路径的方法及装置。该方法包括:获取待处理报文的第一等价路径表、包括第一表项信息的第一聚合流表和包括第二表项信息的第一精确匹配流表;根据待处理报文的报文字段和第一表项信息确定第一信息;根据报文字段、第二表项信息和第一信息确定第二信息;根据第二信息和第一等价路径表,确定待处理报文的第一发送路径。该方法通过将待处理报文的报文字段与第一精确匹配流表的表项信息匹配,确定是否切换路径,使得第一报文处理装置对应的多条发送路径中的流量负载较为均匀,避免了某些发送路径负载流量较大,发生丢包或增大传输时延的问题,也避免了某些发送路径流量负载较小,发生网络带宽利用率较低的问题。

Description

确定报文发送路径的方法及装置
本申请要求于2020年6月16日提交中国专利局、申请号为202010547999.7、发明名称为“确定报文发送路径的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,尤其涉及一种确定报文发送路径的方法及装置。
背景技术
在报文的传输过程中,发送端报文传输设备接收到待处理报文,将待处理报文发送至待处理报文对应的目的端报文传输设备时,如果两个报文传输设备之间存在多条发送路径,则发送端报文传输设备需要确定一条发送路径,以便通过该发送路径将待处理报文发送至目的端报文传输设备。
目前,发送端报文传输设备接收到待处理报文后,通常会根据待处理报文的报文信息,获取待处理报文的等价路径表,该等价路径表包括多条发送路径的路径信息,发送端报文传输设备可以在等价路径表中选取一个路径信息,后续可以使用该路径信息对应的发送路径将待处理报文发送至目的端报文传输设备。采用此种方式,容易将大量报文集中在同一条发送路径中发送,造成某些发送路径流量负载较大,发生拥塞丢包或增大传输时延的问题,而某些发送路径流量负载较小,导致网络带宽利用率较低。
发明内容
本申请提供了一种确定报文发送路径的方法及装置,以解决报文传输过程中由于发送路径选择不当,导致拥塞丢包、传输时延大以及网络带宽利用率低的问题。
第一方面,本申请提供了一种确定报文发送路径的方法,所述方法应用于第一报文处理装置,所述方法包括:获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表;所述第一聚合流表包括第一表项信息;所述第一精确匹配流表包括第二表项信息;根据所述待处理报文的报文字段和所述第一表项信息确定第一信息;根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息;根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
本实现方式中,首先获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表,然后根据待处理报文的报文字段和第一聚合流表的表项信息确定第一信息,之后,根据待处理报文的报文字段、第一信息和第一精确匹配流表的表项信息确定第二信息,最后,根据第二信息和第一等价路径表确定待处理报文的第一发送路径。由于在确定待处理报文的第一发送路径的过程中,通过将待处理报文的报文字段与第一精确匹配流表的表项信息的匹配,可以选择将待处理报文对应的当前信息指示的发送路径作为第一发送路径,或者在当前信息指示的发送路径的流量负载较大时,可以将较为空闲的发送路径作为第一发送路径,从而使得第一报文处理装置对应的多条发送路径中的流量负载较为均匀,避免 了某些发送路径负载流量较大,发生丢包或增大传输时延的问题,也避免了某些发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第一方面,在第一方面第一种可能的实现方式中,所述根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息,包括:当所述第二表项信息包括与所述报文字段匹配的第一秘钥时,根据所述第一秘钥对应的表项内容确定是否使用第三信息;所述第三信息为所述第一秘钥对应的表项内容包括的新信息;当使用所述第三信息时,获取第一时延差;所述第一时延差为所述第一秘钥对应的表项内容包括的新旧路径时延差;获取第二时延差;所述第二时延差为所述待处理报文到达所述第一报文处理装置的时间与其所在流中前一条报文到达所述第一报文处理装置的时间的间隔;当所述第二时延差大于所述第一时延差时,确定所述第三信息为所述第二信息。
本实现方式中,在待处理报文的报文字段与第一精确匹配流表的秘钥匹配时,可以通过与该报文字段匹配的秘钥对应的表项内容,确定是否使用新信息,即确定是否可以更换发送路径,在确定可以使用新信息的情况下,进一步确定是否会影响待处理报文所在流中报文的发送顺序,如果不影响其所在流中报文的发送顺序,则可以根据新信息确定发送路径,从而使用负载较小的发送路径发送待处理报文,减小报文的传输时延。
结合第一方面,在第一方面第二种可能的实现方式中,所述方法还包括:当不使用所述第三信息时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
本实现方式中,在待处理报文的报文字段与第一精确匹配流表的秘钥匹配时,可以通过与该报文字段匹配的秘钥对应的表项内容,确定是否使用新信息,即确定是否需要更换发送路径,在确定不需要使用新信息的情况下,根据当前信息确定发送路径,避免了当前信息对应的发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第一方面,在第一方面第三种可能的实现方式中,所述方法还包括:当所述第二时延差小于等于所述第一时延差时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
本实现方式中,可以通过比较待处理报文所在流中报文的传输时延与新旧路径时延差的关系,确定更换待处理报文的发送路径是否会造成其所在流中报文发送顺序的混乱,当确定会造成其所在流中报文发送顺序的混乱时,使用当前信息确定发送路径,从而避免了更换路径造成其所在流中报文发送顺序的混乱,保证了更换发送路径的准确度。
结合第一方面,在第一方面第四种可能的实现方式中,所述根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息,包括:当所述第二表项信息不包括与所述报文字段匹配的第一秘钥时,确定所述第一信息为所述第二信息。
本实现方式中,可以通过待处理报文的报文字段与第一精确匹配流表的秘钥的匹配,确定待处理报文所在的流是否为大象流,当第一精确匹配流表不包括与待处理报文的报文字段相匹配的秘钥时,说明待处理报文所在的流非大象流,可以根据当前信息确定发送路径,可以避免当前信息对应的发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第一方面,在第一方面第五种可能的实现方式中,所述根据所述待处理报文的报文字段和所述第一表项信息确定第一信息,包括:确定所述第一表项信息包含的表项的第一数量;对所述待处理报文的报文字段进行哈希计算,生成第一计算结果;根据所述第一 计算结果和所述第一数量生成第一索引;根据所述第一索引和所述第一表项信息确定所述第一信息。
本实现方式中,首先确定第一表项信息包含的表项的第一数量;然后对待处理报文的报文字段进行哈希计算,生成第一计算结果;并且根据所述第一计算结果和所述第一数量生成第一索引;最后,根据所述第一索引和所述第一表项信息确定所述第一信息。第一信息的确定过程较为简单。
结合第一方面,在第一方面第六种可能的实现方式中,所述根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径,包括:确定所述第一等价路径表对应的路径索引的第二数量;对所述第二信息进行哈希计算,生成第二计算结果;根据所述第二计算结果和所述第二数量生成第二索引;确定所述待处理报文的第一发送路径;所述第一发送路径是指路径索引为所述第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
本实现方式中,首先确定第一等价路径表对应的路径索引的第二数量;然后对第二信息进行哈希计算,生成第二计算结果;并且根据所述第二计算结果和所述第二数量生成第二索引;最后根据所述第二索引匹配所述第一等价路径表,得到第一发送路径的路径信息,第一发送路径的确定过程更加简单,适用性更好。
结合第一方面,在第一方面第七种可能的实现方式中,所述方法还包括:在所述待处理报文中添加一个报文头,该报文头包括所述第二信息和所述第一发送路径的信息。
本实现方式中,在发送待处理报文之前,在待处理报文中添加一个包括第二信息和第一发送路径的信息的报文头,使得后续报文处理装置可以得到该报文的报文信息和发送路径的信息,可以更加简单快速的对报文进行处理。
结合第一方面,在第一方面第八种可能的实现方式中,所述方法还包括:将所述待处理报文和所述第一信息上报给CPU。
本实现方式中,在第一精确匹配流表的第二表项信息不包括与待处理报文的报文字段相匹配的秘钥时,可以将待处理报文以及第一信息上报给CPU,使得CPU后续可以根据接收到的上报的报文及报文对应的第一信息,更新第一精确匹配流表,使得第一精确匹配流表更加符合应用场景的需求,适用性更好。
第二方面,本申请提供了一种确定报文发送路径的装置,该装置包括:获取模块和处理模块;所述获取模块,用于获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表;所述第一聚合流表包括第一表项信息;所述第一精确匹配流表包括第二表项信息;所述处理模块,用于根据所述待处理报文的报文字段和所述第一表项信息确定第一信息;根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息;根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
本实现方式的装置,可以获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表,然后根据待处理报文的报文字段和第一聚合流表的表项信息确定第一信息,之后,根据待处理报文的报文字段、第一信息和第一精确匹配流表的表项信息确定第二信息,最后,根据第二信息和第一等价路径表确定待处理报文的第一发送路径。该装置由于在确定待处理报文的第一发送路径的过程中,通过将待处理报文的报文字段与第一精确匹配流表的表项信息的匹配,可以选择将待处理报文对应的当前信息指示的发送路径作为第 一发送路径,或者在当前信息指示的发送路径的流量负载较大时,可以将较为空闲的发送路径作为第一发送路径,从而使得第一报文处理装置对应的多条发送路径中的流量负载较为均匀,避免了某些发送路径负载流量较大,发生丢包或增大传输时延的问题,也避免了某些发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第二方面,在第二方面第一种可能的实现方式中,所述处理模块具体用于:当所述第二表项信息包括与所述报文字段匹配的第一秘钥时,根据所述第一秘钥对应的表项内容确定是否使用第三信息;所述第三信息为所述第一秘钥对应的表项内容包括的新信息;当使用所述第三信息时,获取第一时延差;所述第一时延差为所述第一秘钥对应的表项内容包括的新旧路径时延差;获取第二时延差;所述第二时延差为所述待处理报文到达所述装置的时间与其所在流中前一条报文到达所述装置的时间的间隔;当所述第二时延差大于所述第一时延差时,确定所述第三信息为所述第二信息。
本实现方式的装置,在待处理报文的报文字段与第一精确匹配流表的秘钥匹配时,可以通过与该报文字段匹配的秘钥对应的表项内容,确定是否使用新信息,即确定是否可以更换发送路径,在确定可以使用新信息的情况下,进一步确定是否会影响待处理报文所在流中报文的发送顺序,如果不影响其所在流中报文的发送顺序,则可以根据新信息确定发送路径,从而使用负载较小的发送路径发送待处理报文,减小报文的传输时延。
结合第二方面,在第二方面第二种可能的实现方式中,所述处理模块还用于:当不使用所述第三信息时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
本实现方式的装置,在待处理报文的报文字段与第一精确匹配流表的秘钥匹配时,可以通过与该报文字段匹配的秘钥对应的表项内容,确定是否使用新信息,即确定是否需要更换发送路径,在确定不需要使用新信息的情况下,根据当前信息确定发送路径,避免了当前信息对应的发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第二方面,在第二方面第三种可能的实现方式中,所述处理模块还用于:当所述第二时延差小于等于所述第一时延差时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
本实现方式的装置,可以通过比较待处理报文所在流中报文的传输时延与新旧路径时延差的关系,确定更换待处理报文的发送路径是否会造成其所在流中报文发送顺序的混乱,当确定会造成其所在流中报文发送顺序的混乱时,使用当前信息确定发送路径,从而避免了更换路径造成其所在流中报文发送顺序的混乱,保证了更换发送路径的准确度。
结合第二方面,在第二方面第四种可能的实现方式中,所述处理模块具体用于:当所述第二表项信息不包括与所述报文字段匹配的第一秘钥时,确定所述第一信息为所述第二信息。
本实现方式的装置,可以通过待处理报文的报文字段与第一精确匹配流表的秘钥的匹配,确定待处理报文所在的流是否为大象流,当第一精确匹配流表不包括与待处理报文的报文字段相匹配的秘钥时,说明待处理报文所在的流非大象流,可以根据当前信息确定发送路径,可以避免当前信息对应的发送路径流量负载较小,发生网络带宽利用率较低的问题。
结合第二方面,在第二方面第五种可能的实现方式中,所述处理模块具体用于:确定 所述第一表项信息包含的表项的第一数量;对所述待处理报文的报文字段进行哈希计算,生成第一计算结果;根据所述第一计算结果和所述第一数量生成第一索引;根据所述第一索引和所述第一表项信息确定所述第一信息。
本实现方式的装置,可以确定第一表项信息包含的表项的第一数量;然后对待处理报文的报文字段进行哈希计算,生成第一计算结果;并且根据所述第一计算结果和所述第一数量生成第一索引;最后,根据所述第一索引和所述第一表项信息确定所述第一信息,第一信息的确定过程较为简单。
结合第二方面,在第二方面第六种可能的实现方式中,所述处理模块具体用于:确定所述第一等价路径表对应的路径索引的第二数量;对所述第二信息进行哈希计算,生成第二计算结果;根据所述第二计算结果和所述第二数量生成第二索引;确定所述待处理报文的第一发送路径;所述第一发送路径是指路径索引为所述第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
本实现方式的装置,可以确定第一等价路径表对应的路径索引的第二数量;然后对第二信息进行哈希计算,生成第二计算结果;并且根据所述第二计算结果和所述第二数量生成第二索引;最后根据所述第二索引匹配所述第一等价路径表,得到第一发送路径的路径信息,第一发送路径的确定过程更加简单,适用性更好。
结合第二方面,在第二方面第七种可能的实现方式中,所述处理模块还用于:在所述待处理报文中添加一个报文头,该报文头包括所述第二信息和所述第一发送路径的信息。
本实现方式的装置,在发送待处理报文之前,在待处理报文中添加一个包括第二信息和第一发送路径的信息的报文头,使得后续报文处理装置可以得到该报文的报文信息和发送路径的信息,可以更加简单快速的对报文进行处理。
结合第二方面,在第二方面第八种可能的实现方式中,所述处理模块还用于:将所述待处理报文和所述第一信息上报给CPU。
本实现方式的装置,在第一精确匹配流表的第二表项信息不包括与待处理报文的报文字段相匹配的秘钥时,可以将待处理报文以及第一信息上报给CPU,使得CPU后续可以根据接收到的上报的报文及报文对应的第一信息,更新第一精确匹配流表,使得第一精确匹配流表更加符合应用场景的需求,适用性更好。
第三方面,本申请实施例提供一种通信装置,所述通信装置包括处理器,当所述处理器执行存储器中的计算机程序或指令时,如第一方面所述的方法被执行。
第四方面,本申请实施例提供一种通信装置,所述通信装置包括处理器和存储器,所述存储器用于存储计算机程序或指令;所述处理器用于执行所述存储器所存储的计算机程序或指令,以使所述通信装置执行如第一方面中所示的相应的方法。
第五方面,本申请实施例提供一种通信装置,所述通信装置包括处理器、存储器和收发器;所述收发器,用于接收信号或者发送信号;所述存储器,用于存储计算机程序或指令;所述处理器,用于从所述存储器调用所述计算机程序或指令执行如第一方面所述的方法。
第六方面,本申请实施例提供一种通信装置,所述通信装置包括处理器和接口电路;所述接口电路,用于接收计算机程序或指令并传输至所述处理器;所述处理器运行所述计算机程序或指令以执行如第一方面所示的相应的方法。
第七方面,本申请实施例提供一种计算机存储介质,所述计算机存储介质用于存储计算机程序或指令,当所述计算机程序或指令被执行时,使得第一方面所述的方法被实现。
第八方面,本申请实施例提供一种包括计算机程序或指令的计算机程序产品,当所述计算机程序或指令被执行时,使得第一方面所述的方法被实现。
为解决报文传输过程中由于发送路径选择不当,导致拥塞丢包、传输时延大以及网络带宽利用率低的问题,本申请提供了一种确定报文发送路径的方法及装置。该方法中,首先获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表,然后根据待处理报文的报文字段和第一聚合流表的表项信息确定第一信息,之后,根据待处理报文的报文字段、第一信息和第一精确匹配流表的表项信息确定第二信息,最后,根据第二信息和第一等价路径表确定待处理报文的第一发送路径。由于在确定待处理报文的第一发送路径的过程中,通过将待处理报文的报文字段与第一精确匹配流表的表项信息的匹配,可以选择将待处理报文对应的当前信息指示的发送路径作为第一发送路径,或者在当前信息指示的发送路径的流量负载较大时,可以将较为空闲的发送路径作为第一发送路径,从而使得第一报文处理装置对应的多条发送路径中的流量负载较为均匀,避免了某些发送路径负载流量较大,发生丢包或增大传输时延的问题,也避免了某些发送路径流量负载较小,发生网络带宽利用率较低的问题。
附图说明
图1为本申请提供的一种应用场景示意图;
图2为本申请提供的通信系统的一种实施方式的架构示意图;
图3为本申请提供的路由器的一种实施方式的结构示意图;
图4为本申请提供的确定报文发送路径的方法的一种实施方式的流程示意图;
图5为本申请提供的获取发送路径质量信息的方法的一种实施方式的流程示意图;
图6为本申请提供的一种测量报文的格式示意图;
图7为本申请提供的第二精确匹配流表的更新方法的一种实施方式的流程示意图;
图8为本申请提供的确定报文发送路径的装置的一种实施方式的结构框图;
图9为本申请提供的获取发送路径质量信息的系统的一种实施方式的结构框图;
图10为本申请提供的芯片的一种实施方式的结构框图。
具体实施方式
下面结合附图,对本申请的技术方案进行描述。
在本申请的描述中,除非另有说明,“/”表示“或”的意思,例如,A/B可以表示A或B。本文中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。此外,“至少一个”是指一个或多个,“多个”是指两个或两个以上。“第一”、“第二”等字样并不对数量和执行次序进行限定,并且“第一”、“第二”等字样也并不限定一定不同。
需要说明的是,本申请中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其他实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。
为了便于理解本申请的技术方案,下面先对本申请提供的技术方案的应用场景进行示例性说明。
在报文的传输过程中,发送端报文传输设备接收到待处理报文后,在向待处理报文对应的目的端报文传输设备发送待处理报文时,如果存在多条发送路径,发送端报文传输设备需要选择一条发送路径发送待处理报文。
例如,参见图1,在图1所示的应用场景中,路由器A和路由器B之间存在三条发送路径,分别为路径1、路径2和路径3。路由器A接收到一个发送至路由器B的待处理报文时,将待处理报文发送给路由器B之前,需要在路径1、路径2和路径3中选择一条发送路径,然后通过该发送路径,将待处理报文发送至路由器B。
目前,路由器A接收到待处理报文后,通常会根据待处理报文的报文信息获取待处理报文的等价路径表,该等价路径表中包含路径1、路径2和路径3的路径信息,路由器A可以在该等价路径表的3个路径信息中选取一个路径信息,然后通过该路径信息指示的发送路径,将待处理报文发送至路由器B。采用此种方式,容易将大量报文集中在同一条发送路径中发送,造成某些发送路径流量负载较大,发生拥塞丢包或增大传输时延的问题,而某些发送路径流量负载较小,导致网络带宽利用率较低。
为了解决上述技术问题,本申请提供了一种确定报文发送路径的方法及装置。
本申请提供的技术方案可以应用于各种通信系统,示例性的,本申请提供的技术方案所适用的通信系统可以参见图2,图2为本申请提供的通信系统的一种实施方式的架构示意图,如图2所示,该通信系统可以包括第一报文传输设备201和第二报文传输设备202,第一报文传输设备201和第二报文传输设备202之间具有网络隧道203,第一报文传输设备201为网络隧道203的源节点,第二报文传输设备202为网络隧道203的目的节点,网络隧道203可以包括多条发送路径,例如图2示出的路径2031、2032、2033、2034和2035。
其中,网络隧道203可以是段路由V6(segmet routing v6,SRV6)隧道或者虚拟扩展局域网(virtual extensible local area network,VXLAN)隧道等。
第一报文传输设备201和第二报文传输设备202都可以为路由器。路由器的结构可以参见图3,图3为本申请提供的路由器的一种实施方式的结构示意图,如图3所示,路由器可以包括:输入接口模块301、网络处理器(network processor,NP)302、中央处理器(central processing unit,CPU)303、存储模块304和输出接口模块305。其中,输入接口模块301可以用于接收报文,例如待处理报文,输出接口模块305可以用于发送报文,例如经过处理后的待处理报文,此外,路由器中每一个部件的具体作用或功能还可以参考后续实施例的内容,此处不再详述。
本领域技术人员可以理解,图2和图3示出的通信系统和路由器的结构并不构成对本申请的通信系统和路由器的结构的限定,本申请提供的通信系统和路由器可以包括比图示更多或更少的部件,或者组合某些部件,或者采用不同的部件布置。本申请对此并不进行限定。
此外,本申请实施例描述的通信系统的网络架构以及应用场景是为了更加清楚的说明本申请实施例的技术方案,并不构成对于本申请实施例提供的技术方案的限定,本领域普通技术人员可知,随着网络架构的演变和新业务场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。
下面对本申请提供的确定报文发送路径的方法的实施例进行说明。
参见图4,图4为本申请提供的确定报文发送路径的方法的一种实施方式的流程示意图。该方法可以应用于第一报文处理装置,第一报文处理装置位于发送端,用于接收待处理报文,并将经过处理后的待处理报文发送至待处理报文对应的目的端。
例如,第一报文处理装置可以为图2所示的第一报文传输设备201,或者可以为第一报文传输设备201中的报文处理装置,当图2所示的第一报文传输设备201为图3所示的路由器时,第一报文处理装置可以为路由器的NP,该方法可以包括以下步骤:
步骤S101、获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表。
其中,待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表都可以由第一报文处理装置连接的CPU管理和下发,例如,第一报文处理装置连接的CPU可以为图2所示第一报文传输设备201的CPU,当图2所示的第一报文传输设备201为图3所示的路由器时,第一报文处理装置连接的CPU可以为路由器的CPU。
第一报文处理装置接收到待处理报文后,可以根据待处理报文的报文字段获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表。
可选的,待处理报文的报文字段可以为待处理报文的目的地址。可选的,待处理报文的报文字段还可以为待处理报文的五元组,即待处理报文的源地址、目的地址、源端口号、目的端口号和报文协议。
例如,第一报文处理装置可以根据待处理报文的五元组,查访问控制列表(access control lists,ACL),获取待处理报文的第一等价路径表。
根据待处理报文的报文字段获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表的具体内容还可以参见后续实施例的内容。
待处理报文的第一等价路径表包括多个路径信息,路径信息的数量与用于传输报文的发送路径的数量相同,一个路径信息用于指示一条发送路径。可选的,第一等价路径表包括的路径信息可以通过路径标识(例如路径ID)指示,也可以通过路径的其它信息(例如路径名称等)指示,本申请对此不进行限定。
第一等价路径表为线性表,通常可以通过路径索引匹配第一等价路径表,从而得到该路径索引对应的路径信息,例如路径ID。其中,一个路径信息可以对应一个路径索引。具体的,在得到路径索引后,将该路径索引作为输入值,输入至第一等价路径表中,可以得到输出值,输出值即为该路径索引对应的路径信息。
例如,可参见表1,第一等价路径表包括路径ID,每一个路径ID对应一个路径索引,将具体的路径索引作为输入值,输入至表1后,可以得到具体的路径ID。例如,将路径索引0输入至表1后,可以得到路径1,将路径索引1输入至表1后,可以得到路径2等。
路径索引 路径ID
0 路径1
1 路径2
2 路径3
表1
待处理报文的第一聚合流表包括第一表项信息,第一表项信息可以包括多个用于唯一 识别流的流指示信息,本申请中,将第一聚合流表包含的流指示信息记为第一流指示信息,第一流指示信息的数量可以根据实际应用场景的需求进行设置,例如,可以将第一流指示信息的数量设置为64。
可选的,第一流指示信息可以为流标签(flowlabel)或者源端口号,当第一报文处理装置为SRV6隧道的节点时,第一流指示信息可以为流标签,当第一报文处理装置为VXLAN隧道的节点时,第一流指示信息可以为源端口号。本领域技术人员可以理解,随着网络架构的演变和新业务场景的出现,第一流指示信息也可以为其它可以识别流的信息,本申请对此不进行限定。
第一聚合流表同样为线性表,可以通过信息索引匹配第一聚合流表,从而得到该信息索引对应的第一流指示信息。其中,一个第一流指示信息可以对应一个或多个信息索引,信息索引的数量也可以根据实际应用场景的需求进行设置,例如,可以将信息索引的数量设置为64k,当信息索引的数量为64k时,第一聚合流表共有64k个表项。具体的,在得到信息索引后,将该信息索引作为输入值,输入至第一聚合流表中,可以得到输出值,输出值即为该信息索引对应的第一流指示信息。
例如,可参见表2,第一聚合流表包括64个流标签,每一个流标签对应多个信息索引,共有64k个信息索引,所以第一聚合流表共有64k个表项。将具体的信息索引作为输入值,输入至表2中,可以得到相应的流标签。例如,将信息索引0输入至表2中,可以得到flowlabel 1,将信息索引1输入至表2中,可以得到flowlabel 2,将信息索引64k-64输入至表2中,可以得到flowlabel 1,将信息索引64k-63输入至表2中,可以得到flowlabel 2等。
Figure PCTCN2021100032-appb-000001
表2
待处理报文的第一精确匹配流表又可以称为第一大象流表,第一精确匹配流表包括第 二表项信息,第二表项信息可以包括多个秘钥和每个秘钥对应的表项内容,其中,每个秘钥对应的表项内容可以包括当前流指示信息,是否使用新的流指示信息,新旧流指示信息对应路径的时延差,新的流指示信息,以及流计数,即当前流中的报文数量等内容。
其中,当前流指示信息又可以简称为当前信息,例如当前信息可以为当前流标签。新的流指示信息又可以简称为新信息,例如新信息可以为新流标签。新旧流指示信息对应路径的时延差又可以简称为新旧路径时延差,例如新旧路径时延差可以为新旧流标签对应路径的时延差。是否使用新的流指示信息又可以简称为是否使用新信息,例如是否使用新信息可以为是否使用新流标签。
第一精确匹配流表的表项数量可以根据实际应用场景的需求设置,不过由于第一精确匹配流表通常占用的内存较大,所以第一精确匹配流表的规格设置较小,例如第一精确匹配流表的表项数量可以设置为256个。
例如,可以参见表3,第一精确匹配流表包括256个秘钥,每一个秘钥对应一个表项内容,每一个表项内容包括当前流标签,是否使用新流标签,新旧流标签对应路径的时延差,新流标签和流计数。
Figure PCTCN2021100032-appb-000002
表3
第一精确匹配流表中的当前流指示信息和新的流指示信息与第一聚合流表中的第一流指示信息的内容一致,即,第一聚合流表中的第一流指示信息包括第一精确匹配流表中的当前流指示信息,也包括第一精确匹配流表中的新的流指示信息。例如,表2所示的第一聚合流表中的64个流标签包括表3所示的第一精确匹配流表的当前流标签和新流标签。
此外,待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表的具体作用或功能可以参见后续实施例的内容,此处不再详述。
步骤S102、根据所述待处理报文的报文字段和所述第一聚合流表的第一表项信息确定第一信息。
获取到待处理报文的第一聚合流表后,可以根据待处理报文的报文字段和第一聚合流表的第一表项信息确定第一信息,第一信息是指第一聚合流表的第一表项信息包含的与待处理报文的报文字段对应的第一流指示信息。
其中,待处理报文的报文字段用于识别待处理报文所在的流,例如,可以选取待处理报文的五元组作为待处理报文的报文字段,也可以选取待处理报文的五元组中的3个或4个参数作为待处理报文的报文字段。
可选的,根据待处理报文的报文字段和第一表项信息确定第一信息,可以按照下述方式实现:确定第一表项信息包含的表项的第一数量;对待处理报文的报文字段进行哈希计算,生成第一计算结果;根据第一计算结果和第一数量生成第一索引;根据 第一索引和第一表项信息确定第一信息。
其中,对待处理报文的报文字段进行哈希计算,生成第一计算结果,可以按照下述方式实现:根据待处理报文的报文字段组成第一比特数据,将第一比特数据作为哈希计算模型的输入值进行哈希计算,得到的输出值即为第一计算结果。
根据第一计算结果和第一数量生成第一索引,可以按照下述方式实现:对第一计算结果和第一数量进行取余计算,将得到的余数确定为第一索引。
根据第一索引和第一表项信息确定第一信息,可以按照下述方式实现:根据第一索引匹配第一聚合流表的第一表项信息,得到第一信息,即,将第一索引作为输入值,输入至第一聚合流表,得到输出值,该输出值即为第一信息,其中,第一信息为第一表项信息中与第一索引对应的第一流指示信息。
下面以一个具体的例子对步骤S102进行说明。例如,待处理报文的第一聚合流表如表2所示,该第一聚合流表共有64k个表项,即第一数量为64k,根据待处理报文的五元组,即源地址、目的地址、源端口号、目的端口号和报文协议,组成128比特(bit)的第一比特数据,如果待处理报文的五元组组成的比特数据不足128比特,可以将五元组之外的空余位置记为0,然后,对该128比特的第一比特数据进行哈希计算,得到第一计算结果,该第一计算结果为32比特的比特数据,之后,使用32比特的比特数据除以64k,将得到的余数作为第一索引,使用该第一索引作为第一聚合流表的信息索引输入至第一聚合流表中,输出值即为第一信息,即输出值即为待处理报文对应的第一流指示信息。例如,得到的余数为2,则第一信息为flowlabel 3,即待处理报文对应的第一流指示信息为flowlabel 3。
步骤S103、根据所述报文字段、所述第一精确匹配流表的第二表项信息和所述第一信息确定第二信息。
得到待处理报文的第一精确匹配流表和第一信息后,首先确定第一精确匹配流表的第二表项信息中是否包括与待处理报文的报文字段(例如待处理报文的五元组)相匹配的第一秘钥,第一秘钥是指与待处理报文的报文字段相同的秘钥;当第二表项信息中不包括第一秘钥时,将第一信息确定为第二信息,第二信息用于确定第一报文处理装置实际发送待处理报文的发送路径,即用于确定待处理报文的第一发送路径。
例如,待处理报文的第一精确匹配流表如表3所示,表3中秘钥1至秘钥256中任意一个秘钥都与待处理报文的五元组不同,则认为表3所示的第一精确匹配流表的第二表项信息中不包含第一秘钥,则将第一信息确定为第二信息。
当第二表项信息中包括第一秘钥时,根据第二表项信息中第一秘钥对应的表项内容确定是否使用第三信息,第三信息是指第二表项信息中第一秘钥对应的表项内容包含的新信息,即,查第一精确匹配流表中第一秘钥对应的表项内容,确认其中“是否使用新信息”对应的是否为“是”,如果其中“是否使用新信息”对应的为“否”,表示不使用第三信息,当不使用第三信息时,获取第四信息,第四信息是指第二表项信息中第一秘钥对应的表项内容包含的当前信息,将第四信息确定为第二信息。
例如,待处理报文的第一精确匹配流表如表3所示,且待处理报文的五元组与key2相同,可知,第二表项信息包含第一秘钥,且第一秘钥为key2,然后查key2对应的表项内容可知,“是否使用新流标签”为“否”,表示不使用第三信息,即不使用新流标签,然后, 查key2对应的表项内容可知,key2对应的表项内容包含的当前流标签为flowlabel 26,即第四信息为flowlabel 26,则第二信息为flowlabel 26。
当查第一秘钥对应的表项内容,确认其中“是否使用新信息”对应的为“是”时,表示使用第三信息。当使用第三信息时,首先获取第一时延差,第一时延差是指第一秘钥对应的表项内容包含的新旧路径时延差;并且,获取第二时延差,第二时延差是指待处理报文到达第一报文处理装置的时间,与待处理报文所在流中待处理报文的前一条报文到达第一报文处理装置的时间,两者之间的时间间隔;当第二时延差大于第一时延差时,表示将待处理报文的发送路径从当前信息指示的发送路径切换到新信息指示的发送路径,不会引起待处理报文所在流中报文的发送顺序的混乱,可以切换待处理报文的发送路径,则可以将第三信息确定为第二信息。
例如,待处理报文的第一精确匹配流表如表3所示,且待处理报文的五元组与key1相同,可知,第二表项信息包含第一秘钥,且第一秘钥为key1,然后查key1对应的表项内容可知,“是否使用新流标签”为“是”,表示使用第三信息,且第三信息为flowlabel 64,再次查key1对应的表项内容可知,“新旧流标签对应路径的时延差”为50微秒,即第一时延差为50微秒,通过记录每一个报文到达第一报文处理装置的时间可知,待处理报文到达第一报文处理装置的时间,与待处理报文所在流中待处理报文的前一条报文到达第一报文处理装置的时间,两者之间的时间间隔为60微秒,即第二时延差为60微秒,可知,第二时延差大于第一时延差,则可以将第三信息flowlabel 64确定为第二信息,即第二信息为flowlabel 64。
当第二时延差小于等于第一时延差时,表示将待处理报文的发送路径从当前信息指示的发送路径切换到新信息指示的发送路径的话,会引起待处理报文所在流中报文的发送顺序的混乱,不可以切换待处理报文的发送路径,则获取第四信息,将第四信息确定为第二信息。
例如,待处理报文的第一精确匹配流表如表3所示,且待处理报文的五元组与key256相同,可知,第二表项信息包含第一秘钥,且第一秘钥为key256,然后查key256对应的表项内容可知,“是否使用新流标签”为“是”,表示使用第三信息,且第三信息为flowlabel 63,再次查key256对应的表项内容可知,“新旧流标签对应路径的时延差”为30微秒,即第一时延差为30微秒,通过记录每一个报文到达第一报文处理装置的时间可知,待处理报文到达第一报文处理装置的时间,与待处理报文所在流中待处理报文的前一条报文到达第一报文处理装置的时间,两者之间的时间间隔为20微秒,即第二时延差为20微秒,可知,第二时延差小于第一时延差,则获取第四信息,第四信息为flowlabel 58,将第四信息确定为第二信息,则第二信息为flowlabel 58。
可选的,当待处理报文的第一精确匹配流表的第二表项信息不包括第一秘钥时,可以将待处理报文和第一信息作为采样数据上报给第一报文处理装置连接的CPU。
可选的,当待处理报文的第一精确匹配流表的第二表项信息不包括第一秘钥时,还可以先确定待处理报文的报文长度是否超过预设字节长度(例如1000字节),如果待处理报文的报文长度超过预设字节长度,可以将待处理报文和第一信息作为采样数据上报给第一报文处理装置连接的CPU。
可选的,当待处理报文的第一精确匹配流表的第二表项信息不包括第一秘钥时,还可 以先确定待处理报文的报文长度是否超过预设字节长度(例如1000字节),如果待处理报文的报文长度超过预设字节长度,可以将待处理报文作为采样数据进行存储,然后按照预设采样比例(例如1000:1)将采样数据上报给第一报文处理装置连接的CPU。
示例性的,上述第一报文处理装置可以为图3所示的NP 302,第一报文处理装置连接的CPU可以为图3所示的CPU303。第一报文处理装置可以将待处理报文作为采样数据存储至第一报文处理装置连接的存储装置,例如存储装置可以为图3所示的存储模块304。
在本申请一些可选的实施方式中,当确定待处理报文的第一精确匹配流表的第二表项信息包含第一秘钥时,还会在第一秘钥对应的表项内容包含的“流计数”对应的当前数字上加1,更新“流计数”对应的当前数字,以便对待处理报文所在的流包含的报文进行计数,后续可以根据每一条流包含的报文的数量确定该条流是否为大象流。
步骤S104、根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
可选的,根据第二信息和第一等价路径表,确定待处理报文的第一发送路径,可以按照下述方式实现:确定第一等价路径表对应的路径索引的第二数量;对第二信息进行哈希计算,生成第二计算结果;根据第二计算结果和第二数量生成第二索引;确定待处理报文的第一发送路径;所述第一发送路径是指路径索引为第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
其中,对第二信息进行哈希计算,生成第二计算结果,可以按照下述方式实现:根据第二信息组成第二比特数据;将第二比特数据作为哈希计算模型的输入值,进行哈希计算,得到的输出值即为第二计算结果。
可选的,可以根据第二信息和0组成128比特的第二比特数据。
可选的,还可以根据第二信息,第一报文处理装置发送待处理报文时发送端的源地址和目的端的目的地址,以及0,组成第二比特数据。例如,当第一报文处理装置为SRV6隧道的源节点时,源地址和目的地址分别为SRV6隧道的源地址和目的地址,则可以根据第二信息,SRV6隧道的源地址和目的地址,以及0,组成第二比特数据。
可选的,还可以根据第二信息,第一报文处理装置发送待处理报文时发送端的源端口号和源地址,以及目的端的目的端口号和目的地址,组成第二比特数据。例如,当第一报文处理装置为VXLAN隧道的源节点时,源端口号、源地址、目的端口号和目的地址分别为VXLAN隧道的源端口号、源地址、目的端口号和目的地址,则可以根据第二信息,VXLAN隧道的源端口号、源地址、目的端口号和目的地址,以及0,组成第二比特数据。
根据第二计算结果和第二数量生成第二索引,可以按照下述方式实现:对第二计算结果和第二数量进行取余计算,将得到的余数确定为第二索引。
确定待处理报文的第一发送路径,可以按照下述方式实现:根据第二索引匹配待处理报文的第一等价路径表,得到第一发送路径的路径信息,即,将第二索引作为路径索引输入至第一等价路径表,得到的输出值即为第一发送路径的路径信息,也就是说,待处理报文的第一发送路径是指路径索引为第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
在本申请一些可选的实施方式中,确定待处理报文的第一发送路径后,在使用第 一发送路径发送待处理报文之前,还可以在待处理报文中添加一个报文头,该报文头包括第二信息和第一发送路径的信息。
可选的,第一发送路径的信息可以为第一发送路径的源地址和目的地址,例如,当第一报文处理装置为SRV6隧道的源节点时,第一发送路径的信息为SRV6隧道的源地址和目的地址。当第一报文处理装置为VXLAN隧道的源节点时,第一发送路径的信息可以为VXLAN隧道的源地址和目的地址。
本申请实施例提供的确定报文发送路径的方法中,首先获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表,然后根据待处理报文的报文字段和第一聚合流表的表项信息确定第一信息,之后,根据待处理报文的报文字段、第一信息和第一精确匹配流表的表项信息确定第二信息,最后,根据第二信息和第一等价路径表确定待处理报文的第一发送路径。由于在确定待处理报文的第一发送路径的过程中,通过将待处理报文的报文字段与第一精确匹配流表的表项信息的匹配,可以选择将待处理报文对应的当前信息指示的发送路径作为第一发送路径,或者在当前信息指示的发送路径的流量负载较大时,可以将较为空闲的发送路径作为第一发送路径,从而使得第一报文处理装置对应的多条发送路径中的流量负载较为均匀,避免了某些发送路径负载流量较大,发生丢包或增大传输时延的问题,也避免了某些发送路径流量负载较小,发生网络带宽利用率较低的问题。
在报文的传输过程中,发送端报文传输设备中可以设置一个或多个第二等价路径表,一个或多个第二聚合流表,以及一个或多个第二精确匹配流表。第二等价路径表、第二聚合流表和第二精确匹配流表都与报文的报文字段对应。基于此,在上述图4所示的实施例中,位于发送端的第一报文处理装置接收到待处理报文后,可以获取待处理报文的报文字段对应的第二等价路径表,将该第二等价路径表确定为该待处理报文的第一等价路径表。同理,第一报文处理装置可以获取待处理报文的报文字段对应的第二聚合流表和第二精确匹配流表,将获得的第二聚合流表和第二精确匹配流表分别确定为第一聚合流表和第一精确匹配流表。
第二等价路径表、第二聚合流表和第二精确匹配流表的内容可以参考前述实施例中第一等价路径表、第一聚合流表和第一精确匹配流表的内容,此处不再赘述。
此外,一个发送端报文传输设备可以对应一个或多个目的端报文传输设备,同一组发送端报文传输设备和目的端报文传输设备之间可以包括一个或多个报文传输通道(例如报文传输通道可以为网络隧道),一个报文传输通道可以包括一条或多条用于传输报文的发送路径。
其中,一个报文传输通道对应一个第二等价路径表、一个第二聚合流表和一个第二精确匹配流表,发送端报文传输设备可以根据该报文传输通道中发送路径的变化,对该报文传输通道对应的第二等价路径表、第二聚合流表和第二精确匹配流表进行管理。
下面,以图2和图3所示的通信系统为例,对发送端报文传输设备对一个报文传输通道对应的第二等价路径表、第二聚合流表和第二精确匹配流表进行管理的内容进行说明。对任意一条报文传输通道对应的第二等价路径表、第二聚合流表和第二精确匹配流表进行管理的具体实现方式,都可以参考下述实施例的内容。
下述实施例中,图2所示的第一报文传输设备201为发送端报文传输设备,图2所示的第二报文传输设备202为目的端报文传输设备,第一报文传输设备201与第二报文传输设备202之间具有一条报文传输通道,即网络隧道203,并且第一报文传输设备201和第二报文传输设备202均为路由器。
第一报文传输设备201记为第一路由器,第一路由器中的NP记为第一NP,第一路由器中的CPU记为第一CPU。第二报文传输设备202记为第二路由器,第二路由器中的NP记为第二NP。
对应于第一路由器与第二路由器之间的网络隧道203,第一路由器中设置有一个第二等价路径表、一个第二聚合流表和一个第二精确匹配流表。
在网络隧道203包括的发送路径的数量不变时,网络隧道203对应的第二等价路径表不变,相应的,所有通过网络隧道203传输的待处理报文的第一等价路径表相同,均为第二等价路径表。
网络隧道203对应的第二聚合流表在系统启动时,由第一CPU下发至第一NP,在第一NP运行的过程中,网络隧道203对应的第二聚合流表不会发生变化,相应的,所有通过网络隧道203传输的待处理报文的第一聚合流表也相同,均为第二聚合流表。
网络隧道203对应的第二精确匹配流表可以根据网络隧道203包括的发送路径的质量信息进行更新。在对网络隧道203对应的第二精确匹配流表进行更新之前,首先获取网络隧道203包括的每一条发送路径的质量信息。每一条发送路径的质量信息包括丢包率和第三时延差,其中,第三时延差是指该发送路径的传输时延差,即报文从该发送路径的发送端到达目的端经过的时长。
参见图5,图5为本申请提供的获取发送路径质量信息的方法的一种实施方式的流程示意图。该方法可以包括以下步骤:
步骤S201、第一NP生成测量报文。
其中,测量报文可以包括多个,测量报文的数量记为第三数量,第三数量等于网络隧道203对应的第二聚合流表包括的流指示信息的数量,本申请中,将第二聚合流表包括的流指示信息记为第二流指示信息。一个测量报文对应一个第二流指示信息。例如,网络隧道203对应的第二聚合流表包括的第二流指示信息分别为flowlabel 1、flowlabel 2、……、flowlabel 64,则测量报文的数量为64,即第三数量为64,并且,flowlabel 1、flowlabel 2、……、flowlabel 64分别对应一个测量报文。
测量报文的格式如图6所示,测量报文的报文字段中包含介质访问控制(media access control,MAC)、发送时间戳、发送计数和该测量报文对应的第二流指示信息,其中,发送时间戳用于指示第一NP向第二路由器发送该测量报文的时间,发送计数用于指示第一NP通过该第二流指示信息对应的发送路径发送该测量报文时,已经通过该发送路径发送的经过处理后的待处理报文的数量。
可选的,为了可以根据隧道203包含的发送路径的质量变化,及时更新隧道203对应的第二精确匹配流表,第一NP可以按照第一预设时长,周期性的生成测量报文,例如,第一预设时长可以设置为10毫秒,每间隔10毫秒,生成一次测量报文,这样,可以周期性的对网络隧道203对应的第二精确匹配流表进行更新。
步骤S202、第一NP根据所述测量报文对应的第二流指示信息和第二等价路径表, 确定该测量报文的第二发送路径。
第一NP每次生成测量报文后,根据每一个测量报文对应的第二流指示信息和第二等价路径表,确定该测量报文的第二发送路径,第二发送路径为网络隧道203包括的一条发送路径。可以将测量报文的第二发送路径与该测量报文的第二流指示信息进行对应关联。
由于在网络隧道203包括的发送路径的数量不变时,网络隧道203对应的第二等价路径表不变,相应的,所有通过网络隧道203传输的待处理报文的第一等价路径表相同,且都为第二等价路径表。所以,根据每一个测量报文对应的第二流指示信息和第二等价路径表确定该测量报文的第二发送路径的具体实现方式,可以参考图4所示实施例中根据第二信息和第一等价路径表,确定待处理报文的第一发送路径的具体实现方式,此处不再赘述。
步骤S203、第一NP通过所述第二发送路径向第二路由器发送所述测量报文。
第一NP每次生成测量报文,并确定出每一个测量报文的第二发送路径后,通过该测量报文的第二发送路径向第二路由器发送该测量报文。
步骤S204、第二NP根据第二路由器接收到的所述测量报文,确定该测量报文对应的第二流指示信息对应的第一时间、第二时间和第四数量。
第二路由器接收到任意一个测量报文后,第二路由器的第二NP根据该测量报文包含的发送时间戳、发送计数和该测量报文对应的第二流指示信息,确定第一NP发送该测量报文的发送时间,将该发送时间记为该第二流指示信息对应的第一时间,并且确定第一NP发送该测量报文时,已经通过该第二流指示信息对应的第二发送路径发送的经过处理后的待处理报文的数量,将该数量记为该第二流指示信息对应的第四数量,此外,第二NP还会记录第二路由器接收到该测量报文的接收时间,将该接收时间记为该第二流指示信息对应的第二时间。
步骤S205、第二NP根据所述第二流指示信息对应的第一时间、第二时间和第四数量确定该第二流指示信息对应的第二发送路径的丢包率和第三时延差。
结合图4所示实施例的内容可知,第一NP接收到待处理报文,通过网络隧道203向第二路由器发送该待处理报文之前,会在该待处理报文中添加一个报文头,该报文头包括第二信息,所以第二路由器接收到的经过处理后的待处理报文中包括第二信息。基于此,第二NP可以根据第二路由器接收到的经过处理后的待处理报文的第二信息,确定出第二路由器通过每一个第二流指示信息对应的第二发送路径接收到的经过处理后的待处理报文的数量,将该数量记为该第二流指示信息对应的第五数量。
第二NP可以根据每一个第二流指示信息对应的第一时间、第二时间、第四数量和第五数量,确定该第二流指示信息对应的第二发送路径的丢包率和第三时延差。
其中,第二NP确定第二流指示信息对应的第二发送路径的丢包率,可以按照下述方式实现:第二NP根据该第二流指示信息对应的第四数量和第五数量,以及下述关系式:丢包率=(第四数量-第五数量)/第四数量*100%,计算得到该第二流指示信息对应的第二发送路径的丢包率。
第二NP确定第二流指示信息对应的第二发送路径的第三时延差,可以按照下述方式实现:第二NP根据该第二流指示信息对应的第一时间和第二时间,以及下述关 系式:第三时延差=第二时间-第一时间,计算得到该第二流指示信息对应的第二发送路径的第三时延差。
步骤S206、第二NP向第一路由器发送所述第二流指示信息对应的第二发送路径的丢包率和第三时延差。
可选的,第二NP确定出每一个第二流指示信息对应的第二发送路径的丢包率和第三时延差后,可以将该第二流指示信息对应的第二发送路径的丢包率和第三时延差,与该第二流指示信息一起发送给第一路由器。
可选的,第一NP还可以周期性的,将同一周期得到的每一个第二流指示信息,以及该第二流指示信息对应的第二发送路径的丢包率和第三时延差,一起对应发送给第一路由器。
步骤S207、第一CPU根据第一路由器接收到的第二流指示信息对应的第二发送路径的丢包率和第三时延差,获取该第二流指示信息对应的第二发送路径的质量信息。
第一路由器接收到每一个第二流指示信息对应的第二发送路径的丢包率和第三时延差后,第一路由器的第一CPU可以根据该第二流指示信息对应的第二发送路径的丢包率和第三时延差,获取该第二流指示信息对应的第二发送路径的质量信息。
第一CPU可以按照图5所示的方法,获取到网络隧道203对应的第二聚合流表包括的所有第二流指示信息中每一个第二流指示信息对应的第二发送路径的质量信息。在获取到每一个第二流指示信息对应的第二发送路径的质量信息后,第一CPU可以根据获取到的质量信息更新网络隧道203对应的第二精确匹配流表。
当第一NP按照第一预设时长,周期性的生成测量报文时,第一CPU可以周期性的获取到网络隧道203对应的第二聚合流表包括的所有第二流指示信息中每一个第二流指示信息对应的第二发送路径的质量信息。相应的,第一CPU可以周期性的对网络隧道203对应的第二精确匹配流表进行更新。下面以一个周期为例,结合图7,介绍第一CPU对网络隧道203对应的第二精确匹配流表进行更新的内容。
参见图7,图7为本申请提供的第二精确匹配流表的更新方法的一种实施方式的流程示意图。该方法可以包括以下步骤:
步骤S301、获取第二精确匹配流表包括的第二流指示信息对应的第二发送路径的质量信息和第一NP上报的采样数据。
结合图4所示实施例的内容可知,采样数据包括待处理报文和该待处理报文对应的第一信息。为了便于区分,本实施例中,将采样数据包括的待处理报文记为采样报文。
步骤S302、根据所述采样数据和所述质量信息更新所述第二精确匹配流表。
根据采样数据和质量信息更新第二精确匹配流表,可以按照下述方式实现:根据采样数据更新第二精确匹配流表的空闲表项;根据质量信息更新第二精确匹配流表的表项内容。其中,第二精确匹配流表的空闲表项是指第二精确匹配流表中表项信息为空的表项。
根据采样数据更新第二精确匹配流表的空闲表项,可以按照下述方式实现:获取采样数据包括的采样报文的报文字段;确定第二精确匹配流表中是否存在空闲表项;如果第二精确匹配流表中存在空闲表项,将采样报文的报文字段作为第二精确匹配流 表的秘钥添加到空闲表项中,并且将该采样报文的第一信息作为该秘钥对应的表项内容的当前信息添加到该空闲表项中;或者,如果第二精确匹配流表中不存在空闲表项,则删除采样数据。其中,采样报文可以包括多个,可以按照此种实现方式,根据每一个采样报文更新第二精确匹配流表。
根据质量信息更新第二精确匹配流表的表项内容,可以按照下述方式实现:根据质量信息,确定第五信息和第六信息,其中第五信息是指质量好的第二发送路径对应的第二流指示信息,第六信息是指质量差的第二发送路径对应的第二流指示信息,当质量信息包括的丢包率小于等于丢包率阈值和/或第三时延差小于等于时延差阈值时,可以将该质量信息对应的第二发送路径确定为质量好的发送路径,当质量信息包括的丢包率大于丢包率阈值和/或第三时延差大于时延差阈值时,可以将该质量信息对应的第二发送路径确定为质量差的发送路径;将第二精确匹配流表中当前信息为第六信息的表项内容的新信息更新为第五信息,将当前信息为第六信息的表项内容的新旧路径时延差更新为第六信息对应的第三时延差与第五信息对应的第三时延差的差值,将当前信息为第六信息的表项内容的“是否使用新信息”更新为“是”。其中,丢包率阈值和时延差阈值都可以根据实际应用场景设置。
此外,还可以周期性的读取第二精确匹配流表包括的流计数,根据流计数确定该流计数对应的流是否为大象流,如果该流计数对应的流不是大象流,删除该流计数对应的表项。并且,还可以根据流计数确定该流计数对应的流是否在第二预设时长内没有新的报文到达,如果在第二预设时长内没有新的报文到达,删除该流计数对应的表项。其中,如果流计数大于等于报文数量阈值,可以确定该流计数对应的流为大象流。第二预设时长和报文数量阈值都可以根据实际应用场景进行设置。
本文中描述的各个方法实施例可以为独立的方案,也可以根据内在逻辑进行组合,这些方案都落入本申请的保护范围中。
可以理解的是,上述各个方法实施例中,由报文处理装置、NP或CPU实现的方法和操作,也可以由可用于报文处理装置、NP或CPU的部件(例如芯片或者电路)实现。
上述主要从每一个网元之间交互的角度对本申请实施例提供的方案进行了介绍。可以理解的是,每一个网元,例如报文处理装置、NP或CPU等,为了实现上述功能,其包含了执行每一个功能相应的硬件结构或软件模块,或两者结合。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
本申请实施例可以根据上述方法示例对报文处理装置、NP或CPU等进行功能模块的划分,例如,可以对应每一个功能划分每一个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。下面以采用 对应每一个功能划分每一个功能模块为例进行说明。
以上,结合图1至图7详细说明了本申请实施例提供的方法。以下,结合图8至图10详细说明本申请实施例提供的装置。应理解,装置实施例的描述与方法实施例的描述相互对应,因此,未详细描述的内容可以参见上文方法实施例,为了简洁,这里不再赘述。
参见图8,图8为本申请提供的确定报文发送路径的装置的一种实施方式的结构框图。如图8所示,该装置800可以包括:获取模块801和处理模块802。该装置800可以用于执行上文方法实施例中第一报文处理装置所执行的动作。
例如:所述获取模块801,可以用于获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表;所述第一聚合流表包括第一表项信息;所述第一精确匹配流表包括第二表项信息。
所述处理模块802,可以用于根据所述待处理报文的报文字段和所述第一表项信息确定第一信息;根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息;根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
可选的,所述处理模块802具体用于:当所述第二表项信息包括与所述报文字段匹配的第一秘钥时,根据所述第一秘钥对应的表项内容确定是否使用第三信息;所述第三信息为所述第一秘钥对应的表项内容包括的新信息;当使用所述第三信息时,获取第一时延差;所述第一时延差为所述第一秘钥对应的表项内容包括的新旧路径时延差;获取第二时延差;所述第二时延差为所述待处理报文到达所述装置的时间与其所在流中前一条报文到达所述装置的时间的间隔;当所述第二时延差大于所述第一时延差时,确定所述第三信息为所述第二信息。
可选的,所述处理模块802还用于:当不使用所述第三信息时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
可选的,所述处理模块802还用于:当所述第二时延差小于等于所述第一时延差时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;确定所述第四信息为所述第二信息。
可选的,所述处理模块802具体用于:当所述第二表项信息不包括与所述报文字段匹配的第一秘钥时,确定所述第一信息为所述第二信息。
可选的,所述处理模块802具体用于:确定所述第一表项信息包含的表项的第一数量;对所述待处理报文的报文字段进行哈希计算,生成第一计算结果;根据所述第一计算结果和所述第一数量生成第一索引;根据所述第一索引和所述第一表项信息确定所述第一信息。
可选的,所述处理模块802具体用于:确定所述第一等价路径表对应的路径索引的第二数量;对所述第二信息进行哈希计算,生成第二计算结果;根据所述第二计算结果和所述第二数量生成第二索引;确定所述待处理报文的第一发送路径;所述第一发送路径是指路径索引为所述第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
可选的,所述处理模块802还用于:在所述待处理报文中添加一个报文头,该报 文头包括所述第二信息和所述第一发送路径的信息。
可选的,所述处理模块802还用于:将所述待处理报文和所述第一信息上报给CPU。
也就是说,该装置800可实现对应于根据本申请实施例的图4所示方法中第一报文处理装置执行的步骤或者流程,该装置800可以包括用于执行图4所示方法中第一报文处理装置执行的方法的模块。并且,该装置800中的各模块和上述其他操作和/或功能分别为了实现图4所示方法的相应步骤。例如,该装置800中的获取模块801可以用于执行图4所示方法中的步骤S101,处理模块802可以用于执行图4所示方法中的步骤S102至步骤S104。
应理解,各模块执行上述相应步骤的具体过程在上述方法实施例中已经详细说明,为了简洁,在此不再赘述。
参见图9,图9为本申请提供的获取发送路径质量信息的系统的一种实施方式的结构框图。如图9所示,该系统900可以包括:第一报文处理装置901、第二报文处理装置902和处理装置903。其中,第一报文处理装置901和处理装置903位于发送端,第二报文处理装置902位于目的端。该系统900可以用于执行上文图5所示方法实施例中第一NP、第二NP和第一CPU所执行的动作。
例如,第一报文处理装置901可以用于:生成测量报文;根据所述测量报文对应的第二流指示信息和第二等价路径表,确定该测量报文的第二发送路径;通过所述第二发送路径向第二报文处理装置902发送所述测量报文。
第二报文处理装置902可以用于:根据接收到的所述测量报文,确定该测量报文对应的第二流指示信息对应的第一时间、第二时间和第四数量;根据所述第二流指示信息对应的第一时间、第二时间和第四数量确定该第二流指示信息对应的第二发送路径的丢包率和第三时延差;向第一报文处理装置发送所述第二流指示信息对应的第二发送路径的丢包率和第三时延差。
处理装置903可以用于:根据第一报文处理装置901接收到的第二流指示信息对应的第二发送路径的丢包率和第三时延差,获取该第二流指示信息对应的第二发送路径的质量信息。
也就是说,该系统900可实现对应于根据本申请实施例的图5所示方法中第一NP、第二NP和第一CPU所执行的步骤或者流程,该系统900可以包括用于执行图5所示方法中第一NP、第二NP、第一CPU执行的方法的装置。并且,该系统900中的各装置和上述其他操作和/或功能分别为了实现图5所示方法的相应步骤。例如,该系统900中的第一报文处理装置901可以用于执行图5所示方法中的步骤S201至步骤S203,第二报文处理装置902可以用于执行图5所示方法中的步骤S204至步骤S206,处理装置903可以用于执行图5所示方法中的步骤S207。
应理解,各装置执行上述相应步骤的具体过程在上述方法实施例中已经详细说明,为了简洁,在此不再赘述。
本申请还提供了一种第二精确匹配流表的更新装置。该更新装置可以包括处理模块。该更新装置可以执行上述图7所示方法实施例中第一CPU的功能,或者实现上述图7所示方法实施例中第一CPU执行的步骤或者流程。
例如,该更新装置的处理模块可以用于:获取第二精确匹配流表包括的第二流指 示信息对应的第二发送路径的质量信息和第一报文处理装置上报的采样数据;根据所述采样数据和所述质量信息更新所述第二精确匹配流表。
也就是说,该更新装置可实现对应于根据本申请实施例的图7所示方法中第一CPU所执行的步骤或者流程,该更新装置可以包括用于执行图7所示方法中第一CPU执行的方法的模块。并且,该更新装置中的各模块和上述其他操作和/或功能分别为了实现图7所示方法的相应步骤。例如,该更新装置中的处理模块可以用于执行图7所示方法中的步骤S301至步骤S302。
应理解,各模块执行上述相应步骤的具体过程在上述方法实施例中已经详细说明,为了简洁,在此不再赘述。
本申请实施例还提供了一种处理装置,包括处理器和接口。所述处理器可用于执行上述方法实施例中的方法。
应理解,上述处理装置可以是一个芯片。例如,参见图10,图10为本申请提供的芯片的一种实施方式的结构框图。图10所示的芯片可以为通用处理器,也可以为专用处理器。该芯片1000包括处理器1001。其中,处理器1001可以用于支持图8所示的装置执行图4所示的技术方案,支持图9所示的装置执行图5所示的技术方案,以及支持上述更新装置执行图7所示的技术方案。
可选的,该芯片1000还可以包括收发器1002,收发器1002用于接受处理器1001的控制,用于支持图8所示的装置执行图4所示的技术方案,支持图9所示的装置执行图5所示的技术方案,以及支持上述更新装置执行图7所示的技术方案。可选的,图10所示的芯片1000还可以包括:存储介质1003。
需要说明的是,图10所示的芯片可以使用下述电路或者器件来实现:一个或多个现场可编程门阵列(field programmable gate array,FPGA)、可编程逻辑器件(programmable logic device,PLD)、专用集成芯片(application specific integrated circuit,ASIC)、系统芯片(system on chip,SoC)、中央处理器(central processor unit,CPU)、网络处理器(network processor,NP)、数字信号处理电路(digital signal processor,DSP)、微控制器(micro controller unit,MCU),控制器、状态机、门逻辑、分立硬件部件、任何其他适合的电路、或者能够执行本申请通篇所描述的各种功能的电路的任意组合。
在实现过程中,上述方法的各步骤可以通过处理器中的硬件的集成逻辑电路或者软件形式的指令完成。结合本申请实施例所公开的方法的步骤可以直接体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器,处理器读取存储器中的信息,结合其硬件完成上述方法的步骤。为避免重复,这里不再详细描述。
应注意,本申请实施例中的处理器可以是一种集成电路芯片,具有信号的处理能力。在实现过程中,上述方法实施例的各步骤可以通过处理器中的硬件的集成逻辑电路或者软件形式的指令完成。上述的处理器可以是通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现场可编程门阵列(FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。可以实现或者执行本申请实施例 中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器,处理器读取存储器中的信息,结合其硬件完成上述方法的步骤。
可以理解,本申请实施例中的存储器可以是易失性存储器或非易失性存储器,或可包括易失性和非易失性存储器两者。其中,非易失性存储器可以是只读存储器(read-only memory,ROM)、可编程只读存储器(programmable ROM,PROM)、可擦除可编程只读存储器(erasable PROM,EPROM)、电可擦除可编程只读存储器(electrically EPROM,EEPROM)或闪存。易失性存储器可以是随机存取存储器(random access memory,RAM),其用作外部高速缓存。通过示例性但不是限制性说明,许多形式的RAM可用,例如静态随机存取存储器(static RAM,SRAM)、动态随机存取存储器(dynamic RAM,DRAM)、同步动态随机存取存储器(synchronous DRAM,SDRAM)、双倍数据速率同步动态随机存取存储器(double data rate SDRAM,DDR SDRAM)、增强型同步动态随机存取存储器(enhanced SDRAM,ESDRAM)、同步连接动态随机存取存储器(synchlink DRAM,SLDRAM)和直接内存总线随机存取存储器(direct rambus RAM,DR RAM)。应注意,本文描述的系统和方法的存储器旨在包括但不限于这些和任意其它适合类型的存储器。
根据本申请实施例提供的方法,本申请实施例还提供一种计算机程序产品,该计算机程序产品包括:计算机程序或指令,当该计算机程序或指令在计算机上运行时,使得该计算机执行图4、图5、图7所示实施例中任意一个实施例的方法。
根据本申请实施例提供的方法,本申请实施例还提供一种计算机存储介质,该计算机存储介质存储有计算机程序或指令,当该计算机程序或指令在计算机上运行时,使得该计算机执行图4、图5、图7所示实施例中任意一个实施例的方法。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机程序或指令。在计算机上加载和执行所述计算机程序或指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机程序或指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机程序或指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(digital subscriber line,DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质(例如,软盘、硬盘、磁带)、光介质(例如,高密度数字视频光盘(digital video disc,DVD))、或者半导体介质(例如,固态硬盘(solid state disc,SSD))等。
在本说明书中使用的术语“部件”、“模块”、“系统”等用于表示计算机相关的实体、硬件、固件、硬件和软件的组合、软件、或执行中的软件。例如,部件可以是但不限于,在处理器上运行的进程、处理器、对象、可执行文件、执行线程、程序和/或计算机。通过图示,在计算设备上运行的应用和计算设备都可以是部件。一个或多个部件可驻留在进程和/或执行线程中,部件可位于一个计算机上和/或分布在两个或更多个计算机之间。此外,这些部件可从在上面存储有各种数据结构的各种计算机可读介质执行。部件可例如根据具有一个或多个数据分组(例如来自与本地系统、分布式系统和/或网络间的另一部件交互的二个部件的数据,例如通过信号与其它系统交互的互联网)的信号通过本地和/或远程进程来通信。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各种说明性逻辑块(illustrative logical block)和步骤(step),能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统、装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述模块的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个模块或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能模块可以集成在一个处理单元中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个单元中。
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(read-only memory,ROM)、随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
上述本申请实施例提供的确定报文发送路径的装置、获取发送路径质量信息的系统、第二精确匹配流表的更新装置、计算机存储介质、计算机程序产品、芯片均用于执行上文所提供的方法,因此,其所能达到的有益效果可参考上文所提供的方法对应 的有益效果,在此不再赘述。
应理解,在本申请的各个实施例中,各步骤的执行顺序应以其功能和内在逻辑确定,各步骤序号的大小并不意味着执行顺序的先后,不对实施例的实施过程构成限定。
本说明书的各个部分均采用递进的方式进行描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点介绍的都是与其他实施例不同之处。尤其,确定报文发送路径的装置、获取发送路径质量信息的系统、第二精确匹配流表的更新装置、计算机存储介质、计算机程序产品、芯片的实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例中的说明即可。
尽管已描述了本申请的优选实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例作出另外的变更和修改。所以,所附权利要求意欲解释为包括优选实施例以及落入本申请范围的所有变更和修改。
以上所述的本申请实施方式并不构成对本申请保护范围的限定。

Claims (21)

  1. 一种确定报文发送路径的方法,其特征在于,所述方法应用于第一报文处理装置,包括:
    获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表;所述第一聚合流表包括第一表项信息;所述第一精确匹配流表包括第二表项信息;
    根据所述待处理报文的报文字段和所述第一表项信息确定第一信息;
    根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息;
    根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息,包括:
    当所述第二表项信息包括与所述报文字段匹配的第一秘钥时,根据所述第一秘钥对应的表项内容确定是否使用第三信息;所述第三信息为所述第一秘钥对应的表项内容包括的新信息;
    当使用所述第三信息时,获取第一时延差;所述第一时延差为所述第一秘钥对应的表项内容包括的新旧路径时延差;
    获取第二时延差;所述第二时延差为所述待处理报文到达所述第一报文处理装置的时间与其所在流中前一条报文到达所述第一报文处理装置的时间的间隔;
    当所述第二时延差大于所述第一时延差时,确定所述第三信息为所述第二信息。
  3. 根据权利要求2所述的方法,其特征在于,所述方法还包括:
    当不使用所述第三信息时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;
    确定所述第四信息为所述第二信息。
  4. 根据权利要求2所述的方法,其特征在于,所述方法还包括:
    当所述第二时延差小于等于所述第一时延差时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;
    确定所述第四信息为所述第二信息。
  5. 根据权利要求1所述的方法,其特征在于,所述根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息,包括:
    当所述第二表项信息不包括与所述报文字段匹配的第一秘钥时,确定所述第一信息为所述第二信息。
  6. 根据权利要求1至5任意一项所述的方法,其特征在于,所述根据所述待处理报文的报文字段和所述第一表项信息确定第一信息,包括:
    确定所述第一表项信息包含的表项的第一数量;
    对所述待处理报文的报文字段进行哈希计算,生成第一计算结果;
    根据所述第一计算结果和所述第一数量生成第一索引;
    根据所述第一索引和所述第一表项信息确定所述第一信息。
  7. 根据权利要求1至6任意一项所述的方法,其特征在于,所述根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径,包括:
    确定所述第一等价路径表对应的路径索引的第二数量;
    对所述第二信息进行哈希计算,生成第二计算结果;
    根据所述第二计算结果和所述第二数量生成第二索引;
    确定所述待处理报文的第一发送路径;所述第一发送路径是指路径索引为所述第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
  8. 根据权利要求1至7任意一项所述的方法,其特征在于,所述方法还包括:
    在所述待处理报文中添加一个报文头,该报文头包括所述第二信息和所述第一发送路径的信息。
  9. 根据权利要求5所述的方法,其特征在于,所述方法还包括:将所述待处理报文和所述第一信息上报给CPU。
  10. 一种确定报文发送路径的装置,其特征在于,所述装置包括:获取模块和处理模块;
    所述获取模块,用于获取待处理报文的第一等价路径表、第一聚合流表和第一精确匹配流表;所述第一聚合流表包括第一表项信息;所述第一精确匹配流表包括第二表项信息;
    所述处理模块,用于根据所述待处理报文的报文字段和所述第一表项信息确定第一信息;根据所述报文字段、所述第二表项信息和所述第一信息确定第二信息;根据所述第二信息和所述第一等价路径表,确定所述待处理报文的第一发送路径。
  11. 根据权利要求10所述的装置,其特征在于,所述处理模块具体用于:
    当所述第二表项信息包括与所述报文字段匹配的第一秘钥时,根据所述第一秘钥对应的表项内容确定是否使用第三信息;所述第三信息为所述第一秘钥对应的表项内容包括的新信息;
    当使用所述第三信息时,获取第一时延差;所述第一时延差为所述第一秘钥对应的表项内容包括的新旧路径时延差;
    获取第二时延差;所述第二时延差为所述待处理报文到达所述装置的时间与其所在流中前一条报文到达所述装置的时间的间隔;
    当所述第二时延差大于所述第一时延差时,确定所述第三信息为所述第二信息。
  12. 根据权利要求11所述的装置,其特征在于,所述处理模块还用于:
    当不使用所述第三信息时,获取第四信息;所述第四信息为所述第一秘钥对应的 表项内容包括的当前信息;
    确定所述第四信息为所述第二信息。
  13. 根据权利要求11所述的装置,其特征在于,所述处理模块还用于:
    当所述第二时延差小于等于所述第一时延差时,获取第四信息;所述第四信息为所述第一秘钥对应的表项内容包括的当前信息;
    确定所述第四信息为所述第二信息。
  14. 根据权利要求10所述的装置,其特征在于,所述处理模块具体用于:
    当所述第二表项信息不包括与所述报文字段匹配的第一秘钥时,确定所述第一信息为所述第二信息。
  15. 根据权利要求10至14任意一项所述的装置,其特征在于,所述处理模块具体用于:
    确定所述第一表项信息包含的表项的第一数量;
    对所述待处理报文的报文字段进行哈希计算,生成第一计算结果;
    根据所述第一计算结果和所述第一数量生成第一索引;
    根据所述第一索引和所述第一表项信息确定所述第一信息。
  16. 根据权利要求10至15任意一项所述的装置,其特征在于,所述处理模块具体用于:
    确定所述第一等价路径表对应的路径索引的第二数量;
    对所述第二信息进行哈希计算,生成第二计算结果;
    根据所述第二计算结果和所述第二数量生成第二索引;
    确定所述待处理报文的第一发送路径;所述第一发送路径是指路径索引为所述第二索引时,匹配所述第一等价路径表得到的路径信息指示的发送路径。
  17. 根据权利要求10至16任意一项所述的装置,其特征在于,所述处理模块还用于:
    在所述待处理报文中添加一个报文头,该报文头包括所述第二信息和所述第一发送路径的信息。
  18. 根据权利要求14所述的装置,其特征在于,所述处理模块还用于:将所述待处理报文和所述第一信息上报给CPU。
  19. 一种装置,其特征在于,包括处理器和存储器;
    所述处理器,用于执行所述存储器中存储的计算机程序或指令,当所述计算机程序或指令被执行时,使得所述装置实现权利要求1至9中任意一项所述的方法。
  20. 一种计算机可读存储介质,其特征在于,包括计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行如权利要求1至9中任一项所述的方法。
  21. 一种计算机程序产品,其特征在于,所述计算机程序产品在计算机上运行时,使得计算机执行如权利要求1至9中任一项所述的方法。
PCT/CN2021/100032 2020-06-16 2021-06-15 确定报文发送路径的方法及装置 WO2021254307A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010547999.7A CN113810284A (zh) 2020-06-16 2020-06-16 确定报文发送路径的方法及装置
CN202010547999.7 2020-06-16

Publications (1)

Publication Number Publication Date
WO2021254307A1 true WO2021254307A1 (zh) 2021-12-23

Family

ID=78944277

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/100032 WO2021254307A1 (zh) 2020-06-16 2021-06-15 确定报文发送路径的方法及装置

Country Status (2)

Country Link
CN (1) CN113810284A (zh)
WO (1) WO2021254307A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117041139A (zh) * 2023-10-09 2023-11-10 腾讯科技(深圳)有限公司 数据包传输方法、装置、计算机设备和存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2587750A1 (en) * 2011-10-28 2013-05-01 Telefonaktiebolaget LM Ericsson (publ) Addressing the large flow problem for equal cost multi-path in the datacenter
CN106487676A (zh) * 2016-10-27 2017-03-08 盛科网络(苏州)有限公司 一种基于大象流的动态ecmp芯片实现方法
CN107634912A (zh) * 2016-07-19 2018-01-26 华为技术有限公司 负载均衡方法、装置及设备
CN108965121A (zh) * 2017-05-19 2018-12-07 华为技术有限公司 传输数据的方法、主机和交换机

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2587750A1 (en) * 2011-10-28 2013-05-01 Telefonaktiebolaget LM Ericsson (publ) Addressing the large flow problem for equal cost multi-path in the datacenter
CN107634912A (zh) * 2016-07-19 2018-01-26 华为技术有限公司 负载均衡方法、装置及设备
CN106487676A (zh) * 2016-10-27 2017-03-08 盛科网络(苏州)有限公司 一种基于大象流的动态ecmp芯片实现方法
CN108965121A (zh) * 2017-05-19 2018-12-07 华为技术有限公司 传输数据的方法、主机和交换机

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117041139A (zh) * 2023-10-09 2023-11-10 腾讯科技(深圳)有限公司 数据包传输方法、装置、计算机设备和存储介质
CN117041139B (zh) * 2023-10-09 2024-03-26 腾讯科技(深圳)有限公司 数据包传输方法、装置、计算机设备和存储介质

Also Published As

Publication number Publication date
CN113810284A (zh) 2021-12-17

Similar Documents

Publication Publication Date Title
KR102317523B1 (ko) 패킷 제어 방법 및 네트워크 기기
US8830829B2 (en) Parallel processing using multi-core processor
US7908540B2 (en) Method of transmitting ethernet frame in network bridge and the bridge
US10742532B2 (en) Non-intrusive mechanism to measure network function packet processing delay
US8897130B2 (en) Network traffic management
WO2021169256A1 (zh) 网络性能检测方法、装置及网络设备
WO2018149177A1 (zh) 一种报文处理方法及装置
US10924374B2 (en) Telemetry event aggregation
WO2016095345A1 (zh) 报文转发的方法及网络设备
CN113037640A (zh) 数据转发方法、数据缓存方法、装置和相关设备
US11653251B2 (en) Packet forwarding method and apparatus
CN111026324B (zh) 转发表项的更新方法及装置
WO2021017578A1 (zh) 报文发送方法、装置及存储介质
WO2021254307A1 (zh) 确定报文发送路径的方法及装置
US20230300051A1 (en) In-band Edge-to-Edge Round-Trip Time Measurement
WO2020168563A1 (zh) 一种存储器的管理方法及装置
CN115242892B (zh) 一种流标识获取方法、装置、设备及介质
EP4231165A1 (en) Method and device for processing forwarding entry
WO2021120764A1 (zh) 一种收发数据的方法及装置
WO2016078212A1 (zh) 一种报文处理方法、装置及存储介质
US11824792B2 (en) Method and system for dynamic quota-based congestion management
WO2024055584A1 (zh) 时延测量方法、电子设备、计算机可读介质
US20220217092A1 (en) Packet flow out-of-order detection method, packet processing method, and apparatus
US11924106B2 (en) Method and system for granular dynamic quota-based congestion management
WO2021254474A1 (zh) 一种网络测量方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21825654

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21825654

Country of ref document: EP

Kind code of ref document: A1