Traffic forwarding method and device, equipment, storage medium and computer program product

By receiving exception path information in the ECMP scenario, determining the forwarding route and bandwidth ratio, and redividing traffic, the problem of secondary congestion or failure in path congestion or failure in traditional ECMP scenarios is solved, and the network is achieved higher reliability and stability.

CN119766720APending Publication Date: 2025-04-04NEW H3C TECH CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202411961737.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-27
Publication Date
2025-04-04

AI Technical Summary

Technical Problem

In traditional ECMP scenarios, when path congestion or failure, simply transfer traffic to other equivalent paths may lead to secondary path congestion or failure in a short period of time.

Method used

By receiving exception path information, determine the forwarding route to which the exception path belongs, and re-dividing forward traffic according to the bandwidth ratio between multiple forwarding paths to avoid secondary path congestion or failure.

Benefits of technology

The target traffic is diverted as a whole in the network to avoid secondary path congestion or failure in a short period of time, thereby improving the reliability and stability of the network.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119766720A_ABST
    Figure CN119766720A_ABST
Patent Text Reader

Abstract

The invention provides a traffic forwarding method and device, equipment, a storage medium and a computer program product. The method comprises the following steps: receiving abnormal path information sent by a second switch; based on the abnormal path information, determining a forwarding route to which a path between the second switch and the third switch belongs, the forwarding route being a route of the target traffic from the first switch at the source end to the third switch at the destination end; determining a bandwidth proportion among a plurality of forwarding paths belonging to the forwarding route; and forwarding the target traffic to the third switch through the plurality of forwarding paths based on the bandwidth proportion among the plurality of forwarding paths. According to the embodiment of the invention, a forwarding route to which an abnormal path belongs is determined; determining bandwidth proportions corresponding to a plurality of forwarding paths corresponding to the forwarding route; and the forwarding flow of the forwarding path is divided according to the bandwidth proportion, so that the condition of secondary path congestion or fault in a short time is avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and more specifically, to a traffic forwarding method, device, equipment, storage medium and computer program product. Background Art

[0002] Traditional equal-cost multi-path routing (ECMP) scenarios use multiple equal-cost paths in the network to forward data packets to achieve load balancing and redundancy backup.

[0003] However, ECMP does not have the ability to adjust the end side or the network side, and mainly calculates the next hop based on the N-tuple hash. Multi-path next hops are prone to uneven load, leading to path congestion or failure. In the event of path congestion or failure, the traffic of the congested or failed path is simply forwarded through other paths of equal cost, which may cause secondary path congestion or failure in a short period of time. Summary of the invention

[0004] Based on the above technical defects, the present application proposes a traffic forwarding method, device, equipment, storage medium and computer program product, which determines the forwarding route to which the abnormal path belongs; and determines the bandwidth ratios corresponding to multiple forwarding paths corresponding to the forwarding route; and divides the forwarding traffic of the forwarding path according to the bandwidth ratio, thereby avoiding secondary path congestion or failure in a short period of time.

[0005] A first aspect of the present application provides a traffic forwarding method, which is applied to a first switch, and the method includes:

[0006] receiving abnormal path information sent by the second switch, where the abnormal path information is used to represent information of a path between the second switch and the third switch where an abnormality occurs;

[0007] Based on the abnormal path information, determine a forwarding route to which the path between the second switch and the third switch belongs, where the forwarding route is a route of target traffic from the first switch at the source end to the third switch at the destination end;

[0008] Determining a bandwidth ratio between a plurality of forwarding paths belonging to the forwarding route;

[0009] Based on the bandwidth ratio between the multiple forwarding paths, the target traffic is forwarded to the third switch through the multiple forwarding paths.

[0010] A second aspect of the present application provides a traffic forwarding method, which is applied to a second switch, and the method includes:

[0011] Monitoring multiple downlink paths corresponding to the second switch;

[0012] When abnormal conditions are detected in the multiple downlink paths, the abnormal path information is sent to a first switch in the network, where the abnormal path information is used to characterize information about the path between the second switch and the third switch where the abnormal condition occurs.

[0013] A third aspect of the present application provides a traffic forwarding device, applied to a first switch, the device comprising:

[0014] A receiving module, configured to receive abnormal path information sent by the second switch, wherein the abnormal path information is used to represent information of a path between the second switch and the third switch where an abnormality occurs;

[0015] A determination module, configured to determine, based on the abnormal path information, a forwarding route to which the path between the second switch and the third switch belongs, wherein the forwarding route is a route of target traffic from the first switch at a source end to the third switch at a destination end;

[0016] The determination module is further used to determine the bandwidth ratio between the multiple forwarding paths belonging to the forwarding route;

[0017] A forwarding module is used to forward the target traffic to the third switch through the multiple forwarding paths based on the bandwidth ratio between the multiple forwarding paths.

[0018] A fourth aspect of the present application provides a traffic forwarding device, applied to a second switch, the device comprising:

[0019] A monitoring module, used to monitor multiple downlink paths corresponding to the second switch;

[0020] The sending module is used to send the abnormal path information to all first switches in the network when abnormal conditions occur in the multiple downlink paths, wherein the abnormal path information is used to characterize the path between the second switch and the third switch where the abnormal condition occurs.

[0021] In a fifth aspect, the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method described in the first or second aspect above.

[0022] A sixth aspect of the present application provides an electronic device having a computer program stored thereon, wherein the program is executed by a processor to implement the method described in the first aspect or the second aspect.

