Method and application of hierarchical equal-cost multi-path routing
By obtaining and indexing multi-layer equivalent multi-path group tables and member tables in the network, the hierarchical implementation of equivalent multi-path routing is achieved, which solves the problems of resource waste and performance degradation, and achieves resource conservation and performance improvement.
Patent Information
- Application Number
- CN202111423836.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-26
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2041-11-26
AI Technical Summary
In a hierarchical network, implementing equivalent multipath routing requires a large amount of table entry space, and table entry needs to be refreshed when the route changes, resulting in waste of resources and degradation of performance.
By obtaining the equivalent multipath group table of the first network layer, the equivalent multipath member table of the first network layer is indexed; the equivalent multipath of the second network layer is indexed according to the equivalent multipath member table of the first network layer. A table is grouped to index the equivalent multipath member table of the second network layer; and obtain corresponding information for editing messages based on the equivalent multipath member table of the first network layer and the second network layer, respectively.
It realizes forwarding separation of networks at different levels in the network. Each layer maintains its own equivalent multi-path table entry information. It only needs to update the table entry information at this layer to avoid table brushing operations, save table entry resources and save forwarding bandwidth .
Smart Images

Figure CN116192732B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of communications, and in particular to a method and application for implementing hierarchical equal-cost multi-path routing. Background Art
[0002] In data center networks, layered network technologies such as Vxlan and NVGRE are widely used. In such layered networks, equal-cost multi-path (ECMP) is basically implemented using a one-level ECMP solution, which has significant limitations.
[0003] In the prior art, the equal-cost multi-path routes generated by the Overlay and UnderLay networks in Vxlan are merged and calculated. When the route of any layer of the network changes due to the merged calculation, the associated table entries need to be refreshed, which will cause the ECMP member table entries to become larger, wasting table entry resources.
[0004] The information disclosed in this background technology section is only intended to enhance the understanding of the overall background of the invention and should not be regarded as an acknowledgment or any form of suggestion that the information constitutes the prior art already known to a person skilled in the art. Summary of the invention
[0005] The purpose of the present invention is to provide a method and application for implementing equal-cost multi-path routing in a hierarchical manner, so as to solve the problem that a large amount of table entry space needs to be consumed when implementing equal-cost multi-path routing in a hierarchical network, and the table entries need to be refreshed when the routing changes.
[0006] To achieve the above objective, an embodiment of the present invention provides a method for implementing equal-cost multi-path routing in a hierarchical manner.
[0007] In one or more embodiments of the present invention, the method includes: obtaining an equivalent multipath group table of a first network layer to index an equivalent multipath member table of the first network layer; indexing an equivalent multipath group table of a second network layer according to the equivalent multipath member table of the first network layer to index an equivalent multipath member table of the second network layer; and obtaining corresponding first network layer information and second network layer information for editing messages according to the equivalent multipath member tables of the first network layer and the second network layer, respectively.
[0008] In one or more embodiments of the present invention, obtaining the equivalent multi-path group table of the first network layer to index the equivalent multi-path member table of the first network layer includes: obtaining the equivalent multi-path group table of the first network layer; obtaining the equivalent multi-path member table of the first network layer according to the hash value and the equivalent multi-path group table; and obtaining the index of the first network layer editing table of the message according to the information of the equivalent multi-path member table.
[0009] In one or more embodiments of the present invention, the equivalent multipath group table of the second network layer is indexed according to the equivalent multipath member table of the first network layer to index the equivalent multipath member table of the second network layer, including: judging whether there is equivalent multipath information of the second network layer according to the equivalent multipath member table of the first network layer; if so, obtaining information of the equivalent multipath group table and the equivalent multipath member table of the second network layer; if not, obtaining the export information of the message.
[0010] In one or more embodiments of the present invention, obtaining the equivalent multipath group table and the equivalent multipath member table of the second network layer includes: obtaining the equivalent multipath group table of the second network layer; obtaining the index of the second network layer editing table in the equivalent multipath member table and the export information of the message according to the hash value and the equivalent multipath group table.
[0011] In one or more embodiments of the present invention, the method includes: obtaining information of the equal-cost multi-path member table according to hash%num+base, where num is the number of members in the equal-cost multi-path group table, and base is the starting index of the equal-cost multi-path member table.
[0012] In one or more embodiments of the present invention, corresponding first network layer information and second network layer information for editing messages are obtained according to the equivalent multipath member tables of the first network layer and the second network layer, respectively, including: obtaining the first network layer information for editing messages in the first network layer editing table according to the index of the first network layer editing table; and obtaining the Outer Ethernet Header information of the second network layer for editing messages in the second network layer editing table according to the index of the second network layer editing table.
[0013] In one or more embodiments of the present invention, the first network layer information used to edit the message in the first network layer editing table includes: Inner Ethernet Header information, Vxlan Header information, Outer UDP Header information and Outer IP Header information.
[0014] In another aspect of the present invention, a device for implementing hierarchical equal-cost multi-path routing is provided, which includes an ingress processing engine and an egress processing engine.
[0015] An ingress processing engine is used to obtain an equivalent multi-path group table of a first network layer to index an equivalent multi-path member table of the first network layer, and to index an equivalent multi-path group table of a second network layer according to the equivalent multi-path member table of the first network layer to index the equivalent multi-path member table of the second network layer.
[0016] The export processing engine is used to obtain the corresponding first network layer information and second network layer information for editing the message according to the equal-cost multi-path member table of the first network layer and the second network layer respectively.
[0017] In one or more embodiments of the present invention, the ingress processing engine is also used to: obtain an equivalent multi-path group table of the first network layer; obtain information of an equivalent multi-path member table of the first network layer based on a hash value and information of the equivalent multi-path group table; and obtain an index of a first network layer editing table of the message based on information of the equivalent multi-path member table.
[0018] In one or more embodiments of the present invention, the ingress processing engine is also used to: determine whether there is equivalent multipath information of the second network layer based on the equivalent multipath member table of the first network layer; if so, obtain information on the equivalent multipath group table and the equivalent multipath member table of the second network layer; if not, obtain the exit information of the message.
[0019] In one or more embodiments of the present invention, the ingress processing engine is also used to obtain an equivalent multi-path group table of the second network layer; and obtain the index of the second network layer editing table in the equivalent multi-path member table and the exit information of the message based on the hash value and the information of the equivalent multi-path group table.
[0020] In one or more embodiments of the present invention, the entry processing engine is also used to: obtain information of the equal-cost multi-path member table according to hash%num+base, where num is the number of members in the equal-cost multi-path group table, and base is the starting index of the equal-cost multi-path member table.
[0021] In one or more embodiments of the present invention, the egress processing engine is also used to: obtain the first network layer information for editing the message in the first network layer editing table according to the index of the first network layer editing table; and obtain the OuterEthernet Header information of the second network layer for editing the message in the second network layer editing table according to the index of the second network layer editing table.
[0022] In another aspect of the present invention, an electronic device is provided, comprising: at least one processor; and a memory, wherein the memory stores instructions, and when the instructions are executed by the at least one processor, the at least one processor executes the method for implementing hierarchical equal-cost multi-path routing as described above.
[0023] In another aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for implementing hierarchical equal-cost multi-path routing are implemented.
[0024] Compared with the prior art, the method and application of hierarchical implementation of equal-cost multi-path routing according to the implementation mode of the present invention can hierarchically implement equal-cost multi-path routing through the series relationship of equal-cost multi-path table entries. The forwarding of different layers of the network can be separated, and different network layers can respectively maintain their own equal-cost multi-path table entry information. When the equal-cost multi-path members of any layer change, it is only necessary to update the equal-cost multi-path table entry information of this layer, and there is no need to refresh the table. At the same time, by adopting hierarchical equal-cost multi-path routing, a large amount of table entry resources and forwarding bandwidth can be saved. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1 is a flow chart of a method for implementing hierarchical equal-cost multi-path routing according to an embodiment of the present invention;
[0026] Figure 2 It is a message format diagram of a method for implementing equal-cost multi-path routing in a hierarchical manner according to an embodiment of the present invention;
[0027] Figure 3 is a specific flow chart of a method for implementing hierarchical equal-cost multi-path routing according to an embodiment of the present invention;
[0028] Figure 4 is an exemplary diagram of a method for implementing equal-cost multi-path routing in a hierarchical manner according to an embodiment of the present invention;
[0029] Figure 5 is a structural diagram of a device for implementing hierarchical equal-cost multi-path routing according to an embodiment of the present invention;
[0030] Figure 6 It is a hardware structure diagram of a computing device for implementing hierarchical equal-cost multi-path routing according to an embodiment of the present invention. DETAILED DESCRIPTION
[0031] The specific implementation modes of the present invention are described in detail below in conjunction with the accompanying drawings, but it should be understood that the protection scope of the present invention is not limited by the specific implementation modes.
[0032] Unless explicitly stated otherwise, throughout the specification and claims, the term “comprise” or variations such as “include” or “comprising”, etc., will be understood to include the stated elements or components but not to exclude other elements or components.
[0033] The technical solutions provided by various embodiments of the present invention are described in detail below in conjunction with the accompanying drawings.
[0034] Example 1
[0035] like Figure 1 to Figure 2As shown, a method for implementing equal-cost multi-path routing in a hierarchical manner in one embodiment of the present invention is introduced, and the method includes the following steps.
[0036] In step S101, an equal-cost multi-path group table of a first network layer is obtained to index an equal-cost multi-path member table of the first network layer.
[0037] In this embodiment, the first network layer in the Vxlan network is the Overlay network, and the second network layer is the Underlay network. For example, however, the present invention is not limited to the Overlay network and the Underlay network, and can also be used in tunnel-related technologies such as NVGRE and IPTunnel. The Underlay network is a traditional single-layer network, which is the network of the current data center network basic forwarding architecture. The Overlay network is a virtual network built on the existing physical network, and the upper-layer applications are only related to the virtual network. By deploying the Overlay network, the physical network can be deeply extended to the cloud and virtualization, so that the cloud resource pooling capability can get rid of the many limitations of the physical network, which is the key to realizing cloud-network integration. The Overlay network is also a network, but it is a network built on the Underlay network. The nodes of the Overlay network communicate through virtual or logical links. Each virtual or logical link corresponds to a path (Path) of the Underlay network, which is composed of multiple links connected front and back.
[0038] The message in the inlet processing engine (IPE) can query the InnerIPDA to know that the equal-cost multi-path group number of the Overlay network is 1, and obtain the corresponding equal-cost multi-path group table, which includes the number of members (num) in the equal-cost multi-path group table and the starting index (base) of the equal-cost multi-path member table. The message in the inlet processing engine can also obtain the corresponding hash value, and the information of the equal-cost multi-path member table can be obtained through hash%num+base. The index (overlayEditPtr) of the first-layer Overlay network editing table for editing the message in the egress processing engine (EPE) can be obtained through the equal-cost multi-path member table corresponding to the first network layer.
[0039] In step S102, the equal-cost multi-path group table of the second network layer is indexed according to the equal-cost multi-path member table of the first network layer to index the equal-cost multi-path member table of the second network layer.
[0040] When there is second-layer equal-cost multi-path information (underlay network in this embodiment), obtain the information of the equal-cost multi-path group table and the equal-cost multi-path member table of the second network layer. The specific steps are the same as those for obtaining the information of the equal-cost multi-path group table and the equal-cost multi-path member table of the first network layer, and will not be repeated here. The index (underlayEditPtr) of the second-layer underlay network editing table for editing the message in the egress processing engine (EPE) can be obtained through the equal-cost multi-path member table corresponding to the second network layer.
[0041] In step S103, corresponding first network layer information and second network layer information for editing the message are obtained according to the equal-cost multi-path member tables of the first network layer and the second network layer, respectively.
[0042] After the message carries the index of the first-layer Overlay network editing table and the index of the second-layer Underlay network editing table from the IPE to the EPE, the first network layer editing table is obtained according to the index of the first-layer Overlay network editing table. The Inner Ethernet Header information, Vxlan Header information, Outer UDP Header information and Outer IP Header information used to edit the Vxlan message can be obtained through the first network layer editing table; the Outer Ethernet Header information in the second network layer editing table used to edit the Vxlan message is obtained according to the index of the second-layer Underlay network editing table.
[0043] The Vxlan message format is as follows Figure 2 As shown in the figure. Vxlan Header information is used to define different tenants in the Vxlan network; OuterUDP Header information is the Vxlan header and the original Ethernet frame as UDP data, used to identify the message as Vxlan data; Outer IP Header information is used to encapsulate the outer IP header; Outer Ethernet Header information is the outer Ethernet frame header.
[0044] According to the method and application of hierarchical equal-cost multi-path routing implemented in the embodiment of the present invention, when equal-cost multi-path routing is implemented in both the Overlay network layer and the Underlay network layer, each can maintain its own equal-cost multi-path group table and equal-cost multi-path member table information. When any layer of equal-cost multi-path routing members changes, only the information of the equal-cost multi-path member table of this layer needs to be updated, and the corresponding information for editing the message can be modified without refreshing the table.
[0045] Example 2
[0046] like Figure 3 to Figure 4As shown, a method for implementing equal-cost multi-path routing in a hierarchical manner in one embodiment of the present invention is introduced, and the method includes the following steps.
[0047] In step S201, an equal-cost multi-path group table of a first network layer is obtained, and information of an equal-cost multi-path member table of the first network layer is obtained according to information of the equal-cost multi-path group table and a hash value.
[0048] The message can obtain the equivalent multi-path group number corresponding to the first network layer through the Inner IPDA query at the ingress processing engine (IPE), and obtain the corresponding equivalent multi-path group table based on the equivalent multi-path group number. The equivalent multi-path group table includes the number of members (num) in the equivalent multi-path group table and the starting index (base) of the equivalent multi-path member table. The message can also obtain the corresponding hash value at the ingress processing engine, and the corresponding equivalent multi-path member table information can be obtained through hash%num+base.
[0049] In step S202, the index of the first network layer editing table of the message is obtained according to the information of the equal-cost multi-path member table.
[0050] The equivalent multi-path member table includes: overlayEditPtr represents the index of the editing table of the first network layer, which will be transmitted from the ingress processing engine to the egress processing engine. According to the index of the first network layer editing table, the corresponding first network layer editing table can be obtained in the egress processing engine, and the network editing table can obtain information used to edit the message.
[0051] In step S203, it is determined whether there is second layer equal-cost multi-path information according to the equal-cost multi-path member table.
[0052] The equal-cost multi-path member table includes: ecmp_en indicates whether there is path information of the lower-layer equal-cost multi-path routing. When ecmp_en=1, it indicates that there is path information of the lower-layer equal-cost multi-path routing. Otherwise, ecmp_en=0 indicates that there is no path information of the lower-layer equal-cost multi-path routing. groupId / port indicates the equal-cost multi-path group table information of the lower-layer network or the egress information of the message. Specifically, when ecmp_en=1, the equal-cost multi-path group number (groupId) of the lower-layer network can be obtained, which is used to obtain the equal-cost multi-path group table of the layer network. When ecmp_en=0, the egress information (port) of the message can be obtained.
[0053] In step S204, information of an equal-cost multi-path group table and an equal-cost multi-path member table of the second network layer is obtained.
[0054] According to ecmp_en=1 and groupId in the equal-cost multi-path member table of the first layer, the equal-cost multi-path group table corresponding to the second network layer can be obtained, and the information of the equal-cost multi-path member table corresponding to the second network layer can be obtained through hash%num+base.
[0055] The equal-cost multi-path member table also includes: underLayEditPtr is used for the index of the editing table of the second network layer. The index is also transmitted from the ingress processing engine to the egress processing engine. The information used to edit the message in the second network layer editing table is obtained according to the index of the second network layer editing table.
[0056] In step S205, first network layer information and second network layer information for editing the message are obtained according to the information of the equal-cost multi-path group table and the equal-cost multi-path member table.
[0057] After the message carries the index of the first layer Overlay network editing table and the index of the second layer Underlay network editing table from IPE to EPE, the first network layer editing table is obtained according to the index of the first layer Overlay network editing table. The first network layer editing table includes: L2EditPtr index, Fid index and L3EditPtr index. Specifically, L2ditPtr indexes the Innner Ethernet Header information in the DsL2Edit table for editing the inner layer of the message; Fid indexes the Vxlan Header information in the DsVxlanEdit table for editing the message; L3EditPtr indexes the Outer IP / UDPHeader information in the DsL3Edit table for editing the message. The Outer Ethernet Header information in the second network layer editing table for editing the Vxlan message is obtained according to the index of the second layer Underlay network editing table.
[0058] by Figure 4 For example, the message obtains the equal-cost multipath group number GroupId=1 of the first-layer Overlay network through the Inner IPDA query in IPE, and obtains the equal-cost multipath group table. The message obtains the information of the equal-cost multipath member table through the hash%num+base index based on the hash value obtained in IPE, obtains the overlayEditPtr of the message edited in EPE according to the equal-cost multipath member table, and continues to index the equal-cost multipath group table information of the next layer Underlay network according to ecmp_en=1 and groupId=100 in the equal-cost multipath member table, obtains the information of the equal-cost multipath member table of the Underlay network through the hash%num+base index, and finally obtains the export information and underLayEditPtr of the message.
[0059] After the message carries overlayEditPtr and underLayEditPtr from IPE to EPE, the DsOverlayEdit table is obtained according to the overlayEditPtr index, and the DsL2Edit table, DsVxlanEdit table and DsL3Edit table are further obtained. The Innner Ethernet Header, VxlanHeader, Outer UDP Header and Outer IP Header information of the Vxlan message are edited according to the relevant information obtained; the OuterEthernet Header information of the Vxlan message is edited according to the underlayEditPtr index of the DsUnderlayEdit table.
[0060] like Figure 5 As shown, a device for implementing equal-cost multi-path routing in a hierarchical manner according to a specific embodiment of the present invention is introduced.
[0061] In the embodiment of the present invention, the apparatus for implementing hierarchical equal-cost multi-path routing includes an ingress processing engine 501 and an egress processing engine 502 .
[0062] The ingress processing engine 501 is used to obtain the equivalent multi-path group table of the first network layer to index the equivalent multi-path member table of the first network layer, and to index the equivalent multi-path group table of the second network layer according to the equivalent multi-path member table of the first network layer to index the equivalent multi-path member table of the second network layer.
[0063] The egress processing engine 502 is used to obtain corresponding first network layer information and second network layer information for editing the message according to the equal-cost multi-path member tables of the first network layer and the second network layer, respectively.
[0064] The ingress processing engine 501 is also used to: obtain an equivalent-cost multi-path group table of the first network layer; obtain information of an equivalent-cost multi-path member table of the first network layer based on a hash value and information of the equivalent-cost multi-path group table; and obtain an index of the first network layer editing table of the message based on information of the equivalent-cost multi-path member table.
[0065] The ingress processing engine 501 is also used to: determine whether there is equivalent multipath information of the second network layer based on the equivalent multipath member table of the first network layer; if so, obtain information on the equivalent multipath group table and the equivalent multipath member table of the second network layer; if not, obtain the egress information of the message.
[0066] The ingress processing engine 501 is also used to obtain the equal-cost multi-path group table of the second network layer; and obtain the index of the second network layer editing table in the equal-cost multi-path member table and the egress information of the message according to the hash value and the information of the equal-cost multi-path group table.
[0067] The ingress processing engine 501 is further used to obtain information of the equal-cost multi-path member table according to hash%num+base, where num is the number of members in the equal-cost multi-path group table and base is the starting index of the equal-cost multi-path member table.
[0068] The egress processing engine 502 is also used to: obtain the first network layer information used to edit the message in the first network layer editing table according to the index of the first network layer editing table; and obtain the Outer Ethernet Header information of the second network layer used to edit the message in the second network layer editing table according to the index of the second network layer editing table.
[0069] Figure 6 FIG. 6 shows a hardware structure diagram of a computing device 60 for implementing hierarchical equal-cost multi-path routing according to an embodiment of the present specification. Figure 6 As shown, the computing device 60 may include at least one processor 601, a memory 602 (e.g., a non-volatile memory), a memory 603, and a communication interface 604, and the at least one processor 601, the memory 602, the memory 603, and the communication interface 604 are connected together via a bus 605. The at least one processor 601 executes at least one computer-readable instruction stored or encoded in the memory 602.
[0070] It should be understood that the computer executable instructions stored in the memory 602, when executed, cause at least one processor 601 to perform the above combined operations in various embodiments of this specification. Figure 1-6 Describes the various operations and functions.
[0071] In the embodiments of the present specification, the computing device 60 may include, but is not limited to, a personal computer, a server computer, a workstation, a desktop computer, a laptop computer, a notebook computer, a mobile computing device, a smart phone, a tablet computer, a cellular phone, a personal digital assistant (PDA), a handheld device, a messaging device, a wearable computing device, a consumer electronic device, and the like.
[0072] According to one embodiment, a program product such as a machine-readable medium is provided. The machine-readable medium may have instructions (i.e., the above-mentioned elements implemented in the form of software), which, when executed by a machine, causes the machine to perform the above-mentioned combination of various embodiments of this specification. Figure 1-6 Specifically, a system or device equipped with a readable storage medium may be provided, on which a software program code implementing the functions of any of the above-mentioned embodiments is stored, and a computer or processor of the system or device reads and executes the instructions stored in the readable storage medium.
[0073] According to the method and application of hierarchical equal-cost multi-path routing implemented in the embodiment of the present invention, it is possible to hierarchically implement equal-cost multi-path routing through the series relationship of equal-cost multi-path table items, and forwarding of different layers of the network can be separated. Different network layers can respectively maintain their own equal-cost multi-path table item information. When any layer of equal-cost multi-path members changes, it is only necessary to update the equal-cost multi-path table item information of this layer without refreshing the table. At the same time, by adopting hierarchical equal-cost multi-path routing, a large amount of table item resources and forwarding bandwidth can be saved.
[0074] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0075] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0076] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0077] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1The steps for the functions specified in one or more boxes.
[0078] The foregoing description of specific exemplary embodiments of the present invention is for the purpose of illustration and demonstration. These descriptions are not intended to limit the present invention to the precise form disclosed, and it is clear that many changes and variations can be made based on the above teachings. The purpose of selecting and describing the exemplary embodiments is to explain the specific principles of the present invention and its practical application, so that those skilled in the art can realize and utilize various different exemplary embodiments of the present invention and various different selections and changes. The scope of the present invention is intended to be limited by the claims and their equivalents.
Claims
1. A method for implementing hierarchical equal-cost multi-path routing, characterized in that: The method comprises: Obtaining an equal-cost multi-path group table of the first network layer at the ingress processing engine IPE to index an equal-cost multi-path member table of the first network layer, and then obtaining an index of the first network layer editing table; Indexing the equal-cost multi-path group table of the second network layer according to the equal-cost multi-path member table of the first network layer to index the equal-cost multi-path member table of the second network layer, thereby obtaining an index of the second network layer editing table; and The first network layer information and the second network layer information corresponding to the message editing are obtained according to the equal-cost multi-path member tables of the first network layer and the second network layer, respectively, wherein: Acquiring corresponding first network layer information and second network layer information for editing a message according to the equal-cost multi-path member tables of the first network layer and the second network layer, respectively, specifically includes: The egress processing engine EPE obtains the first network layer information for editing the message in the first network layer editing table according to the index of the first network layer editing table; and The second network layer information for editing the message in the second network layer editing table is obtained according to the index of the second network layer editing table.
2. The method for implementing hierarchical equal-cost multi-path routing as claimed in claim 1, characterized in that: The obtaining of the equal-cost multi-path group table of the first network layer to index the equal-cost multi-path member table of the first network layer includes: Obtain an equal-cost multi-path group table of a first network layer; Obtaining an equal-cost multi-path member table of the first network layer according to the hash value and the equal-cost multi-path group table; The index of the first network layer editing table of the message is obtained according to the information of the equal-cost multi-path member table.
3. The method for implementing hierarchical equal-cost multi-path routing as claimed in claim 2, characterized in that: Indexing the equal-cost multi-path group table of the second network layer according to the equal-cost multi-path member table of the first network layer to index the equal-cost multi-path member table of the second network layer includes: Determine whether there is equivalent-cost multi-path information of the second network layer according to the equivalent-cost multi-path member table of the first network layer; if so, Obtain information about the equal-cost multi-path group table and the equal-cost multi-path member table of the second network layer; if not, Obtain the egress information of the message.
4. The method for implementing hierarchical equal-cost multi-path routing as claimed in claim 3, characterized in that: The obtaining of the equal-cost multi-path group table and the equal-cost multi-path member table of the second network layer includes: Obtain an equal-cost multi-path group table of the second network layer; The index of the second network layer editing table in the equal-cost multi-path member table and the egress information of the message are obtained according to the hash value and the equal-cost multi-path group table.
5. The method for implementing hierarchical equal-cost multi-path routing as claimed in claim 2 or 4, characterized in that: The method comprises: The information of the equal-cost multi-path member table is obtained according to hash%num+base, where num is the number of members in the equal-cost multi-path group table, and base is the starting index of the equal-cost multi-path member table.
6. The method for implementing hierarchical equal-cost multi-path routing as claimed in claim 1, characterized in that: The second network layer information used to edit the message in the second network layer editing table includes Outer Ethernet Header information, and the first network layer information used to edit the message in the first network layer editing table includes: Inner Ethernet Header information, Vxlan Header information, Outer UDP Header information and Outer IP Header information.
7. A device for implementing hierarchical equal-cost multi-path routing, characterized in that: The device comprises: an ingress processing engine, configured to obtain an equal-cost multi-path group table of a first network layer to index an equal-cost multi-path member table of the first network layer, and to index an equal-cost multi-path group table of a second network layer according to the equal-cost multi-path member table of the first network layer to index an equal-cost multi-path member table of the second network layer; and An export processing engine is used to obtain corresponding first network layer information and second network layer information for editing messages according to the equivalent multi-path member tables of the first network layer and the second network layer, respectively, wherein the corresponding first network layer information and second network layer information for editing messages according to the equivalent multi-path member tables of the first network layer and the second network layer, respectively, specifically includes: obtaining the first network layer information for editing messages in the first network layer editing table according to the index of the first network layer editing table in the export processing engine; and obtaining the second network layer information for editing messages in the second network layer editing table according to the index of the second network layer editing table.
8. An electronic device, characterized in that: include: at least one processor; as well as A memory storing instructions, which, when executed by the at least one processor, causes the at least one processor to execute the method for implementing hierarchical equal-cost multi-path routing as claimed in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for hierarchical equal-cost multi-path routing as claimed in any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Path Resolution for Hierarchical Load Distribution
US20140293786A1