WO2023050818A1 - 数据转发方法、系统、电子设备和存储介质 - Google Patents

数据转发方法、系统、电子设备和存储介质 Download PDF

Info

Publication number
WO2023050818A1
WO2023050818A1 PCT/CN2022/091545 CN2022091545W WO2023050818A1 WO 2023050818 A1 WO2023050818 A1 WO 2023050818A1 CN 2022091545 W CN2022091545 W CN 2022091545W WO 2023050818 A1 WO2023050818 A1 WO 2023050818A1
Authority
WO
WIPO (PCT)
Prior art keywords
forwarding
policy
group
data
management device
Prior art date
Application number
PCT/CN2022/091545
Other languages
English (en)
French (fr)
Inventor
王前宇
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2023050818A1 publication Critical patent/WO2023050818A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/12Avoiding congestion; Recovering from congestion
    • H04L47/125Avoiding congestion; Recovering from congestion by balancing the load, e.g. traffic engineering

Definitions

  • the embodiments of the present application relate to the communication field, and in particular, to a data forwarding method, system, electronic device, and storage medium.
  • 5G 5th Generation
  • the 5G network will use network slicing technology to divide a physical infrastructure into multiple virtual networks, so that each slice provides different and unique connections under the same infrastructure.
  • Most virtual networks use overlay network technology to quickly provide different requirements. For large-scale networking scenarios, different traffic from the same node can choose different paths to flow to the destination, preventing single-path load overload, while providing high reliability and providing high-performance and reliable network services for various applications, so overlay scenarios also need Equal Cost Multi-path (ECMP for short) technology.
  • ECMP Equal Cost Multi-path
  • the routing strategy enables the local priority strategy, that is, the local virtual member of the ECMP group is preferentially selected for data forwarding, so that when the source address and destination address of the packet are located on the same node When it is up, the load cannot be shared to the ECMP members of other nodes, and the network data forwarding performance is low.
  • the embodiment of the present application provides a data forwarding method, which is applied to a forwarding device in an overlay network.
  • the forwarding device communicates with a management device.
  • the management device is used to manage at least one forwarding device.
  • Each forwarding device includes multiple virtual members.
  • the method Including: receiving the forwarding strategy distributed by the management device; wherein, the forwarding strategy includes: when the forwarding device is the first-hop device, select the next hop in the first group; The next hop is selected in the second group, the first group includes all virtual members of the ECMP group of the forwarding device, and the second group includes only the local virtual members of the ECMP group; data forwarding is performed according to the forwarding strategy.
  • the embodiment of the present application also provides a data forwarding method, which is applied to a management device in an overlay network.
  • the management device communicates with at least one forwarding device, and the management device is used to manage at least one forwarding device.
  • Each forwarding device contains multiple virtual member, the method includes: obtaining the routing information of each forwarding device; generating the forwarding policy of each forwarding device according to the routing information; distributing the forwarding policy of each forwarding device to each forwarding device for each forwarding device to receive the forwarding policy distributed by the management device , and perform data forwarding according to the forwarding strategy; wherein, the forwarding strategy includes: when the forwarding device is the first-hop device, select the next hop in the first group; The next hop is selected in two groups, the first group includes all virtual members of the ECMP group of the forwarding device, and the second group includes only the local virtual members of the ECMP group.
  • the embodiment of the present application also provides a data forwarding system, including a forwarding device and a management device applied in an overlay network; the management device communicates with at least one forwarding device, and the management device is used to manage at least one forwarding device, and each forwarding device Contains multiple virtual members; among them, the management device is used to obtain the routing information of each forwarding device; generate the forwarding strategy of each forwarding device according to the routing information; distribute the forwarding strategy of each forwarding device to each forwarding device for each forwarding device
  • the device receives the forwarding strategy distributed by the management device, and forwards data according to the forwarding strategy; the forwarding strategy includes: when the forwarding device is the first-hop device, select the next hop in the first group; when the forwarding device is a non-first-hop device In the case of , select the next hop in the second packet, the first packet contains all virtual members of the ECMP packet of the forwarding device, and the second packet only contains the local virtual member of the ECMP packet; the forwarding device is used to receive Manage
  • the embodiment of the present application also provides an electronic device, including: at least one processor; and a memory connected to the at least one processor in communication; wherein, the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by at least one processor. Executed by a processor, so that at least one processor can execute the above data forwarding method.
  • An embodiment of the present application also provides a computer-readable storage medium storing a computer program, and implementing the above data forwarding method when the computer program is executed by a processor.
  • FIG. 1 is a schematic flow diagram of a data forwarding method applied to a forwarding device provided by an embodiment of the present application
  • FIG. 2 is a first schematic diagram of a forwarding path provided by an embodiment of the present application
  • FIG. 3 is a second schematic diagram of a forwarding path provided by an embodiment of the present application.
  • FIG. 4 is a third schematic diagram of forwarding paths provided by an embodiment of the present application.
  • Fig. 5 is a schematic diagram 4 of a forwarding path provided by an embodiment of the present application.
  • FIG. 6 is a schematic flowchart of a data forwarding method provided by an embodiment of the present application.
  • FIG. 7 is a schematic diagram of routing information collection provided by an embodiment of the present application.
  • FIG. 8 is a schematic diagram of a routing strategy provided by an embodiment of the present application.
  • FIG. 9 is a schematic flowchart of a data forwarding method applied to a management device provided by an embodiment of the present application.
  • FIG. 10 is a schematic diagram of a data forwarding system provided by an embodiment of the present application.
  • Fig. 11 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • the main purpose of the embodiments of the present application is to provide a data forwarding method, system, electronic device, and storage medium, so as to improve network data forwarding performance.
  • the embodiment of the present application relates to a data forwarding method, as shown in Figure 1, comprising the following steps:
  • Step 101 receiving the forwarding strategy distributed by the management device; wherein, the forwarding strategy includes: if the forwarding device is the first-hop device, select the next hop in the first group; The next hop is selected in the second group, the first group contains all virtual members of the ECMP group of the forwarding device, and the second group only contains the local virtual members of the ECMP group;
  • Step 102 perform data forwarding according to the forwarding policy.
  • the data forwarding method of this embodiment is applied to a forwarding device in an overlay network, and the forwarding device is communicatively connected to a management device, and the management device is used to manage at least one forwarding device, and each forwarding device includes multiple virtual members.
  • Overlay network also known as overlay network, overlay network
  • overlay network simply understands that a logical network is built on top of a physical network.
  • VXLAN Virtual eXtensible Local Area Network
  • NVO3 Network Virtualization over Layer 3
  • MAC-in-UDP packet encapsulation mode of L2 over L4
  • encapsulating Layer 2 packets with Layer 3 protocols can realize the expansion of Layer 2 networks within the scope of Layer 3, and at the same time meet the needs of large Layer 2 virtual migration and multi-tenancy in the data center.
  • NVO3 is a general term for technologies that build virtual networks based on a three-layer IP overlay network
  • VXLAN is just one of the NVO3 technologies.
  • the forwarding device in this embodiment may be a VXLAN Tunnel Endpoints (VXLAN Tunnel Endpoints, referred to as "VTEP”) device
  • the VTEP device may be a switch, or the server where the virtual machine is located
  • the management device may be a management device in the network
  • VTEP equipment or cloud management system such as the neutron component of OPENSTACK
  • a virtual network controller such as a software-defined network (Software Defined Network, referred to as "SDN").
  • SDN Software Defined Network
  • the 5G network will use network slicing technology to divide a physical infrastructure into multiple virtual networks, so that each slice provides different and unique connections under the same infrastructure. To achieve this flexibility, each slice must be able to access different types of resources, whether physical or virtual, such as virtualized network functions (Virtualized Network Function, referred to as "VNF"), so 5G through Network control can be programmed to revolutionize the architecture of the network. Network control is used in open software systems to virtualize the actual physical network. In terms of implementation, most virtual networks use overlay technology to quickly provide different requirements. For large-scale networking scenarios, different traffic from the same node can choose different paths to flow to the destination, preventing single-path load overload, while providing high reliability and providing high-performance and reliable network services for various applications, so overlay scenarios also need ECMP technology.
  • VNF Virtualized Network Function
  • each VTEP device must maintain the Media Access Control (MAC) and Address Resolution Protocol ( Address Resolution Protocol, referred to as "ARP") table, for example, there are 4 virtual members on the VTEP device, the first member vni1, the second member vni2, the third member vni3, and the fourth member vni4, when forwarding, you can select it on this node Specific members of the ECMP.
  • the asymmetric routing method is that each vtep needs to maintain the ARP and MAC address tables of all vnis, even if there is no vni of the local host. This requires ARP and MAC tables with a large capacity, resulting in waste of resources, as shown in Figure 2.
  • each vtep optimizes the ARP and MAC address tables, and each router has an L3 vni.
  • L3 vni the number of ECMP groups.
  • VTEP1 may select ECMP group members on VTEP2 as the next hop.
  • the device may choose the group members on vtep1 as the next hop, thus causing a loop.
  • the policy of local priority is generally selected, that is, if there is a directly connected ECMP group on the local VTEP device, the ECMP group on the local device is given priority.
  • the local priority policy is enabled, when the source and destination are on the same node, the load cannot be shared to the ECMP members of other nodes, resulting in uneven traffic.
  • the local ECMP next-hop member is always selected and cannot be selected. Another next hop in 3.
  • the next hop is selected among all the virtual members of the ECMP group. Even when the source address and destination address of the message are on the same node, the data forwarding traffic can be shared to other nodes, thereby balancing the data forwarding traffic and improving the network performance.
  • the response speed and overall performance enable the network to achieve elastic service scaling.
  • the forwarding device is the first-hop device, select the next hop in the first group, and if the forwarding device is a non-first-hop device, select the next hop in the second group, and use this strategy for data forwarding
  • the performance of network data forwarding can be improved.
  • the forwarding device receives the forwarding strategy distributed by the management device.
  • the forwarding strategy includes: if the forwarding device is the first-hop device, select the next hop in the first group; , select the next hop in the second packet, the first packet includes all virtual members of the ECMP packet of the forwarding device, and the second packet includes only the local virtual members of the ECMP packet.
  • the forwarding policy is configured by the management device, and the management device generates the forwarding policy of each forwarding device according to the routing information by acquiring the routing information of each forwarding device.
  • the forwarding device may select one or more devices in the first group or the second group as next-hop devices.
  • the forwarding device selects the next hop, specifically: selects all virtual members in the group as next hop devices, and performs load sharing among all virtual members.
  • all virtual members in the group are selected as next-hop devices, and load sharing is performed among all virtual members, thereby performing traffic sharing among all virtual members of the entire group, and further improving network data forwarding performance.
  • step 102 the forwarding device forwards data according to the forwarding policy.
  • the forwarding device judges whether the device is the first-hop device after receiving the message to be forwarded according to the forwarding policy. If the device is the first-hop device, it selects the next hop from all virtual members in the ECMP group. If the device is not the first-hop device, the next hop is selected from the second group, that is, the local virtual members of the ECMP group.
  • the forwarding device generates a forwarding rule according to the forwarding policy and the type of the forwarding device, and forwards data according to the forwarding rule.
  • the forwarding rules include a general virtual routing table, a local virtual routing table, and a flow table.
  • the forwarding device generates forwarding rules according to the forwarding policy in the following ways: if the forwarding device is an openflow device, generate a flow table according to the forwarding policy; if the forwarding device is an EVPN device, set a general virtual route according to the forwarding policy table and the local virtual routing table.
  • a flow table is generated according to the forwarding strategy
  • the forwarding device is an EVPN (Ethernet VPN) device
  • the general virtual routing table and the local routing table are set according to the forwarding strategy
  • the virtual routing table can change the forwarding rules of openflow devices and EVPN devices to improve network data forwarding performance.
  • the forwarding device after receiving the forwarding policy distributed by the management device, the forwarding device also receives the updated forwarding policy distributed by the management device, and performs data forwarding according to the updated forwarding policy.
  • the new forwarding strategy by receiving the updated forwarding strategy distributed by the management device, data is forwarded according to the updated forwarding strategy, and the new forwarding strategy can be used for data forwarding, so as to improve network data forwarding performance.
  • an ECMP management module and an ECMP forwarding policy module in the management device and an ECMP forwarding execution module in the forwarding device, as shown in Figure 6, wherein the ECMP management module, the server end, is used to collect the information of each VTEP forwarding device Routing information forms a global ECMP group, and information such as the attributes, locations, and topological relationships of each group member is used to guide the subsequent ECMP forwarding policy module to complete policy generation and synchronize to the corresponding device.
  • the ECMP forwarding policy module on the agent side, is used to convert the information obtained from the ECMP management module into the ECMP forwarding policy of the device, and calculate the ECMP forwarding policy of each VTEP device according to the unknown members of the ECMP group.
  • the vswitch the vswitch flow table can be delivered , select ECMP member ports for different ingress ports of packets.
  • the ECMP forwarding execution module, the virtual forwarding device vswitch, or the hardware forwarding device switch are used to generate forwarding rules on each VTEP device using the ECMP forwarding policy.
  • the VTEP device may be an openflow device or an EVPN device, so it can be forwarded according to the policy.
  • data forwarding includes the following processes:
  • the ECMP management module collects routing information in the network by interacting with VTEP devices or cloud management systems (such as the neutron component of OPENSTACK) or virtual network controllers (such as SDN), and forms and maintains ECMP groups and member information tables.
  • VTEP devices or cloud management systems such as the neutron component of OPENSTACK
  • virtual network controllers such as SDN
  • the routing information collected by the ECMP management module and the next hop process are as follows: the ECMP management module obtains all routing entries of each logical routing instance (vrouter), and the key information of each routing entry includes: vrouter identifier (RD or L3VNI), routing Destination network segment (network prefix), next hop (in the case of a routing network element, the next hop may be a virtual machine address or port); the ECMP management module extracts the ECMP group member information table (with A group of routes with the same vrouter ID (RD or L3VNI), the routing destination network segment (network prefix), key information includes: ECMP group ID, belonging vrouter ID (RD or L3VNI), next hop member (specifically may include next hop address or port information), the VTEP device where the member resides.
  • RD or L3VNI vrouter identifier
  • routing Destination network segment network prefix
  • next hop in the case of a routing network element, the next hop may be a virtual machine address or port
  • the ECMP forwarding policy module obtains ECMP information from the management module and converts it into a forwarding policy of the device, as shown in FIG. 8 .
  • the forwarding execution module converts the ECMP forwarding policy into the forwarding rule of the VTEP device. If the VTEP device is an openflow forwarding device, the forwarding rule is converted to an openflow flow table. If the VTEP device is an EVPN forwarding device, the forwarding rule is converted to a Border Gateway Protocol (Boarder Gateway Protocol, "BGP") message.
  • Border Gateway Protocol Border Gateway Protocol
  • flow table entries are received through the openflow protocol, and ECMP is generally implemented using the group table defined in the openflow protocol.
  • the group table in the protocol is defined as follows:
  • OFPGT_ALL 0, /*All(multicast/broadcast)group.*/
  • OFPGT_SELECT 1, /*Select group.*/
  • OFPGT_INDIRECT 2, /*Indirect group.*/
  • OFPGT_FF 3, /*Fast failover group.*/
  • OFPGT_CONDITION 16, /*conditional group.*/
  • the bucket table of the Openflow protocol also needs to add a new type corresponding to the group table of the conditional type.
  • the value here is also 16, and the definition is as follows:
  • OFPGBPT_WEIGHT 0, /*Select groups only.*/
  • OFPGBPT_WATCH_PORT 1, /*Fast failover groups only.*/
  • OFPGBPT_WATCH_GROUP 2, /*Fast failover groups only.*/
  • OFPGBPT_COND_GROUP 16, /*Conditional groups only.*/
  • OFPGBPT_EXPERIMENTER 0xFFFF, /*Experimenter defined.*/
  • the structure of the new bucket type is as follows:
  • condition_key can be extended and defined, currently defined as:
  • condition_type can be extended and defined, currently defined as:
  • conditional_val is the matching specific value, currently only supports numeric values.
  • conditional_key If conditional_key is set, it will participate in load sharing only when conditional_key and conditional_val meet the definition of condition_type; if it is not set by default, it means to participate in load sharing calculation.
  • OFPGFC_CONDITIONAL 1 ⁇ 7, /*Support conditional groups*/.
  • OFPGFC_SELECT_WEIGHT 1 ⁇ 0, /*Support weight for select groups*/
  • OFPGFC_SELECT_LIVENESS 1 ⁇ 1, /*Support liveness for select groups*/
  • OFPGFC_CHAINING 1 ⁇ 2, /*Support chaining groups*/
  • OFPGFC_CHAINING_CHECKS 1 ⁇ 3, /*Check chaining for loops and delete*/
  • OFPGFC_CONDITIONAL 1 ⁇ 7, /*Support conditional groups*/
  • the forwarding policy module determines to generate forwarding rules according to condition according to the group type reported by the VTEP device.
  • the forwarding execution module tracks the group information of the openflow flow table issued by the forwarding rule vtep1 as follows:
  • the forwarding execution module tracks the group information of the openflow flow table issued by the forwarding rule vtep2 as follows:
  • VTEP1 After VTEP1 receives the message sent by VNF13, it acts according to the message flow table, and first saves the vni of the current message in the metadata field, because the message sent by VNF13 is not a vxlan message and has no vni information , the metadata is 0.
  • the group action When executing the group action, first check whether the metadata is equal to L3 vni 1. If they are equal, only the actions of bucket2 can be executed; if they are not equal, both bucket1 and bucket2 can be executed, and choose one according to the original bucket.
  • the VTEP2 node After the VTEP2 node receives the message, because it is a vxlan message, it saves the metadata as the vni number, that is, L3 vni 1. When executing the group action, because the metadata is equal to L3 vni1, only bucket 2 is optional, so it can only execute the action of selecting bucket 2. Send the packet to the next hop of VNF21.
  • VTEP devices For EVPN devices, EVPN VTEP devices BGP exchange forwarding rules, VTEP devices need to implement the following functions: VTEP devices group IP-VRF tables to form local IP-VRF tables (that is, local virtual routing tables) and general IP-VRF tables ( i.e. generic virtual routing table). The VTEP device maintains the local IP-VRF table and the general IP-VRF table through the BGP protocol. When forwarding L3 packets, the VTEP device determines whether to check the local IP-VRF table or the general IP-VRF table according to the destination mac.
  • IP-VRF tables that is, local virtual routing tables
  • general IP-VRF tables i.e. generic virtual routing table
  • VTEP device creates two tables of local IP-VRF table and general IP-VRF table for each router-id.
  • the new matching field in the L2 forwarding table of the VTEP router is the router-mac table, and the action is to enter the local IP-VRF table to check the L3 forwarding rules.
  • the forwarding policy module sends the new RT-5 route notification of the BGP neighbor to the VTEP device.
  • the VTEP device takes out the routing entry, and after synthesizing the route, checks whether the next-hop address is in the arp table learned locally or in the arp table notified by RT-2.
  • the route will only be saved in the local RT-5 routing table, and will not be added to the local IP-VRF table and general IP-VRF; if the next-hop address is in the arp table advertised by RT-2, the Save the route to the local RT-5 routing table and then add it to the general IP-VRF; if the next-hop address is in the locally learned arp table, save the route to the local RT-5 routing table and add the route Add it to the general IP-VRF and local IP-VRF tables.
  • the VTEP device receives the RT-2 route announcement from the remote BGP neighbor.
  • the advertised ip address is the next hop of an RT-5 route synthesis route, it will save it in the arp table and check whether the route is in the general IP- In the VRF table, if not, add the route to the general IP-VRF.
  • the VTEP device learns ARP locally. If the ip address is the next hop of a synthetic route in the RT-5 routing table, it will be saved to the arp table normally and check whether the route is in the general IP-VRF. Add the route to the general IP-VRF, check whether the route is in the local IP-VRF, if not, add the route to the local IP-VRF.
  • the processing of RT-5 route deletion notification and ARP aging event is to delete the corresponding next hop record from the above table.
  • the packet forwarding traffic of the EVPN device is as follows. After the VTEP device receives the service packet, it first checks the L2 forwarding table. If the destination mac is the gateway mac, it enters the general IP-VRF table and applies ECMP rules in the general IP-VRF table. ; If the destination mac is router-mac, enter the local IP-VRF table and apply ECMP rules in the local IP-VRF table.
  • each ECMP group member is collected and maintained by the management device, and the ECMP group of each VTEP device is managed according to the topological relationship.
  • the same ECMP group is split into the following two on each VTEP device Group: A group that includes all group members, and a group that is directly connected to the VTEP device. Combine the two ECMP groups split from each VTEP device to calculate the forwarding policy of each VTEP device. Each VTEP device converts the ECMP forwarding policy of the device into a forwarding rule for traffic forwarding.
  • the traffic is load-balanced among all ECMP group members of the first-hop device, and the route is selected evenly; the traffic is load-balanced among the group members directly connected to the VTEP device on the non-first-hop device; thus avoiding the non-first-hop device from distributing packets Sending to other VTEP devices causes a loop, and at the same time avoids the problem of uneven load sharing under the above-mentioned local priority policy.
  • the data forwarding method of this embodiment is applied to the management device in the overlay network, the management device communicates with at least one forwarding device, the management device is used to manage at least one forwarding device, and each forwarding device includes multiple virtual members, as shown in Figure 9 shown, including:
  • Step 901 obtaining routing information of each forwarding device
  • Step 902 generating a forwarding strategy for each forwarding device according to the routing information
  • Step 903 distribute the forwarding policy of each forwarding device to each forwarding device, for each forwarding device to receive the forwarding policy distributed by the management device, and perform data forwarding according to the forwarding policy;
  • the forwarding strategy includes: when the forwarding device is the first-hop device, select the next hop in the first group;
  • the packet contains all virtual members of the equal-cost multipath routing ECMP packet of the forwarding device, and the second packet contains only the local virtual members of the ECMP packet.
  • the management device updates the routing information after the network topology changes; and updates the forwarding strategy of each forwarding device according to the updated routing information;
  • the updated forwarding policy of each forwarding device is distributed to each forwarding device.
  • this embodiment corresponds to the above-mentioned embodiments, this embodiment can be implemented in cooperation with the above-mentioned embodiments.
  • the relevant technical details mentioned in the above embodiments are still valid in this embodiment, and the technical effects that can be achieved in the above embodiments can also be achieved in this embodiment, and in order to reduce repetition, details are not repeated here.
  • the relevant technical details mentioned in this embodiment can also be applied in the above embodiments.
  • the embodiment of this application relates to a data forwarding system, as shown in FIG. 10 , including: a forwarding device 1001 and a management device 1002 in an overlay network; the management device 1002 communicates with at least one forwarding device 1001, and the management device 1002 is used to manage At least one forwarding device 1001, each forwarding device 1001 includes a plurality of virtual members;
  • the management device 1002 is used to obtain the routing information of each forwarding device 1001; generate the forwarding strategy of each forwarding device 1001 according to the routing information; distribute the forwarding strategy of each forwarding device 1001 to each forwarding device 1001 for each forwarding device 1001 receives the forwarding strategy distributed by the management device 1002, and performs data forwarding according to the forwarding strategy;
  • the forwarding strategy includes: when the forwarding device 1001 is the first-hop device, select the next hop in the first packet, and when the forwarding device 1001 is a non- In the case of the first-hop device, select the next hop in the second group, the first group includes all virtual members of the ECMP group of the forwarding device 1001, and the second group only includes the local virtual members of the ECMP group;
  • the forwarding device 1001 is configured to receive the forwarding strategy distributed by the management device 1002; and forward data according to the forwarding strategy.
  • the data forwarding according to the forwarding policy includes: generating a forwarding rule according to the forwarding policy and the type of the forwarding device 1001; and forwarding the data according to the forwarding rule.
  • the forwarding rules include a general virtual routing table, a local virtual routing table, and a flow table; generating a forwarding rule according to a forwarding strategy includes: when the forwarding device 1001 is an openflow device, generating a flow table according to the forwarding strategy ; In the case that the forwarding device 1001 is an EVPN device, set a general virtual routing table and a local virtual routing table according to the forwarding policy.
  • the method further includes: receiving an updated forwarding strategy distributed by the management device 1002; performing data forwarding according to the updated forwarding strategy.
  • selecting the next hop includes: selecting all virtual members in the group as next-hop devices, and performing load sharing among all virtual members.
  • the management device 1002 after distributing the forwarding policy of each forwarding device 1001 to each forwarding device 1001, the management device 1002 also updates the routing information after the network topology changes; and updates each forwarding device 1001 according to the updated routing information.
  • the forwarding policy of each forwarding device 1001 is distributed to each forwarding device 1001 after updating.
  • this embodiment is a system embodiment corresponding to the above-mentioned embodiments, and this embodiment can be implemented in cooperation with the above-mentioned embodiments.
  • the relevant technical details mentioned in the foregoing embodiments are still valid in this embodiment, and will not be repeated here in order to reduce repetition.
  • the relevant technical details mentioned in this embodiment can also be applied in the above embodiments.
  • the embodiment of the present application also relates to an electronic device, as shown in FIG. 11 , including: at least one processor 1101; The executed instructions are executed by at least one processor 1101 in the data forwarding method of any of the foregoing embodiments.
  • the memory 1102 and the processor 1101 are connected by a bus, and the bus may include any number of interconnected buses and bridges, and the bus connects one or more processors 1101 and various circuits of the memory 1102 together.
  • the bus may also connect together various other circuits such as peripherals, voltage regulators, and power management circuits, all of which are well known in the art and therefore will not be further described herein.
  • the bus interface provides an interface between the bus and the transceivers.
  • a transceiver may be a single element or multiple elements, such as multiple receivers and transmitters, providing means for communicating with various other devices over a transmission medium.
  • the information processed by the processor 1101 is transmitted on the wireless medium through the antenna, further, the antenna also receives the information and transmits the information to the processor 1101 .
  • the processor 1101 is responsible for managing the bus and general processing, and can also provide various functions, including timing, peripheral interface, voltage regulation, power management and other control functions. Instead, memory 1102 may be used to store information used by the processor when performing operations.
  • Embodiments of the present application relate to a computer-readable storage medium storing a computer program.
  • the above method embodiments are implemented when the computer program is executed by the processor.
  • the program is stored in a storage medium, and includes several instructions to make a device ( It may be a single-chip microcomputer, a chip, etc.) or a processor (processor) to execute all or part of the steps of the methods in the various embodiments of the present application.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disc, etc., which can store program codes. .

Abstract

本申请实施例涉及通信领域,公开了一种数据转发方法、系统、电子设备和存储介质。本申请中,数据转发方法,应用于overlay网络中的转发设备,转发设备与管理设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员,方法包括:接收管理设备分发的转发策略;其中,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员;根据转发策略,进行数据转发。

Description

数据转发方法、系统、电子设备和存储介质
交叉引用
本申请基于申请号为“202111155660.3”、申请日为2021年9月30日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此以引入方式并入本申请。
技术领域
本申请实施例涉及通信领域,特别涉及一种数据转发方法、系统、电子设备和存储介质。
背景技术
随着互联网技术的发展,5G用户爆炸式增长,因此必须提供比上一代技术更大的设备连接和网络容量,对于5G来说,一个重大的改变是如今的虚拟化趋势。5G网络会使用网络切片技术将一个物理基础设施分割成多个虚拟网络,以便每个片在相同的基础设施下提供不同的且唯一的连接。虚拟网络大多使用重叠网络overlay技术,以便快速提供不同要求。对于大型组网场景中,来自相同节点的不同流量能选择不同路径流向目的地,防止单路径负荷超限,同时提供高可靠,为各类应用提供高性能可靠的网络服务,所以overlay场景同样需要等价多路径路由(Equal Cost Multi-path,简称“ECMP”)技术。
然而,路由策略为了实现各节点独立选择ECMP成员时不造成环路,启用本地优先策略,即,优先选择ECMP分组的本地虚拟成员进行数据转发,从而造成当报文源地址和目的地址位于相同节点上时,无法负荷分担到其他节点的ECMP成员,网络数据转发性能较低。
发明内容
本申请实施例提供了一种数据转发方法,应用于overlay网络中的转发设备, 转发设备与管理设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员,方法包括:接收管理设备分发的转发策略;其中,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员;根据转发策略,进行数据转发。
本申请实施例还提供了一种数据转发方法,应用于overlay网络中的管理设备,管理设备与至少一个转发设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员,方法包括:获取各转发设备的路由信息;根据路由信息,生成各转发设备的转发策略;将各转发设备的转发策略,分发给各转发设备,供各转发设备接收管理设备分发的转发策略,并根据转发策略,进行数据转发;其中,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员。
本申请实施例还提供了一种数据转发系统,包括应用于overlay网络中的转发设备和管理设备;管理设备与至少一个转发设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员;其中,管理设备,用于获取各转发设备的路由信息;根据路由信息,生成各转发设备的转发策略;将各转发设备的转发策略,分发给各转发设备,供各转发设备接收管理设备分发的转发策略,并根据转发策略,进行数据转发;转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员;转发设备,用于接收管理设备分发的转发策略;根据转发策略,进行数据转发。
本申请的实施例还提供了一种电子设备,包括:至少一个处理器;以及,与至少一个处理器通信连接的存储器;其中,存储器存储有可被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行上述数据转发方法。
本申请的实施例还提供了一种计算机可读存储介质,存储有计算机程序,计算机程序被处理器执行时实现上述数据转发方法。
附图说明
图1是本申请一个实施例提供的应用于转发设备的数据转发方法流程示意图;
图2是本申请一个实施例提供的转发路径示意图一;
图3是本申请一个实施例提供的转发路径示意图二;
图4是本申请一个实施例提供的转发路径示意图三;
图5是本申请一个实施例提供的转发路径示意图四;
图6是本申请一个实施例提供的数据转发方法流程示意图;
图7是本申请一个实施例提供的路由信息采集示意图;
图8是本申请一个实施例提供的路由策略示意图;
图9是本申请一个实施例提供的应用于管理设备的数据转发方法流程示意图;
图10是本申请一个实施例提供的数据转发系统示意图;
图11是本申请一个实施例提供的电子设备结构示意图。
具体实施方式
为使本申请实施例的目的、技术方案和优点更加清楚,下面将结合附图对本申请的各实施例进行详细的阐述。然而,本领域的普通技术人员可以理解,在本申请各实施例中,为了使读者更好地理解本申请而提出了许多技术细节。但是,即使没有这些技术细节和基于以下各实施例的种种变化和修改,也可以实现本申请所要求保护的技术方案。以下各个实施例的划分是为了描述方便,不应对本申请的具体实现方式构成任何限定,各个实施例在不矛盾的前提下可以相互结合相互引用。
本申请实施例的主要目的在于提出一种数据转发方法、系统、电子设备和存储介质,以实现提高网络数据转发性能。
本申请的实施例涉及一种数据转发方法,如图1所示,包括以下步骤:
步骤101,接收管理设备分发的转发策略;其中,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员;
步骤102,根据转发策略,进行数据转发。
本实施例的数据转发方法,应用于overlay网络中的转发设备,转发设备与管理设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员。Overlay网络,又叫叠加网络、覆盖网络)简单理解就是把一个逻辑网络建立在一个实体网络之上。虚拟扩展局域网(Virtual eXtensible Local Area Network,简称“VXLAN”),是由IETF定义的NVO3(Network Virtualization over Layer 3)标准技术之一,采用L2 over L4(MAC-in-UDP)的报文封装模式,将二层报文用三层协议进行封装,可实现二层网络在三层范围内进行扩展,同时满足数据中心大二层虚拟迁移和多租户的需求。NVO3是基于三层IP overlay网络构建虚拟网络的技术的统称,VXLAN只是NVO3技术之一。其中,本实施例的转发设备可以是VXLAN隧道端点(VXLAN Tunnel Endpoints,简称“VTEP”)设备,VTEP设备可以是交换机,也可以是虚拟机所在的服务器,管理设备可以是网络中的管理设备,和VTEP设备或者云管理系统,如OPENSTACK的neutron组件,或者虚拟网络控制器,例如软件定义网络(Software Defined Network,简称“SDN”)。
随着5G用户爆炸式增长,必须提供比上一代技术更大的设备连接和网络容量,对于5G来说,一个重大的改变是如今的虚拟化趋势。5G网络会使用网络切片技术将一个物理基础设施分割成多个虚拟网络,以便每个片在相同的基础设施下提供不同的且唯一的连接。为了实现这种灵活性,每个分片都要能够访问不同类型的资源,无论是物理资源还是虚拟资源,例如,虚拟网络功能(Virtualized Network Function,简称“VNF”),因此5G通过SDN,用网络控制可编程来彻底改变网络的架构。网络控制用于开放的软件系统,将实际的物理网络虚拟化,从实现来说,虚拟网络大多使用overlay技术,以便快速提供不同要求。对于大型组网场景中,来自相同节点的不同流量能选择不同路径流向目的地,防止单路径负荷超限,同时提供高可靠,为各类应用提供高性能可靠 的网络服务,所以overlay场景同样需要ECMP技术。
大规模场景,若使用非对称路由,每个VTEP设备要维护所有虚拟网络标识(virtualized network identifier,简称“vni”)的介质访问控制层(Media Access Control,简称“MAC”)和地址解析协议(Address Resolution Protocol,简称“ARP”)表,例如VTEP设备上有4个虚拟成员,第一成员vni1、第二成员vni2、第三成员vni3、第四成员vni4,转发时,可以在本节点选择好ECMP的具体成员。非对称路由方式,是每个vtep需要维护所有vni的ARP和MAC地址表,即使没有本地主机的vni。这就需要涉及超大容量的ARP和MAC表,造成资源浪费,如图2。
为了减小MAC/ARP表项,一般采用对称式路由技术,对称路由中,每个vtep优化了ARP和MAC地址表,每个router有一个L3 vni。如图3所示,对称路由在处理ECMP路由时,由于每个节点独立选路,不同ECMP组成员连接在不同VTEP设备上,其中,一般需要设置为本地优先,否则继续选路可能会存在环路,如图4所示,ECMP组成员分别落在vtep1设备和vtep2设备上,虚拟网络功能VNF发出的报文,在VTEP1设备上可能选择VTEP2设备上的ECMP组成员做下一跳,在VTEP2设备上可能选择vtep1上的组成员做下一跳,从而造成循环。
为了避免各节点独立选路造成环路,一般是选择本地优先的策略,即若本VTEP设备上有直连的ECMP组,则优先发往本设备的ECMP组。启用本地优先策略,会造成当源和目的位于相同节点上时,无法负荷分担到其他节点的ECMP成员,造成流量不均,如图5所示,永远选择本地的ECMP下一跳成员,无法选择3中的另一个下一跳。
本实施例的数据转发方法,通过在ECMP分组的本地虚拟成员中选择下一跳,可以避免节点独立选路而导致数据转发过程中形成环路,提高网络的数据转发效率,在转发设备为首跳设备时,在ECMP分组所有虚拟成员中选择下一跳,即使在报文源地址和目的地址位于相同节点上时,也可以将数据转发流量分担至其他节点,从而均衡数据转发流量,提高了网络的反应速度与总体性能,使得网络可以实现弹性业务伸缩。因此,在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选 择下一跳,以此策略进行数据转发可以实现提高网络数据转发性能。
下面对本实施例的数据转发方法实现细节进行具体的说明,以下内容仅为方便理解提供的实现细节,并非实施本方案的必须。
在步骤101中,转发设备接收管理设备分发的转发策略,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员。
具体地,转发策略由管理设备配置得到,管理设备通过获取各转发设备的路由信息,根据路由信息,生成各转发设备的转发策略。其中,转发设备可以在第一分组或者第二分组中选择一个或多个设备作为下一跳设备。
在一个例子中,转发设备选择下一跳,具体为:选择组中所有虚拟成员作为下一跳设备,并在所有虚拟成员之间进行负荷分担。
本实施例中,通过选择组中所有虚拟成员作为下一跳设备,并在所有虚拟成员之间进行负荷分担,从而在整个组的所有虚拟成员间进行流量分担,进一步实现提高网络数据转发性能。
在步骤102中,转发设备根据转发策略,进行数据转发。
具体地,转发设备根据转发策略,在接收到待转发报文后,判断本设备是否为首跳设备,若本设备为首跳设备,则从ECMP分组中的所有虚拟成员中选择下一跳,若本设备不是首跳设备,则从第二分组,即ECMP分组的本地虚拟成员中选择下一跳。
进一步地,转发设备根据转发策略,和转发设备的类型,生成转发规则,根据转发规则,进行数据转发。
本实施例中,通过根据转发策略,和转发设备的类型,生成转发规则,根据转发规则,进行数据转发,可以实现提高网络数据转发性能。
在一个例子中,转发规则包括通用虚拟路由表和本地虚拟路由表,以及流表。转发设备通过以下方式实现根据转发策略,生成转发规则:在转发设备为openflow设备的情况下,根据转发策略,生成流表;在转发设备为EVPN设备的情况下,根据转发策略,设置通用虚拟路由表和本地虚拟路由表。
本实施例中,通过在转发设备为openflow设备的情况下,根据转发策略,生成流表,在转发设备为EVPN(以太网VPN)设备的情况下,根据转发策略,设置通用虚拟路由表和本地虚拟路由表,可以实现对openflow设备和EVPN设备转发规则的更改,实现提高网络数据转发性能。
在一个例子中,在接收管理设备分发的转发策略后,转发设备还接收管理设备分发的更新后的转发策略,根据更新后的转发策略,进行数据转发。
本实施例中,通过接收管理设备分发的更新后的转发策略,根据更新后的转发策略,进行数据转发,可以用新的转发策略进行数据转发,实现提高网络数据转发性能。
在一个例子中,管理设备中有ECMP管理模块、ECMP转发策略模块,转发设备中有ECMP转发执行模块,如图6所示,其中,ECMP管理模块,server端,用于搜集各VTEP转发设备的路由信息,形成全局的ECMP组,及各组成员的属性,位置,拓扑关系等信息,用于指导后续ECMP转发策略模块完成策略生成,并同步到对应设备。ECMP转发策略模块,agent端,用于将从ECMP管理模块获取到的信息转化为设备的ECMP转发策略,根据ECMP组成员未知计算个VTEP设备的ECMP转发策略,对于vswitch,可以下发vswitch流表,针对报文不同入端口选择ECMP成员口,对于switch,可以下发硬件转发设备对应的转发条目,针对报文不同入端口选择ECMP成员口。ECMP转发执行模块,虚拟转发设备vswitch,或者硬件转发设备switch用于将ECMP转发策略在各VTEP设备上生成转发规则。VTEP设备可能是openflow类型的设备,也可能是EVPN类型设备,从而可以按策略进行转发。
如图7所示,数据转发包括以下流程:
1)ECMP管理模块通过和VTEP设备或云管理系统(如OPENSTACK的neutron组件)或虚拟网络控制器(如SDN)交互,搜集网络内路由信息,形成并维护ECMP组及成员信息表。
ECMP管理模块搜集到的路由信息及下一跳过程如下:ECMP管理模块获取到每个逻辑路由实例(vrouter)的所有路由条目,每个路由条目关键信息包括:vrouter标识(RD或L3VNI),路由目的网段(网络前缀),下一跳(在路 由型网元的场景下,该下一跳可能是虚机地址或端口);ECMP管理模块根据上述信息,提取出ECMP组成员信息表(具有相同vrouter标识(RD或L3VNI),路由目的网段(网络前缀)的一组路由),关键信息包括:ECMP组标识,归属vrouter标识(RD或L3VNI),下一跳成员(具体可包括下一跳的地址或端口信息),成员所在VTEP设备。
2)ECMP转发策略模块从管理模块获取ECMP信息,转化为设备的转发策略,如图8所示。
3)转发执行模块将ECMP转发策略转为VTEP设备的转发规则。若VTEP设备是openflow转发设备,则转发规则转为openflow流表。若VTEP设备是EVPN转发设备,则转发规则转为边界网关协议(Boarder Gateway Protocol,简称“BGP”)报文。下面分别说明转发规则的实现方法。
对于openflow设备,通过openflow协议接收流表条目,ECMP一般是使用openflow协议中定义的group表实现的。协议中group表定义如下:
GroupIdentifier GroupType Counters Action Bucket
我们这里扩展group表类型,增加一个新类型,值为16,取名字为conditional,表示可根据定义的条件选择不同bucket。定义如下:
enum ofp_group_type{
OFPGT_ALL=0,/*All(multicast/broadcast)group.*/
OFPGT_SELECT=1,/*Select group.*/
OFPGT_INDIRECT=2,/*Indirect group.*/
OFPGT_FF=3,/*Fast failover group.*/
OFPGT_CONDITION=16,/*conditional group.*/
};
Openflow协议的bucket表也要新增一个和conditional类型的group表对应的新类型,这里取值也为16,定义如下:
/*Group bucket property types.*/
enum ofp_group_bucket_prop_type{
OFPGBPT_WEIGHT=0,/*Select groups only.*/
OFPGBPT_WATCH_PORT=1,/*Fast failover groups only.*/
OFPGBPT_WATCH_GROUP=2,/*Fast failover groups only.*/
OFPGBPT_COND_GROUP=16,/*Conditional groups only.*/
OFPGBPT_EXPERIMENTER=0xFFFF,/*Experimenter defined.*/
};
新bucket类型的结构如下:
struct ofp_group_bucket_prop_cond{
uint16_t type;/*OFPGBPT_COND_GROUP.*/
uint16_t length;/*8.*/
uint16_t conditional_key;/*条件匹配的key值*/
uint16_t conditional_type;/*条件匹配的类型*/
uint32_t conditional_val;/*与key值相匹配的值.*/
};
各字段说明如下:
condition_key可扩展定义,当前定义为:
0:保留;
1:metadata
2:in_port
condition_type可扩展定义,当前定义为:
0:保留;
1:等于;
2:不等于;
3:包含;
conditional_val为匹配的具体值,当前仅支持数值。
如果设置了conditional_key,则仅当conditional_key和conditional_val满足condition_type的定义才参与负荷分担;默认不设置,表示参加负荷分担计算。
Openflow的group feature字段新增一个如下值,用来通知管理模块本VTEP设备支持conditional的组,定义如下:
OFPGFC_CONDITIONAL=1<<7,/*Support conditional groups*/。
/*Group configuration flags*/
enum ofp_group_capabilities{
OFPGFC_SELECT_WEIGHT=1<<0,/*Support weight for select groups*/
OFPGFC_SELECT_LIVENESS=1<<1,/*Support liveness for select groups*/
OFPGFC_CHAINING=1<<2,/*Support chaining groups*/
OFPGFC_CHAINING_CHECKS=1<<3,/*Check chaining for loops and delete*/
OFPGFC_CONDITIONAL=1<<7,/*Support conditional groups*/
};
举例说明如下:
转发策略模块根据VTEP设备上报的组类型,确定按conditional生成转发规则。
转发执行模块跟踪转发规则vtep1下发的openflow流表group组信息为:
Figure PCTCN2022091545-appb-000001
转发执行模块跟踪转发规则vtep2下发的openflow流表group组信息为:
Figure PCTCN2022091545-appb-000002
报文转发过程说明如下:VTEP1收到VNF13发出的报文后,按照报文流 表动作,先将当前报文的vni保存到metadata字段,因为VNF13发送的报文非vxlan报文,无vni信息,则metadata为0。执行group动作时,先查看metadata是否等于L3 vni 1,如果相等,则只有bucket2的动作可执行;如果不相等,则bucket1和bucket2均可执行,按照原有bucket进行选择其一。因此VNF13发出的报文仍然可在2个下一跳间均衡选路,可以在VTEP1上选择VNF11作为下一跳;也可以在VTEP1上选择VNF21作为下一跳,因为VNF21跨节点,因此封装vxlan报文,vni=L3 vni 1,发送到VTEP2。
VTEP2节点收到报文后,因为是vxlan报文,保存metadata为vni号,即L3 vni 1,执行group动作时,因为metadata等于L3 vni1,只有bucket2可选,因此只能执行选择bucket2的动作,将报文发送到VNF21这个下一跳。
对于EVPN设备,EVPN的VTEP设备BGP协议交换转发规则,VTEP设备需要实现如下功能:VTEP设备将IP-VRF表分组,形成local IP-VRF表(即本地虚拟路由表)和通用IP-VRF表(即通用虚拟路由表)。VTEP设备通过BGP协议维护local IP-VRF表和通用IP-VRF表。VTEP设备L3报文转发时,根据目的mac确定查local IP-VRF表还是通用IP-VRF表。
对于表维护和报文转发流程分别说明如下:VTEP设备给每个router-id创建local IP-VRF表和通用IP-VRF两个表。VTEP router的L2转发表新增匹配字段是router-mac的表,动作是进入local IP-VRF表查L3转发规则。转发策略模块给VTEP设备发送BGP邻居的RT-5路由新增通告,VTEP设备取出路由条目,合成路由以后,查询下一跳地址是在本地学到的arp表中还是RT-2通告的arp表中,若都不在,该路由仅保存到本地RT-5路由表中,不加入local IP-VRF表和通用IP-VRF;若下一跳地址在RT-2通告的arp表中,则将该路由保存到本地RT-5路由表以后再将其加入通用IP-VRF;若下一跳地址在本地学到的arp表中,则将该路由保存到本地RT-5路由表以后同时将该路由加入通用IP-VRF和local IP-VRF表中。VTEP设备收到远端BGP邻居的RT-2路由通告,若通告的ip地址是某个RT-5路由合成路由的下一跳,则正常保存到arp表以后,检查该路由是否在通用IP-VRF表中,若不在,则将该路由加入通用IP-VRF。VTEP设备本地学到ARP,若ip地址是RT-5路由表中某个合成路由的下一跳,则正常保存到arp表以后,检查该路由是否在通用IP-VRF,若不在,则将该路由加 入通用IP-VRF,检查该路由是否在local IP-VRF,若不在,则将该路由加入local IP-VRF。RT-5路由删除通告和ARP老化事件处理为从上述表中删除对应的下一跳记录。
EVPN设备的报文转发流量如下,VTEP设备收到业务报文以后,首先是查L2转发表,若目的mac是网关mac,则进入通用IP-VRF表,在通用IP-VRF表中应用ECMP规则;若目的mac是router-mac,则进入local IP-VRF表,在local IP-VRF表中应用ECMP规则。
本实施例中,通过管理设备搜集并维护各ECMP组成员的物理位置及拓扑关系,根据拓扑关系管理每个VTEP设备的ECMP组,同一个ECMP组在每个VTEP设备上拆分成如下两个组:包含所有组成员的组,以及组成员和本VTEP设备直连的组,结合每个VTEP设备拆分出来的两个ECMP组计算个VTEP设备的转发策略。各VTEP设备将本设备的ECMP转发策略转成转发规则进行流量转发。流量在首跳设备的所有ECMP组成员之间进行负荷分担,均匀选路;流量在非首跳设备上的和本VTEP设备直连的组成员间负荷分担;从而避免非首跳设备将报文发往其他VTEP设备引发环路,同时也能避免上述本地优先策略下的负荷分担不均问题。
本实施例的数据转发方法,应用于overlay网络中的管理设备,管理设备与至少一个转发设备通信连接,管理设备用于管理至少一个转发设备,每个转发设备包含多个虚拟成员,如图9所示,包括:
步骤901,获取各转发设备的路由信息;
步骤902,根据路由信息,生成各转发设备的转发策略;
步骤903,将各转发设备的转发策略,分发给各转发设备,供各转发设备接收管理设备分发的转发策略,并根据转发策略,进行数据转发;
其中,转发策略包括:在转发设备为首跳设备的情况下,在第一分组中选择下一跳,在转发设备为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员。
在一个例子中,在将各转发设备的转发策略,分发给各转发设备后,管理 设备还在网络拓扑发生变化后,更新路由信息;根据更新后的路由信息,更新各转发设备的转发策略;将更新后的各转发设备的转发策略,分发给各转发设备。
由于本实施例与上述实施例相互对应,因此本实施例可与上述实施例互相配合实施。上述实施例中提到的相关技术细节在本实施例中依然有效,在上述实施例中所能达到的技术效果在本实施例中也同样可以实现,为了减少重复,这里不再赘述。相应地,本实施例中提到的相关技术细节也可应用在上述实施例中。
本申请的实施例涉及一种数据转发系统,如图10所示,包括:overlay网络中的转发设备1001和管理设备1002;管理设备1002与至少一个转发设备1001通信连接,管理设备1002用于管理至少一个转发设备1001,每个转发设备1001包含多个虚拟成员;
其中,管理设备1002,用于获取各转发设备1001的路由信息;根据路由信息,生成各转发设备1001的转发策略;将各转发设备1001的转发策略,分发给各转发设备1001,供各转发设备1001接收管理设备1002分发的转发策略,并根据转发策略,进行数据转发;转发策略包括:在转发设备1001为首跳设备的情况下,在第一分组中选择下一跳,在转发设备1001为非首跳设备的情况下,在第二分组中选择下一跳,第一分组包含转发设备1001的等价多路径路由ECMP分组所有虚拟成员,第二分组仅包含ECMP分组的本地虚拟成员;
转发设备1001,用于接收管理设备1002分发的转发策略;根据转发策略,进行数据转发。
在一个例子中,根据转发策略,进行数据转发,包括:根据转发策略,和转发设备1001的类型,生成转发规则;根据转发规则,进行数据转发。
在一个例子中,转发规则包括通用虚拟路由表和本地虚拟路由表,以及流表;根据转发策略,生成转发规则,包括:在转发设备1001为openflow设备的情况下,根据转发策略,生成流表;在转发设备1001为EVPN设备的情况下,根据转发策略,设置通用虚拟路由表和本地虚拟路由表。
在一个例子中,在接收管理设备1002分发的转发策略后,方法还包括:接 收管理设备1002分发的更新后的转发策略;根据更新后的转发策略,进行数据转发。
在一个例子中,选择下一跳,包括:选择组中所有虚拟成员作为下一跳设备,并在所有虚拟成员之间进行负荷分担。
在一个例子中,在将各转发设备1001的转发策略,分发给各转发设备1001后,管理设备1002还在网络拓扑发生变化后,更新路由信息;根据更新后的路由信息,更新各转发设备1001的转发策略;将更新后的各转发设备1001的转发策略,分发给各转发设备1001。
不难发现,本实施例为与上述实施例相对应的系统实施例,本实施例可与上述实施例互相配合实施。上述实施例中提到的相关技术细节在本实施例中依然有效,为了减少重复,这里不再赘述。相应地,本实施例中提到的相关技术细节也可应用在上述实施例中。
本申请的实施例还涉及一种电子设备,如图11所示,包括:至少一个处理器1101;与至少一个处理器通信连接的存储器1102;其中,存储器1102存储有可被至少一个处理器1101执行的指令,指令被至少一个处理器1101执行上述的任一实施例的数据转发方法。
其中,存储器1102和处理器1101采用总线方式连接,总线可以包括任意数量的互联的总线和桥,总线将一个或多个处理器1101和存储器1102的各种电路连接在一起。总线还可以将诸如外围设备、稳压器和功率管理电路等之类的各种其他电路连接在一起,这些都是本领域所公知的,因此,本文不再对其进行进一步描述。总线接口在总线和收发机之间提供接口。收发机可以是一个元件,也可以是多个元件,比如多个接收器和发送器,提供用于在传输介质上与各种其他装置通信的单元。经处理器1101处理的信息通过天线在无线介质上进行传输,进一步,天线还接收信息并将信息传送给处理器1101。
处理器1101负责管理总线和通常的处理,还可以提供各种功能,包括定时,外围接口,电压调节、电源管理以及其他控制功能。而存储器1102可以被用于存储处理器在执行操作时所使用的信息。
本申请的实施例涉及一种计算机可读存储介质,存储有计算机程序。计算机程序被处理器执行时实现上述方法实施例。
即,本领域技术人员可以理解,实现上述实施例方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。