[0023] In a seventh aspect, the present application provides an electronic device, including a computer program, which, when executed by a processor, implements the method described in the first aspect or the second aspect.

[0024] The beneficial effects of this application include at least:

[0025] In an embodiment of the present application, by determining the forwarding route to which the abnormal path belongs; and determining the bandwidth ratios corresponding to the multiple forwarding paths corresponding to the forwarding route; and re-dividing the forwarding traffic of the forwarding path corresponding to the forwarding route according to the bandwidth ratio, the target traffic to be forwarded is diverted on the network as a whole, thereby avoiding secondary path congestion or failure in a short period of time. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] The accompanying drawings, which constitute a part of the specification, illustrate embodiments of the present application and, together with the description, serve to explain the principles of the present application.

[0027] The present application can be more clearly understood from the following detailed description with reference to the accompanying drawings, in which:

[0028] Figure 1 A schematic diagram of a network architecture of an ECMP scenario provided by an exemplary embodiment of the present application is shown;

[0029] Figure 2 A flow chart of a traffic forwarding method provided by an exemplary embodiment of the present application is shown;

[0030] Figure 3 A schematic diagram of the structure of a SPINE-LEAF network provided by an exemplary embodiment of the present application is shown;

[0031] Figure 4 A schematic diagram of data forwarding of a two-level ECMP provided by an exemplary embodiment of the present application is shown;

[0032] Figure 5 A flow chart of a traffic forwarding method provided by an exemplary embodiment of the present application is shown;

[0033] Figure 6 A schematic diagram of the structure of a traffic forwarding device provided by an exemplary embodiment of the present application is shown;

[0034] Figure 7 A schematic diagram of the structure of another traffic forwarding device provided by an exemplary embodiment of the present application is shown;

[0035] Figure 8 A schematic diagram of the structure of an electronic device provided by an exemplary embodiment of the present application is shown;

[0036] Fig. 9A schematic diagram of a storage medium provided by an exemplary embodiment of the present application is shown. DETAILED DESCRIPTION

[0037] Hereinafter, embodiments of the present application will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present application. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present application. It is obvious to those skilled in the art that the present application can be implemented without one or more of these details. In other examples, in order to avoid confusion with the present application, some technical features known in the art are not described.

[0038] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit exemplary embodiments according to the present application. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should also be understood that when the terms "comprise" and / or "include" are used in this specification, it indicates the presence of the features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.

[0039] Now, exemplary embodiments according to the present application will be described in more detail with reference to the accompanying drawings. However, these exemplary embodiments may be implemented in a variety of different forms and should not be construed as being limited to the embodiments described herein. The accompanying drawings are not drawn to scale, and certain details may be magnified and certain details may be omitted for the purpose of clear expression. The shapes of the various regions and layers shown in the figures and the relative sizes and positional relationships therebetween are merely exemplary, and may deviate in practice due to manufacturing tolerances or technical limitations, and those skilled in the art may additionally design regions / layers with different shapes, sizes, and relative positions according to actual needs.

[0040] The following describes an exemplary embodiment according to the present application. It should be noted that the following embodiments are only shown to facilitate understanding of the spirit and principle of the present application, and the embodiments of the present application are not limited in this regard. On the contrary, the embodiments of the present application can be applied to any applicable scenario.

[0041] Based on the above background technology, the traditional ECMP scenario diagram is as follows Figure 1 As shown, the scenario includes a local leaf switch, a spine switch, and a peer leaf switch.

[0042] These include the local leaf switches: leaf1 and leaf2, the spine switches spine1 and spine2, and the remote leaf switches leaf3 and leaf4. Leaf1 and leaf2 are connected to spine1 and spine2 respectively, and spine1 and spine2 are connected to leaf3 and leaf4 respectively.

[0043] In the related technologies, ECMP has no adjustment capability on the peer side or the network side. It mainly calculates the next hop based on the N-tuple hash. The multi-path next hop is prone to uneven load, resulting in path congestion or failure. Even if the Leaf-Spine load balancing is very uniform, if multiple local leaf switches access the peer leaf switch, and the two local leaf switches select the same spine switch for data forwarding, it will cause congestion, for example Figure 1 The peer leaf switches of leaf1 and leaf2 are both leaf3, and both choose spine2 for forwarding, which will cause congestion on the spine1-leaf3 path.

[0044] In some cases, remote paths may also fail, and when remote failures or congestion occur, the control plane is relied upon for perception, resulting in poor overall convergence. When path congestion or failure occurs, the traffic on the congested or failed path is simply forwarded through other paths of equal cost, which may result in secondary path congestion or failure within a short period of time.

[0045] In view of the above technical problems, the present application proposes a traffic forwarding method, device, equipment, storage medium and computer program product, which are applied to a first switch, and the method includes: receiving abnormal path information sent by a second switch; the abnormal path information is used to characterize the information of the path between the second switch and the third switch where the abnormality occurs, and based on the abnormal path information, determining the forwarding route to which the path between the second switch and the third switch belongs, the forwarding route is the route between the target traffic from the first switch at the source end to the third switch at the destination end; determining the bandwidth ratio between multiple forwarding paths belonging to the forwarding route; based on the bandwidth ratio between the multiple forwarding paths, forwarding the target traffic to the third switch through multiple forwarding paths. The embodiment of the present application determines the forwarding route to which the abnormal path belongs; and determines the bandwidth ratio corresponding to each of the multiple forwarding paths corresponding to the forwarding route; and re-divides the forwarding traffic of the forwarding path corresponding to the forwarding route according to the bandwidth ratio, so as to divert the target traffic to be forwarded on the network as a whole, thereby avoiding secondary path congestion or failure in a short time.