Claims (10)

  1. 一种数据转发方法,应用于overlay网络中的转发设备,所述转发设备与管理设备通信连接,所述管理设备用于管理至少一个所述转发设备,每个所述转发设备包含多个虚拟成员,所述方法包括:
    接收所述管理设备分发的转发策略;其中,所述转发策略包括:在所述转发设备为首跳设备的情况下,在第一分组中选择下一跳,在所述转发设备为非首跳设备的情况下,在第二分组中选择下一跳,所述第一分组包含所述转发设备的等价多路径路由ECMP分组所有虚拟成员,所述第二分组仅包含所述ECMP分组的本地虚拟成员;
    根据所述转发策略,进行数据转发。
  2. 根据权利要求1所述的数据转发方法,其中,所述根据所述转发策略,进行数据转发,包括:
    根据所述转发策略,和所述转发设备的类型,生成转发规则;
    根据所述转发规则,进行数据转发。
  3. 根据权利要求2所述的数据转发方法,其中,所述转发规则包括通用虚拟路由表和本地虚拟路由表,以及流表;
    所述根据所述转发策略,生成转发规则,包括:
    在所述转发设备为openflow设备的情况下,根据所述转发策略,生成流表;
    在所述转发设备为EVPN设备的情况下,根据所述转发策略,设置通用虚拟路由表和本地虚拟路由表。
  4. 根据权利要求1至3中任意一项所述的数据转发方法,其中,在所述接收所述管理设备分发的转发策略后,所述方法还包括:
    接收所述管理设备分发的更新后的转发策略;
    根据更新后的转发策略,进行数据转发。
  5. 根据权利要求2至4中任一项所述的数据转发方法,其中,所述选择下一跳,包括:
    选择组中所有虚拟成员作为下一跳设备,并在所有虚拟成员之间进行负荷分担。
  6. 一种数据转发方法,应用于overlay网络中的管理设备,所述管理设备 与至少一个转发设备通信连接,所述管理设备用于管理至少一个所述转发设备,每个所述转发设备包含多个虚拟成员,所述方法包括:
    获取各所述转发设备的路由信息;
    根据所述路由信息,生成各所述转发设备的转发策略;
    将各所述转发设备的转发策略,分发给各所述转发设备,供各所述转发设备接收所述管理设备分发的转发策略,并根据所述转发策略,进行数据转发;
    其中,所述转发策略包括:在所述转发设备为首跳设备的情况下,在第一分组中选择下一跳,在所述转发设备为非首跳设备的情况下,在第二分组中选择下一跳,所述第一分组包含所述转发设备的等价多路径路由ECMP分组所有虚拟成员,所述第二分组仅包含所述ECMP分组的本地虚拟成员。
  7. 根据权利要求6所述的数据转发方法,其中,在所述将各所述转发设备的转发策略,分发给各所述转发设备后,所述方法还包括:
    在网络拓扑发生变化后,更新所述路由信息;
    根据更新后的路由信息,更新各所述转发设备的转发策略;
    将更新后的各所述转发设备的转发策略,分发给各所述转发设备。
  8. 一种数据转发系统,包括应用于overlay网络中的转发设备和管理设备;所述管理设备与至少一个所述转发设备通信连接,所述管理设备用于管理至少一个所述转发设备,每个所述转发设备包含多个虚拟成员;
    其中,管理设备,用于获取各所述转发设备的路由信息;根据所述路由信息,生成各所述转发设备的转发策略;将各所述转发设备的转发策略,分发给各所述转发设备,供各所述转发设备接收所述管理设备分发的转发策略,并根据所述转发策略,进行数据转发;所述转发策略包括:在所述转发设备为首跳设备的情况下,在第一分组中选择下一跳,在所述转发设备为非首跳设备的情况下,在第二分组中选择下一跳,所述第一分组包含所述转发设备的等价多路径路由ECMP分组所有虚拟成员,所述第二分组仅包含所述ECMP分组的本地虚拟成员;
    转发设备,用于接收所述管理设备分发的所述转发策略;根据所述转发策略,进行数据转发。
  9. 一种电子设备,包括:
    至少一个处理器;以及,
    与所述至少一个处理器通信连接的存储器;其中,
    所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如权利要求1至5中任一项所述的应用于转发设备的数据转发方法,或者,如权利要求6至7中任一项所述的应用于管理设备的数据转发方法。
  10. 一种计算机可读存储介质,存储有计算机程序,所述计算机程序被处理器执行时实现如权利要求1至5中任一项所述的应用于转发设备的数据转发方法,或者,如权利要求6至7中任一项所述的应用于管理设备的数据转发方法。
PCT/CN2022/091545 2021-09-30 2022-05-07 数据转发方法、系统、电子设备和存储介质 WO2023050818A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111155660.3A CN115914069A (zh) 2021-09-30 2021-09-30 数据转发方法、系统、电子设备和存储介质
CN202111155660.3 2021-09-30

Publications (1)

Publication Number Publication Date
WO2023050818A1 true WO2023050818A1 (zh) 2023-04-06

Family

ID=85739403

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/091545 WO2023050818A1 (zh) 2021-09-30 2022-05-07 数据转发方法、系统、电子设备和存储介质

Country Status (2)

Country Link
CN (1) CN115914069A (zh)
WO (1) WO2023050818A1 (zh)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101572667A (zh) * 2009-05-22 2009-11-04 中兴通讯股份有限公司 一种ip路由等价多路径的实现方法及装置
US20130329730A1 (en) * 2012-06-07 2013-12-12 Cisco Technology, Inc. Scaling IPv4 in Data Center Networks Employing ECMP to Reach Hosts in a Directly Connected Subnet
CN107547348A (zh) * 2017-07-25 2018-01-05 新华三技术有限公司 防止数据流中断方法和装置
CN107634905A (zh) * 2016-07-19 2018-01-26 南京中兴新软件有限责任公司 堆叠系统中数据转发方法及装置
CN109246017A (zh) * 2018-11-28 2019-01-18 新华三技术有限公司 一种查询组播转发路径的方法及装置
CN109981455A (zh) * 2017-12-28 2019-07-05 中兴通讯股份有限公司 一种隧道实现方法及装置
CN109995654A (zh) * 2017-12-29 2019-07-09 中兴通讯股份有限公司 一种基于隧道传输数据的方法及装置
CN111756830A (zh) * 2020-06-22 2020-10-09 浪潮云信息技术股份公司 公有云网络的内网负载均衡实现方法
CN112565045A (zh) * 2019-09-26 2021-03-26 中兴通讯股份有限公司 Evpn中报文转发方法、装置、设备及存储介质

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101572667A (zh) * 2009-05-22 2009-11-04 中兴通讯股份有限公司 一种ip路由等价多路径的实现方法及装置
US20130329730A1 (en) * 2012-06-07 2013-12-12 Cisco Technology, Inc. Scaling IPv4 in Data Center Networks Employing ECMP to Reach Hosts in a Directly Connected Subnet
CN107634905A (zh) * 2016-07-19 2018-01-26 南京中兴新软件有限责任公司 堆叠系统中数据转发方法及装置
CN107547348A (zh) * 2017-07-25 2018-01-05 新华三技术有限公司 防止数据流中断方法和装置
CN109981455A (zh) * 2017-12-28 2019-07-05 中兴通讯股份有限公司 一种隧道实现方法及装置
CN109995654A (zh) * 2017-12-29 2019-07-09 中兴通讯股份有限公司 一种基于隧道传输数据的方法及装置
CN109246017A (zh) * 2018-11-28 2019-01-18 新华三技术有限公司 一种查询组播转发路径的方法及装置
CN112565045A (zh) * 2019-09-26 2021-03-26 中兴通讯股份有限公司 Evpn中报文转发方法、装置、设备及存储介质
CN111756830A (zh) * 2020-06-22 2020-10-09 浪潮云信息技术股份公司 公有云网络的内网负载均衡实现方法

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
CISCO SYSTEMS.: "Pseudo-CR on SRv6 Introduction for User Plane", 3GPP DRAFT; C4-186166, 3RD GENERATION PARTNERSHIP PROJECT (3GPP), MOBILE COMPETENCE CENTRE ; 650, ROUTE DES LUCIOLES ; F-06921 SOPHIA-ANTIPOLIS CEDEX ; FRANCE, vol. CT WG4, no. West Palm Beach, US; 20180820 - 20180824, 10 August 2018 (2018-08-10), Mobile Competence Centre ; 650, route des Lucioles ; F-06921 Sophia-Antipolis Cedex ; France , XP051574803 *
JING-LING LIU, HUANG JIA-WEI, JIANG WAN-CHUN, WANG JIAN-XIN: "Survey on Load Balancing Mechanism in Data Center", JOURNAL OF SOFTWARE, vol. 32, no. 2, 1 February 2021 (2021-02-01), pages 300 - 326, XP093053341, ISSN: 1000-9825, DOI: 10.13328/j.cnki.jos.006151 *