[0046] The embodiment of the present application first describes the traffic forwarding method by taking the first switch in the ECMP scenario as the execution subject, wherein the first switch may be a leaf switch connected to the data source in the ECMP scenario.

[0047] See also Figure 2 , the method comprises the following steps.

[0048] S201. Receive abnormal path information sent by a second switch.

[0049] The abnormal path information is used to represent information about the path between the second switch and the third switch where the abnormality occurs.

[0050] The abnormal path may be a congested path or a normal path.

[0051] The second switch can be a spine switch connected to a leaf switch, and the ECMP dynamic load balancing (DLB) mode can be enabled on the spine switch to monitor the downlink path corresponding to the second switch. When the second switch detects a path failure or congestion, it sends a notification message to all leaf switches in the network. The message includes the switch identifier of the second switch and the switch identifier of the remote leaf switch adjacent to the second switch.

[0052] The process in which a spine switch detects a downlink path failure or congestion can be implemented as follows:

[0053] Path anomaly detection: Spine switches can detect path anomalies by checking the port alarms of switches at both ends of the Leaf-Spine path, or by regularly collecting port transmission statistics of switches. This method can detect scenarios where the path is completely interrupted, but it cannot effectively detect abnormal conditions such as congestion and pseudo-death on the path.

[0054] Full message mirroring analysis: Another solution is to perform full message mirroring analysis on messages transmitted along the path between Leaf and Spine. However, this method has a large overhead, especially when the path bandwidth is large (such as 40 Gbps). Full message mirroring will consume a large amount of path bandwidth and put pressure on the backend analysis server.

[0055] Machine learning algorithm: Through training samples of normal traffic, the machine learning algorithm is used to obtain alarm thresholds for multiple dimensions (such as latency, jitter, packet loss, and load sharing ratio) to determine whether the path is an abnormal path.

[0056] Active detection and traffic analysis: Create a detection virtual machine in one or more host nodes under each leaf switch to perform flow detection, and mirror the traffic passing through the virtual network to the backend server for analysis to detect traffic anomalies. This method uses machine learning algorithms to detect path status anomalies by performing fine-grained analysis of colored packets, combining multiple dimensions.

[0057] It should be noted that other detection methods may also be used to determine whether a path is faulty or congested, which will not be described in detail here.

[0058] At this time, the first switch may receive the message and the abnormal path information in the message. The abnormal path information may include the switch identifier of the second switch and the switch identifier of the remote leaf switch adjacent to the second switch.

[0059] S202: Determine a forwarding route to which the path between the second switch and the third switch belongs based on the abnormal path information.

[0060] The forwarding route is the route of the target traffic from the first switch at the source end to the third switch at the destination end.

[0061] It can be understood that the second switch is connected to the first switch, and the abnormal path information includes the switch identifier of the second switch and the switch identifier of the remote leaf switch adjacent to the second switch. Therefore, the first switch can determine the forwarding route to which the path between the second switch and the third switch belongs based on the abnormal path information.

[0062] The forwarding route is a route between leaf switches, that is, a route between a local leaf switch and a remote leaf switch, and the third switch may be a remote leaf switch.

[0063] Based on this, it can be determined that the forwarding route to which the path belongs is the route between the target traffic from the first switch at the source end to the third switch at the destination end.

[0064] S203: Determine a bandwidth ratio between multiple forwarding paths belonging to the forwarding route.

[0065] It is understandable that each forwarding route has multiple forwarding paths to ensure that when a forwarding path fails or is congested, the data to be forwarded by the failed or congested forwarding path is forwarded through other forwarding paths.

[0066] When determining a failed path or a congested path, the forwarding traffic of each forwarding path during retransmission can be determined based on the bandwidth ratio between multiple forwarding paths of the forwarding route. Therefore, after determining the forwarding route to which the path belongs, the bandwidth ratio between multiple forwarding paths belonging to the forwarding route can be determined.

[0067] In some embodiments, each forwarding path may include a forwarding sub-path, where the forwarding sub-path may be a path from a leaf switch to a spine switch or a path from a spine switch to a leaf switch, and the maximum bandwidth of the switch in each path may be obtained. Therefore, the comprehensive bandwidth of each forwarding path may be determined based on the maximum bandwidth of the forwarding sub-path corresponding to each forwarding path, and the bandwidth ratio between multiple forwarding paths may be further determined based on the comprehensive bandwidth of each path.

[0068] The maximum bandwidth of each forwarding sub-path may be obtained through specification parameters of a switch, or through a network monitoring tool, or through port statistics information, and the like.

[0069] S204: forwarding the target traffic to the third switch through the multiple forwarding paths based on the bandwidth ratio between the multiple forwarding paths.

[0070] The ratio of target traffic forwarded by each forwarding path is determined by the bandwidth ratio between multiple forwarding paths. Assuming that there are three forwarding paths from the first switch to the third switch, and the bandwidth ratio between the three forwarding paths is 1:2:3, and the total data volume of the target traffic is 60G, then the three forwarding paths forward 10G traffic, 20G traffic and 30G traffic respectively.

[0071] The present application proposes a traffic forwarding method, which is applied to a first switch, and the method includes: receiving abnormal path information sent by a second switch; the abnormal path information is used to characterize the information of the path between the second switch and the third switch where the abnormality occurs; based on the abnormal path information, determining the forwarding route to which the path between the second switch and the third switch belongs, the forwarding route is the route between the target traffic from the first switch at the source end to the third switch at the destination end; determining the bandwidth ratio between multiple forwarding paths belonging to the forwarding route; based on the bandwidth ratio between the multiple forwarding paths, forwarding the target traffic to the third switch through the multiple forwarding paths. The embodiment of the present application determines the forwarding route to which the abnormal path belongs; and determines the bandwidth ratio corresponding to each of the multiple forwarding paths corresponding to the forwarding route; and re-divides the forwarding traffic of the forwarding path corresponding to the forwarding route according to the bandwidth ratio, thereby diverting the target traffic to be forwarded on the network as a whole, thereby avoiding secondary path congestion or failure in a short period of time.

[0072] In some embodiments, the abnormal path information includes congested path information, and determining the bandwidth ratio between multiple forwarding paths belonging to the forwarding route includes: determining the comprehensive bandwidth of each forwarding path respectively; and determining the bandwidth ratio between the multiple forwarding paths based on the comprehensive bandwidth of each forwarding path.

[0073] It is understandable that abnormal path information may be congested path information, and a congested path means that the path can still forward data, but the amount of data currently forwarded is relatively large, exceeding the maximum bandwidth that the path can forward, and the amount of data transmitted by the path needs to be reduced. Therefore, when abnormal path information is received and multiple forwarding paths of the forwarding route to which the path belongs are determined, it is necessary to determine the comprehensive bandwidth of the forwarding path to which the path belongs and the comprehensive bandwidth of other forwarding paths.

[0074] The comprehensive bandwidth may be the sum of the maximum bandwidths of the forwarding sub-paths, or a corresponding weight may be set for each forwarding sub-path, and the comprehensive bandwidth of each forwarding path may be determined based on the maximum bandwidth of each forwarding sub-path and the corresponding weight.

[0075] Further, the bandwidth ratio between the multiple forwarding paths may be determined based on the comprehensive bandwidth of each forwarding path.

[0076] The present application embodiment provides a schematic diagram of the structure of a SPINE-LEAF network, such as Figure 3 As shown, the network includes a local leaf switch leaf1 and two remote leaf switches leaf2 and leaf3. The network also includes three spine switches spine1, spine2 and spine3, wherein leaf1 is connected to the three spine switches respectively, and the three spine switches are connected to leaf2 and leaf3 respectively.

[0077] from Figure 3 It can be determined that there are two forwarding routes in the current network: leaf1 to leaf2 and leaf1 to leaf3.

[0078] Assume that at a certain moment, spine1 detects that the path from spine1 to leaf2 is congested. Then, by querying the routing table, it can be determined that the forwarding route to which the congested path belongs is leaf1 to leaf2. It can further be determined that the multiple forwarding paths corresponding to the forwarding route are leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2.

[0079] Further determine the maximum bandwidth of each forwarding sub-path, that is, respectively determine the maximum bandwidths of the path from leaf1 to spine1, the path from spine1 to leaf2, the path from leaf1 to spine2, the path from spine2 to leaf2, the path from leaf1 to spine3, and the path from spine3 to leaf2; further, determine the comprehensive bandwidths of leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2 based on the maximum bandwidths of each path; thereby determine the bandwidth ratios of leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2 based on the comprehensive bandwidths of leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2.

[0080] In some embodiments, the abnormal path information includes faulty path information, and determining the bandwidth ratio between multiple forwarding paths belonging to the forwarding route includes: determining that the comprehensive bandwidth corresponding to the forwarding path to which the faulty path information belongs is set to 0; determining the comprehensive bandwidth corresponding to each of the other forwarding paths, where the other forwarding paths are paths among the multiple forwarding paths other than the forwarding path to which the faulty path information belongs; and determining the bandwidth ratio between the other forwarding paths based on the comprehensive bandwidth corresponding to each of the other forwarding paths.

[0081] It can be understood that the abnormal path information can be a faulty path information, and a faulty path refers to a path that loses the ability to forward data, that is, the path cannot forward data. Therefore, when the faulty path information is received and multiple forwarding paths of the forwarding route to which the path belongs are determined, the comprehensive bandwidth corresponding to the forwarding path to which the faulty path information belongs is determined to be set to 0, and the comprehensive bandwidths corresponding to the other forwarding paths are determined respectively.

[0082] by Figure 3 For example, assuming that at a certain moment, spine1 detects that the path from spine1 to leaf2 is congested, then by querying the routing table, it can be determined that the forwarding route to which the congested path belongs is leaf1 to leaf2, and further determined that the forwarding paths corresponding to the forwarding route are leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2.

[0083] It is determined that the integrated bandwidth corresponding to the forwarding path to which the faulty path information belongs is set to 0, and the integrated bandwidths corresponding to other forwarding paths are determined respectively, that is, the maximum bandwidth of the forwarding path from leaf1 to spine1 to leaf2 is set to 0, and the maximum bandwidths of the path from spine2 to leaf2, the path from leaf1 to spine3, and the path from spine3 to leaf2 are determined respectively. Further, based on the maximum bandwidth of each path, the integrated bandwidths of leaf1 to spine2 to leaf2 and leaf1 to spine3 to leaf2 are determined, so as to determine the bandwidth ratios between leaf1 to spine2 to leaf2 and leaf1 to spine3 to leaf2 based on the integrated bandwidths of leaf1 to spine2 to leaf2 and leaf1 to spine3 to leaf2.