Also Published As

Publication number Publication date
CN115914069A (zh) 2023-04-04

Similar Documents

Publication Publication Date Title
US11140070B2 (en) Independent datastore in a network routing environment
US10182496B2 (en) Spanning tree protocol optimization
US10263889B2 (en) Data forwarding method, device, and system in software-defined networking
CN107204867B (zh) 一种信息传输方法、装置和系统
EP3474502B1 (en) Reduced configuration for multi-stage network fabrics
WO2021043181A1 (zh) 一种数据传输方法及装置
WO2021007963A1 (zh) 路由分发方法及控制器、信息路由方法及网络节点设备
US9743367B2 (en) Link layer discovery protocol (LLDP) on multiple nodes of a distributed fabric
CN111147372B (zh) 下行报文发送、转发方法和装置
US9948482B2 (en) Apparatus and method for enabling flexible key in a network switch
US11923963B2 (en) Managing satellite devices within a branch network
WO2023045871A1 (zh) 报文处理方法、网络设备及系统
WO2022194023A1 (zh) 报文处理的方法、网络设备及控制器
WO2022057810A1 (zh) 业务报文的转发方法、sr策略的发送方法、设备及系统
US20230269164A1 (en) Method and apparatus for sending route calculation information, device, and storage medium
EP4325800A1 (en) Packet forwarding method and apparatus
WO2023050818A1 (zh) 数据转发方法、系统、电子设备和存储介质
WO2022166465A1 (zh) 一种报文处理方法及相关装置
Rischke et al. Software-defined networks
CN114520752A (zh) 基于智能网卡的vxlan协议控制平面卸载方法及装置
WO2021083228A1 (zh) 报文转发方法、装置及计算机存储介质
CN115473812A (zh) 流量报文转发方法、客户端、控制器及存储介质
CN113595915A (zh) 转发报文的方法及相关设备
WO2023155733A1 (zh) 一种网络切片信息传输方法及装置
WO2023138351A1 (zh) 一种流量转发方法、报文发送方法、消息发送方法及装置

Legal Events

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

Ref document number: 22874216

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2022874216

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2022874216

Country of ref document: EP

Effective date: 20240326