[0084] In some embodiments, determining the comprehensive bandwidth of each forwarding path includes: obtaining multiple forwarding sub-paths corresponding to each forwarding path; determining the bandwidth of each forwarding sub-path; and determining the comprehensive bandwidth of each forwarding path based on the bandwidths corresponding to the multiple forwarding sub-paths corresponding to each forwarding path.

[0085] In some embodiments, multiple forwarding sub-paths corresponding to each forwarding path can be determined by querying the routing table, and the bandwidth of each forwarding sub-path can be further determined by obtaining the specification parameters of the switch, or by using a network monitoring tool, or by obtaining port statistics, etc., where the bandwidth can be the remaining bandwidth of each forwarding sub-path or the maximum bandwidth of each forwarding sub-path.

[0086] The comprehensive bandwidth may be the sum of the maximum bandwidths of the forwarding sub-paths, or a corresponding weight may be set for each forwarding sub-path, and the comprehensive bandwidth of each forwarding path may be determined based on the maximum bandwidth of each forwarding sub-path and the corresponding weight.

[0087] In some embodiments, based on the bandwidth ratio between the multiple forwarding paths, the target traffic is forwarded to the third switch through the multiple forwarding paths, including: determining the forwarding traffic corresponding to at least one target downstream path corresponding to each data source node based on the bandwidth ratio between the target traffic and the multiple forwarding paths, the at least one target downstream path being a path belonging to the forwarding route among the multiple downstream paths corresponding to each data source node; sending the forwarding traffic corresponding to the at least one target downstream path corresponding to each data source node to the routing forwarding chip corresponding to each data source node, so that the routing forwarding chip forwards according to the forwarding traffic corresponding to the at least one target downstream path, so as to forward the target traffic to the third switch.

[0088] In some embodiments, the data source node may be a leaf switch or a spine switch. For the downlink path, the switch in the data source direction to which it is connected is the data source node. Figure 3 For example, the data source node of the path from spine2 to leaf2 is spine2.

[0089] Determining the forwarding flow corresponding to at least one target downlink path corresponding to each data source node based on the target flow and the bandwidth ratio between the multiple forwarding paths can be implemented as follows:

[0090] The data flow of each forwarding path is determined based on the target flow and the bandwidth ratio between the multiple forwarding paths, and the forwarding flow corresponding to at least one target downlink path corresponding to each data source node is further determined.

[0091] by Figure 3 For example, assuming that the target traffic transmitted by leaf1 is 100G, the bandwidth ratios between leaf1 to spine1 to leaf2, leaf1 to spine2 to leaf2, and leaf1 to spine3 to leaf2 are 2:3:5, then the traffic transmitted from leaf1 to spine1 to leaf2 is 20G, the traffic transmitted from leaf1 to spine2 to leaf2 is 30G, and the traffic transmitted from leaf1 to spine3 to leaf2 is 50G. Then the forwarding traffic corresponding to at least one target downlink path corresponding to the data source node leaf1 can be calculated.

[0092] Each switch is respectively provided with a routing forwarding chip, and the routing forwarding chip is used to forward the traffic forwarded to the switch according to the forwarding traffic corresponding to at least one target downlink path.

[0093] Among them, each routing and forwarding chip can be abstracted into a two-level ECMP according to the secondary virtual routing. The two-level ECMP generation method of the Spine switch can be: In the data center network, the Spine switch is usually used as a core layer switch. They can be configured with a multi-path aggregation system and serve as a gateway. In this configuration, the Spine device can run ECMP to achieve load balancing and redundant transmission of traffic.

[0094] The two-level ECMP generation mode of the Leaf switch can be: As the access device of the server, the access switch can also be configured as a multi-path aggregation system, and together with the Spine switch, a two-level ECMP network can be implemented. In this way, the server can be dual-uplinked to the two-level ECMP system through the aggregation port, further improving the redundancy and reliability of the network.

[0095] By running ECMP, these devices can intelligently distribute traffic among multiple equal-cost paths, thereby improving network bandwidth utilization and reliability. Two-level ECMP configuration can be implemented on network devices at different levels, such as between Spine and Leaf switches, or between routers at different levels.

[0096] according to Figure 3 The routing method shown abstracts the route Leaf1->Leaf2 / Leaf3 into a two-level ECMP according to the secondary VN. The implementation process is as follows:

[0097] Spine-Leaf structure: In this architecture, Leaf nodes (access layer switches) and Spine nodes (core layer switches) are interconnected through three layers, using OSPF or EBGP protocol to achieve equal-cost multi-path load balancing and path backup.

[0098] Leaf nodes deploy multipath aggregation to achieve access reliability. Multipath aggregation allows multiple physical paths to appear as one path logically, enhancing network redundancy and load balancing capabilities.

[0099] Virtual Extensible LAN (VXLAN) and Ethernet VPN (EVPN): In the example of configuring VXLAN to achieve Layer 2 interoperability, it is mentioned that a VXLAN tunnel is established between Leaf2 and Leaf3 through EVPN, which is a technical means to implement two-level ECMP.

[0100] ECMP load sharing: ECMP can achieve load balancing and redundant transmission of data in the network. When the router finds that there are multiple optimal paths to the same destination address, it will update the routing table and add multiple rules for this destination address, corresponding to multiple next hops.

[0101] Through the above, we can get Figure 4 The ECMP structure diagram shown is the two-level ECMP structure diagram corresponding to Leaf1. Through routing query, two ECMPL1s are obtained, corresponding to Leaf1->Leaf2 and Leaf1->Leaf3 respectively.

[0102] Further, the forwarding traffic corresponding to at least one target downstream path corresponding to Leaf1 is sent to ECMPL1. Further, ECMPL1 sends the forwarding traffic corresponding to at least one target downstream path to ECMPL2. Since at least one target downstream path corresponding to Leaf1 is leaf1-spine1, leaf1-spine2, and leaf1-spine3, ECMPL1 sends the forwarding traffic corresponding to leaf1-spine1, leaf1-spine2, and leaf1-spine3 to ECMPL2, so that ECMPL2 controls at least one target downstream path to forward according to the forwarding traffic corresponding to at least one target downstream path, so as to forward the target traffic to leaf2.

[0103] The embodiment of the present application also illustrates the traffic forwarding method using the second switch in the ECMP scenario as the execution subject, wherein the second switch may be a spine switch connected to a leaf switch.

[0104] like Figure 5 , the method comprises the following steps:

[0105] S501. Monitor multiple downlink paths corresponding to the second switch.

[0106] S502: When abnormal conditions are detected in multiple downlink paths, abnormal path information is sent to a first switch in the network.

[0107] The abnormal path information is used to represent information about the path between the second switch and the third switch where the abnormality occurs.

[0108] ECMP DLB mode can be enabled on the spine switch to monitor the downstream path corresponding to the second switch. When a path failure or congestion is detected, a notification message is sent to all leaf switches in the network, and the message includes the switch identifier of the second switch and the switch identifier of the remote leaf switch adjacent to the second switch. At this time, the first switch in the network can obtain the abnormal link information. The first switch can be a leaf switch connected to the data source in the ECMP scenario.

[0109] The present application proposes a traffic forwarding method, which is applied to a second switch, and the method includes: monitoring multiple downstream paths corresponding to the second switch; when abnormal conditions are detected in the multiple downstream paths, sending abnormal path information to a first switch in the network. The embodiment of the present application monitors the downstream path of the switch, and when an abnormal path is detected, the abnormal path information is sent to all switches in the network, so that the leaf switch connected to the data source in the network can quickly perceive the abnormal path to switch the path.

[0110] In some embodiments, the method further comprises:

[0111] When forwarding traffic corresponding to at least one target downlink path sent by the second switch is received, forwarding is performed according to the forwarding traffic corresponding to the at least one target downlink path, where the at least one target downlink path is a path belonging to the forwarding route among the multiple downlink paths corresponding to the second switch.

[0112] In some embodiments, the data source node may be a leaf switch or a spine switch. For the downlink path, the switch in the data source direction to which it is connected is the data source node. Figure 3 For example, the data source node of the path from spine2 to leaf2 is spine2.

[0113] Each switch is respectively provided with a routing forwarding chip, and the routing forwarding chip is used to forward the traffic forwarded to the switch according to the forwarding traffic corresponding to at least one target downlink path.

[0114] The embodiment of the present application also provides a traffic forwarding device, which is applied to the first switch and is used to perform the above Figure 2 The traffic forwarding method in the embodiment, such as Figure 6 As shown, the device includes: a receiving module 601, a determining module 602 and a forwarding module 603.

[0115] The receiving module 601 is used to receive abnormal path information sent by the second switch, where the abnormal path information is used to represent the path between the second switch and the third switch where the abnormality occurs;

[0116] A determination module 602 is configured to determine, based on the abnormal path information, a forwarding route to which the path between the second switch and the third switch belongs, wherein the forwarding route is a route between the target traffic from the first switch at the source end to the third switch at the destination end;

[0117] The determination module 602 is further configured to determine a bandwidth ratio between multiple forwarding paths belonging to the forwarding route;

[0118] The forwarding module 603 is configured to forward the target traffic to the third switch through the multiple forwarding paths based on the bandwidth ratio between the multiple forwarding paths.

[0119] The present application proposes a traffic forwarding method, device, equipment, storage medium and computer program product, which are applied to a first switch, the method comprising: receiving abnormal path information sent by a second switch; the abnormal path information is used to characterize the information of the path between the second switch and the third switch where the abnormality occurs, and based on the abnormal path information, determining the forwarding route to which the path between the second switch and the third switch belongs, the forwarding route being the route between the target traffic from the first switch at the source end to the third switch at the destination end; determining the bandwidth ratio between multiple forwarding paths belonging to the forwarding route; based on the bandwidth ratio between the multiple forwarding paths, forwarding the target traffic to the third switch through the multiple forwarding paths. The embodiment of the present application determines the forwarding route to which the abnormal path belongs; and determines the bandwidth ratio corresponding to each of the multiple forwarding paths corresponding to the forwarding route; and re-divides the forwarding traffic of the forwarding path corresponding to the forwarding route according to the bandwidth ratio, thereby diverting the target traffic to be forwarded on the network as a whole, thereby avoiding secondary path congestion or failure in a short time.

[0120] In some embodiments, the abnormal path information includes congested path information, and the determination module 602 is specifically used to:

[0121] Determine the comprehensive bandwidth of each forwarding path separately;

[0122] The bandwidth ratio between the multiple forwarding paths is determined based on the comprehensive bandwidth of each forwarding path.

[0123] In some embodiments, the abnormal path information includes fault path information, and the determination module 602 is further specifically configured to:

[0124] Determine that the integrated bandwidth corresponding to the forwarding path to which the faulty path information belongs is set to 0;

[0125] Determine the comprehensive bandwidth corresponding to each of the other forwarding paths, where the other forwarding paths are paths among the multiple forwarding paths except the forwarding path to which the fault path information belongs;

[0126] The bandwidth ratio between the other forwarding paths is determined based on the comprehensive bandwidths corresponding to the other forwarding paths.

[0127] In some embodiments, the determination module 602 is further specifically configured to:

[0128] Obtain multiple forwarding sub-paths corresponding to each forwarding path;

[0129] Determine the bandwidth of each forwarding subpath;

[0130] Based on the bandwidths corresponding to the multiple forwarding sub-paths corresponding to each forwarding path, the comprehensive bandwidth of each forwarding path is determined.

[0131] In some embodiments, the forwarding module 603 is specifically configured to:

[0132] Determine the forwarding traffic corresponding to at least one target downlink path corresponding to each data source node based on the bandwidth ratio between the target traffic and the multiple forwarding paths, wherein the at least one target downlink path is a path belonging to the forwarding route among the multiple downlink paths corresponding to each data source node;

[0133] The forwarding traffic corresponding to the at least one target downlink path corresponding to each data source node is sent to the routing forwarding chip corresponding to each data source node, so that the routing forwarding chip forwards the forwarding traffic according to the at least one target downlink path, so as to forward the target traffic to the third switch.

[0134] The embodiment of the present application also provides a traffic forwarding device, which is applied to the second switch and is used to perform the above Figure 5 The traffic forwarding method in the embodiment, such as Figure 7 As shown, the device includes: a monitoring module 71 and a sending module 72.

[0135] A monitoring module 71, configured to monitor multiple downlink paths corresponding to the second switch;

[0136] The sending module 72 is used to send the abnormal path information to the first switch in the network when abnormal conditions occur in the multiple downlink paths. The abnormal path information is used to represent the path between the second switch and the third switch where the abnormal condition occurs.

[0137] The present application proposes a traffic forwarding method, which is applied to a second switch, and the method includes: monitoring multiple downstream paths corresponding to the first switch; when abnormal conditions are detected in the multiple downstream paths, sending the abnormal path information to all switches in the network. The embodiment of the present application monitors the downstream path of the switch, and when an abnormal path is detected, the abnormal path information is sent to all switches in the network, so that the leaf switch connected to the data source in the network can quickly perceive the abnormal path to switch the path.

[0138] In some embodiments, the above device further includes a forwarding module, which is used to:

[0139] When forwarding traffic corresponding to at least one target downlink path sent by the second switch is received, forwarding is performed according to the forwarding traffic corresponding to the at least one target downlink path, where the at least one target downlink path is a path belonging to the forwarding route among the multiple downlink paths corresponding to the second switch.

[0140] Please refer to the following Figure 8 , which shows a schematic diagram of an electronic device provided by some embodiments of the present application. Figure 8 As shown, the electronic device 7 includes: a processor 700, a memory 701, a bus 707 and a communication interface 703, and the processor 700, the communication interface 703 and the memory 701 are connected via the bus 707; the memory 701 stores a computer program that can be run on the processor 700, and when the processor 700 runs the computer program, it executes the traffic forwarding method provided in any of the aforementioned embodiments of the present application.

[0141] The memory 701 may include a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk memory. The communication connection between the system network element and at least one other network element is realized through at least one communication interface 703 (which may be wired or wireless), and the Internet, wide area network, local area network, metropolitan area network, etc. may be used.

[0142] The bus 707 may be an ISA bus, a PCI bus, or an EISA bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. The memory 701 is used to store programs, and the processor 700 executes the programs after receiving the execution instruction. The traffic forwarding method disclosed in any implementation of the aforementioned embodiment of the present application may be applied to the processor 700, or implemented by the processor 700.

[0143] The processor 700 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 700. The above processor 700 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a readily available programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to be executed, or the hardware and software modules in the decoding processor can be executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 701, and the processor 700 reads the information in the memory 701 and completes the steps of the above method in combination with its hardware.

[0144] The electronic device provided in the embodiment of the present application and the traffic forwarding method provided in the embodiment of the present application are based on the same application concept and have the same beneficial effects as the methods adopted, operated or implemented therein.

[0145] The present application also provides a computer-readable storage medium corresponding to the traffic forwarding method provided in the above embodiment. Fig. 9 , Fig. 9 The computer-readable storage medium shown is an optical disc 30 on which a computer program (ie, a program product) is stored. When the computer program is executed by a processor, the traffic forwarding method provided by any of the aforementioned embodiments is executed.

[0146] In addition, examples of the computer-readable storage medium may also include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other optical or magnetic storage media, which are not listed here one by one.

[0147] The computer-readable storage medium provided in the above-mentioned embodiments of the present application and the traffic forwarding method provided in the embodiments of the present application are based on the same application concept and have the same beneficial effects as the methods adopted, run or implemented by the application programs stored therein.

[0148] It should be noted that the algorithms and displays provided herein are not inherently related to any particular computer, virtual device, or other device. Various general-purpose devices may also be used in conjunction with the teachings herein. Based on the above description, it is apparent that the structures required to construct such devices are suitable. In addition, the present application is not directed to any particular programming language. It should be understood that the contents of the present application described herein may be implemented using various programming languages, and the description of the specific languages ​​above is intended to disclose the best implementation of the present application.

[0149] Similarly, it should be understood that in order to streamline the present application and aid in understanding one or more of the various application aspects, in the above description of the exemplary embodiments of the present application, the various features of the present application are sometimes grouped together into a single embodiment, figure, or description thereof. However, this disclosed method should not be interpreted as reflecting the following intention: the claimed application requires more features than the features explicitly recited in each claim. More specifically, as reflected in the claims below, the application aspects lie in less than all the features of the single embodiment disclosed above. Therefore, the claims following the specific embodiment are hereby expressly incorporated into the specific embodiment, with each claim itself serving as a separate embodiment of the present application.

[0150] The various component embodiments of the present application can be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that a microprocessor or digital signal processor (DSP) can be used in practice to implement some or all functions of some or all components in the creation device of the virtual machine according to the embodiment of the present application. The present application can also be implemented as a device or device program for executing part or all of the methods described herein. The program implementing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.

[0151] The above is only a preferred specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.

Claims

1. A traffic forwarding method, characterized in that: Applied to a first switch, the method includes: receiving abnormal path information sent by the second switch, where the abnormal path information is used to represent information of a path between the second switch and the third switch where an abnormality occurs; Based on the abnormal path information, determine a forwarding route to which the path between the second switch and the third switch belongs, where the forwarding route is a route of target traffic from the first switch at the source end to the third switch at the destination end; Determining a bandwidth ratio between a plurality of forwarding paths belonging to the forwarding route; Based on the bandwidth ratio between the multiple forwarding paths, the target traffic is forwarded to the third switch through the multiple forwarding paths.

2. The method according to claim 1, characterized in that: The abnormal path information includes congested path information, and the determining of the bandwidth ratio between the multiple forwarding paths belonging to the forwarding route includes: Determine the comprehensive bandwidth of each forwarding path separately; The bandwidth ratio between the multiple forwarding paths is determined based on the comprehensive bandwidth of each forwarding path.

3. The method according to claim 1, characterized in that The abnormal path information includes fault path information, and the determining of the bandwidth ratio between the multiple forwarding paths belonging to the forwarding route includes: Determine that the integrated bandwidth corresponding to the forwarding path to which the faulty path information belongs is set to 0; Determine the comprehensive bandwidth corresponding to each of the other forwarding paths, where the other forwarding paths are paths among the multiple forwarding paths except the forwarding path to which the fault path information belongs; The bandwidth ratio between the other forwarding paths is determined based on the comprehensive bandwidths corresponding to the other forwarding paths.

4. The method according to claim 2, characterized in that: The step of respectively determining the comprehensive bandwidth of each forwarding path includes: Obtain multiple forwarding sub-paths corresponding to each forwarding path; Determine the bandwidth of each forwarding subpath; Based on the bandwidths corresponding to the multiple forwarding sub-paths corresponding to each forwarding path, the comprehensive bandwidth of each forwarding path is determined.

5. The method according to claim 4, characterized in that The forwarding the target traffic to the third switch through the multiple forwarding paths based on the bandwidth ratio between the multiple forwarding paths includes: Determine the forwarding traffic corresponding to at least one target downlink path corresponding to each data source node based on the bandwidth ratio between the target traffic and the multiple forwarding paths, wherein the at least one target downlink path is a path belonging to the forwarding route among the multiple downlink paths corresponding to each data source node; The forwarding traffic corresponding to the at least one target downlink path corresponding to each data source node is sent to the routing forwarding chip corresponding to each data source node, so that the routing forwarding chip forwards the forwarding traffic according to the at least one target downlink path, so as to forward the target traffic to the third switch.

6. A traffic forwarding method, characterized in that: Applied to the second switch, the method includes: Monitoring multiple downlink paths corresponding to the second switch; When abnormal conditions are detected in the multiple downlink paths, the abnormal path information is sent to a first switch in the network, where the abnormal path information is used to characterize information about the path between the second switch and the third switch where the abnormal condition occurs.

7. The method according to claim 6, characterized in that The method further comprises: When forwarding traffic corresponding to at least one target downlink path sent by the second switch is received, forwarding is performed according to the forwarding traffic corresponding to the at least one target downlink path, where the at least one target downlink path is a path belonging to the forwarding route among the multiple downlink paths corresponding to the second switch.

8. A traffic forwarding device, characterized in that: Applied to a first switch, the device comprises: A receiving module, configured to receive abnormal path information sent by the second switch, wherein the abnormal path information is used to represent information of a path between the second switch and the third switch where an abnormality occurs; A determination module, configured to determine, based on the abnormal path information, a forwarding route to which the path between the second switch and the third switch belongs, wherein the forwarding route is a route of target traffic from the first switch at a source end to the third switch at a destination end; The determination module is further used to determine the bandwidth ratio between the multiple forwarding paths belonging to the forwarding route; A forwarding module is used to forward the target traffic to the third switch through the multiple forwarding paths based on the bandwidth ratio between the multiple forwarding paths.

9. A traffic forwarding device, characterized in that: Applied to a second switch, the device comprises: A monitoring module, used to monitor multiple downlink paths corresponding to the second switch; The sending module is used to send the abnormal path information to all switches in the network when abnormal conditions occur in the multiple downlink paths, wherein the abnormal path information is used to characterize the path between the second switch and the third switch where the abnormal condition occurs.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: The processor executes the computer program to implement the method according to any one of claims 1 to 7.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: The program is executed by a processor to implement the method according to any one of claims 1 to 7.

12. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Systems and methods for multipath load balancing

    CN104954275A

  • Data transmission method, node, network manager and system

    CN113472646A

  • Network convergence method and device for networking, equipment and medium

    CN116055382A

  • Path switching method and device, network equipment and network system

    CN116319535A

  • Route adjustment method and apparatus, and electronic device

    CN117081984A