A network communication system, method, device, electronic device and storage medium

By generating and propagating target advertisement routes in the network communication system, the problem of increasing data transmission path length caused by the same access address between switches is solved, and the data communication efficiency is improved and the traffic forwarding path is optimized.

CN118869581BActive Publication Date: 2025-03-07INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411356823.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-27
Publication Date
2025-03-07
Estimated Expiration
2044-09-27

AI Technical Summary

Technical Problem

In a network communication system, after establishing a neighbor relationship between switches, the external access addresses are the same, resulting in an increase in the length of the data packet transmission path and reducing the data communication efficiency.

Method used

When the local switch detects the access address of the independent terminal device, a target advertisement route is generated and sent to the remote switch. After the remote switch receives the target advertised route, it tunnels the packets to be sent based on the global unique tunnel endpoint address of the local switch in the advertised route to ensure that the traffic forwarding path is the shortest path.

Benefits of technology

By optimizing the data transmission path, data communication efficiency is improved, the optimality of the traffic forwarding path is ensured, and the overall network performance and stability are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118869581B_ABST
    Figure CN118869581B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of network communication, and discloses a network communication system, method, device, electronic device and storage medium, comprising: when a local switch detects an access address of an independent terminal device, according to the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch, a target announcement route is generated, and the target announcement route is sent to each remote switch; when the remote switch obtains a message to be sent to the independent terminal device, tunnel encapsulates the message to be sent according to the target announcement route to obtain a tunnel message; by allowing the target announcement route sent by the local switch to carry the globally unique tunnel endpoint address of the local switch, the remote switch can use the globally unique tunnel endpoint address of the local switch as the outer destination address of the message to be sent according to the target announcement route, so as to ensure that the traffic forwarding path is the shortest and optimal path, thereby improving data communication efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of network communication technology, and in particular to a network communication system, method, device, electronic device and storage medium. Background Art

[0002] At present, switches play a vital role in network communication systems, mainly including the connection of terminal devices, data forwarding and network expansion. Therefore, how to ensure the high availability of switches in the system has always been a key research topic.

[0003] In related technologies, two or more switches are usually negotiated with the connected device for link aggregation, so that these switches become neighbor switches in a cross-device link aggregation group. From the perspective of the connected device, the neighbor switches on the other end are virtualized into a single switch, thereby improving reliability from the link level to the device level.

[0004] However, after two or more switches establish a neighbor relationship, the external access addresses of these neighbor switches are the same. When any switch is connected to an independent terminal device, when the remote device sends a data message to the independent terminal device, it is often sent to its neighbor switch, and then forwarded to the switch by its neighbor switch, which increases the transmission path length of the data message and reduces data communication efficiency. Summary of the Invention

[0005] The present application provides a network communication system, method, device, electronic device and storage medium to address the defects of related technologies such as reduced data communication efficiency.

[0006] A first aspect of the present application provides a network communication system, comprising: a local switch and a remote switch; the local switch is connected to a plurality of neighbor switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switches;

[0007] The local switch is configured to, upon detecting an access address of an independent terminal device, generate a target advertisement route according to the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch, and send the target advertisement route to each of the remote switches;

[0008] The remote switch is configured to receive the target advertised route and, upon obtaining a message to be sent to the independent terminal device, perform tunnel encapsulation on the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertised route and the access address of the independent terminal device, thereby obtaining a tunnel message; wherein the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0009] In an optional implementation manner, the remote switch is further configured to:

[0010] After receiving the target advertisement route, determining whether a network communication tunnel is established with the local switch based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route;

[0011] When it is determined that no network communication tunnel is established with the local switch, a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel with the local switch.

[0012] In an optional implementation manner, the local switch is configured to:

[0013] When an access address of any connected device is detected, determining whether the connected device is an independent terminal device according to the connection port type of the connected device;

[0014] In the case where it is determined that the connecting device is an independent terminal device, generating a target advertisement route according to the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch;

[0015] The independent terminal device is connected to the local switch via an independent port, and data packets sent to the independent terminal device must be forwarded via the local switch.

[0016] In an optional implementation manner, the local switch is further configured to:

[0017] When it is determined that the connecting device is not an independent terminal device, a common advertisement route is generated according to the access address of the connecting device, and the common advertisement route is sent to each of the remote switches.

[0018] In an optional implementation manner, the local switch is further configured to:

[0019] The access address of the connected device is synchronized to the neighbor switch, so that the neighbor switch generates a common advertisement route according to the access address of the connected device, and sends the common advertisement route to each of the remote switches.

[0020] In an optional implementation manner, the remote switch is further configured to:

[0021] receiving a common advertisement route sent by the local switch or the neighboring switch;

[0022] When a message to be sent to the connection device is obtained, tunnel encapsulation is performed on the message to be sent according to the unified tunnel endpoint address of the local switch and the neighbor switch and the access address of the connection device to obtain a tunnel message;

[0023] The outer destination address of the tunnel message is the unified tunnel endpoint address.

[0024] In an optional embodiment, the system further includes:

[0025] The uplink switch is configured to receive the tunnel message sent by the remote switch, and, when the outer destination address of the tunnel message is a unified tunnel endpoint address of the local switch and the neighboring switch, send the tunnel message to the local switch or the neighboring switch, so that the tunnel message is forwarded to the connected device through the local switch or the neighboring switch according to the access address of the connected device.

[0026] In an optional embodiment, the system further includes:

[0027] The uplink switch is configured to receive the tunnel message sent by the remote switch, and when the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch, send the tunnel message to the local switch, so as to forward the tunnel message to the independent terminal device through the local switch.

[0028] In an optional implementation manner, the uplink switch is further configured to:

[0029] In the event that an uplink communication link of the local switch fails, the tunnel message is sent to a corresponding neighboring switch, so that the tunnel message is forwarded to the local switch through the neighboring switch.

[0030] In an optional implementation manner, the uplink switch is configured to:

[0031] In the event of a failure of an uplink communication link of the local switch, sending system link information to a dynamic router, so that the dynamic router determines a best alternative path to the local switch based on the system link information;

[0032] According to the best candidate path, the tunnel message is sent to the corresponding neighbor switch, so that the tunnel message is forwarded to the local switch through the neighbor switch.

[0033] In an optional implementation manner, the neighbor switch is configured to:

[0034] The tunnel message is forwarded to the local switch via a peer link between the local switch and the tunnel message.

[0035] In an optional implementation manner, the local switch is further configured to:

[0036] When the access address of the external network device is detected, a target external advertisement route is generated according to the access address of the external network device and the globally unique tunnel endpoint address of the local switch, and the target external advertisement route is sent to each of the remote switches.

[0037] In an optional implementation manner, the remote switch is further configured to:

[0038] receiving the target external advertisement route;

[0039] When a message to be sent to the external network device is obtained, tunnel encapsulating the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target external advertisement route and the access address of the external network device to obtain a tunnel message;

[0040] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0041] In an optional implementation manner, the local switch is configured to:

[0042] The target announcement route or target external announcement route is sent to the upstream switch, so that the target announcement route or target external announcement route is forwarded to each switch in the system except the local switch through the upstream switch, so that each remote switch obtains the target announcement route or target external announcement route.

[0043] In an optional implementation manner, the neighbor switch is further configured to:

[0044] When obtaining the target announcement route or target external announcement route forwarded by the upstream switch, if the target identifier carried in the target announcement route or the target external announcement route is the same as its own target identifier, it is determined that the target announcement route or the target external announcement route is generated by a local switch that has established a cross-device link aggregation group neighbor relationship, and the target announcement route or the target external announcement route is discarded.

[0045] A second aspect of the present application provides a network communication method, applied to a local switch, wherein the local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches. The method includes:

[0046] generating a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch when the access address of the independent terminal device is detected;

[0047] sending the target advertisement route to each remote switch, so that when the remote switch receives a message to be sent to the independent terminal device, the remote switch performs tunnel encapsulation on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message;

[0048] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0049] A third aspect of the present application provides a network communication method, applied to a remote switch, the method comprising:

[0050] receiving a target advertisement route sent by a local switch; wherein, upon detecting an access address of an independent terminal device, the local switch generates a target advertisement route based on the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch, wherein the local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches;

[0051] When a message to be sent to the independent terminal device is obtained, tunnel encapsulation is performed on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message;

[0052] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0053] A fourth aspect of the present application provides a network communication device, applied to a local switch, wherein the local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches. The device includes:

[0054] a generating module configured to generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch when the access address of the independent terminal device is detected;

[0055] a first communication module configured to send the target advertisement route to each remote switch, so that when the remote switch receives a message to be sent to the independent terminal device, the remote switch performs tunnel encapsulation on the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message;

[0056] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0057] A fifth aspect of the present application provides a network communication device, applied to a remote switch, comprising:

[0058] a receiving module, configured to receive a target advertisement route sent by a local switch; wherein, upon detecting an access address of an independent terminal device, the local switch generates a target advertisement route based on the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch; the local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches;

[0059] a second communication module configured to, upon receiving a message to be sent to the independent terminal device, perform tunnel encapsulation on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device, to obtain a tunnel message;

[0060] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0061] A sixth aspect of the present application provides an electronic device, comprising: at least one processor and a memory;

[0062] The memory stores computer-executable instructions;

[0063] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the method described in the second aspect and various possible designs of the second aspect or the method described in the third aspect and various possible designs of the third aspect.

[0064] The seventh aspect of the present application provides a computer-readable storage medium, which stores computer-executable instructions. When a processor executes the computer-executable instructions, it implements the method described in the second aspect and various possible designs of the second aspect or the method described in the third aspect and various possible designs of the third aspect.

[0065] The eighth aspect of the present application provides a computer program product, including computer instructions, which are used to enable a computer to execute the method described in the second aspect and various possible designs of the second aspect or the method described in the third aspect and various possible designs of the third aspect.

[0066] The technical solution of this application has the following advantages:

[0067] The present application provides a network communication system, method, apparatus, electronic device, and storage medium, the system comprising: a local switch and a remote switch; the local switch being connected to a plurality of neighboring switches, and establishing a cross-device link aggregation group neighbor relationship between the local switch and the neighboring switches. The local switch is configured to, upon detecting an access address of an independent terminal device, generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch, and send the target advertisement route to each remote switch; the remote switch is configured to receive the target advertisement route, and upon receiving a message to be sent to the independent terminal device, tunnel encapsulate the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device, thereby obtaining a tunnel message; wherein the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch. The system provided by the above solution allows the local switch to carry the globally unique tunnel endpoint address of the local switch in the target advertisement route sent by the local switch, so that the remote switch can use the globally unique tunnel endpoint address of the local switch as the outer destination address of the message to be sent based on the target advertisement route, thereby ensuring that the traffic forwarding path is the shortest and optimal path, thereby improving data communication efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following is a brief introduction to the drawings required for use in the embodiments or related technical descriptions. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can also be obtained based on these drawings.

[0069] Figure 1 A schematic diagram of the network structure of a cross-device link aggregation group switch provided in an embodiment of the present application;

[0070] Figure 2 A schematic diagram of the interaction flow of the network communication system provided in an embodiment of the present application;

[0071] Figure 3 A schematic diagram of the structure of the VXLAN control plane provided in an embodiment of the present application;

[0072] Figure 4A schematic diagram of the structure of an exemplary network communication system provided in an embodiment of the present application;

[0073] Figure 5 A schematic diagram of the extended community attribute data structure provided in an embodiment of the present application;

[0074] Figure 6 A schematic diagram of the routing process of a remote switch provided in an embodiment of the present application;

[0075] Figure 7 A flowchart of a network communication method is provided for an embodiment of the present application;

[0076] Figure 8 A flowchart of another network communication method is provided for an embodiment of the present application;

[0077] Figure 9 A schematic diagram of the structure of a network communication device provided in an embodiment of the present application;

[0078] Figure 10 A schematic diagram of the structure of another network communication device provided in an embodiment of the present application;

[0079] Figure 11 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0080] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present disclosure in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION

[0081] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0082] In addition, the terms "first," "second," etc. are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. In the description of the following embodiments, "plurality" means more than two, unless otherwise specifically defined.

[0083] In related technologies, two or more switches are usually negotiated with the connected device for link aggregation, so that these switches become neighbor switches in a cross-device link aggregation group. From the perspective of the connected device, the neighbor switches at the other end are virtualized into one switch, thereby improving reliability from the link level to the device level. Figure 1 The figure shows a network structure diagram of a multi-chassis link aggregation group switch provided in an embodiment of the present application. A multi-chassis link aggregation group (MCLAG) is a cross-device link aggregation mechanism. Switches PE1 and PE2 negotiate link aggregation across devices with switch CE1. If either PE1 or PE2 fails, traffic can be rapidly switched to the other device, avoiding network disruption caused by a single point of failure. After the two devices establish a neighbor relationship, they elect an active and standby switch. The standby switch modifies the MAC address of all MCLAG member ports on its device to the same as the system MAC address of the active device. Assume that PE2 is the active (main switch) and PE1 is the standby (backup switch). Once the neighbor relationship is established, PE1 modifies the MAC address corresponding to the MCLAG member port on its device to the system MAC address of PE2. This allows LACP PDUs sent from PE1's member ports to have the same source MAC address as PE2, making CE1 appear to receive packets from the same device (the virtual PE).

[0084] However, after two or more switches establish a neighbor relationship, the external access addresses of these neighbor switches are the same. When any switch is connected to an independent terminal device, when the remote device sends a data message to the independent terminal device, it is often sent to its neighbor switch, and then forwarded to the switch by its neighbor switch, which increases the transmission path length of the data message and reduces data communication efficiency.

[0085] In response to the above-mentioned problems, embodiments of the present application provide a network communication system, method, apparatus, electronic device, and storage medium, the system comprising: a local switch and a remote switch; the local switch being connected to a plurality of neighboring switches, and establishing a cross-device link aggregation group neighbor relationship between the local switch and the neighboring switches. The local switch is configured to, upon detecting an access address of an independent terminal device, generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch, and send the target advertisement route to each remote switch; the remote switch is configured to receive the target advertisement route, and upon obtaining a message to be sent to the independent terminal device, tunnel encapsulate the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device, thereby obtaining a tunnel message; wherein the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch. The system provided by the above solution allows the local switch to carry the globally unique tunnel endpoint address of the local switch in the target advertisement route sent by the local switch, so that the remote switch can use the globally unique tunnel endpoint address of the local switch as the outer destination address of the message to be sent based on the target advertisement route, thereby ensuring that the traffic forwarding path is the shortest and optimal path, thereby improving data communication efficiency.

[0086] The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. The following describes the embodiments of the present invention in conjunction with the accompanying drawings.

[0087] An embodiment of the present application provides a network communication system for ensuring that a communication path between switches is the shortest path, thereby improving communication efficiency between switches.

[0088] like Figure 2 As shown, it is a schematic diagram of the interaction process of the network communication system provided in an embodiment of the present application, which includes: a local switch and a remote switch; the local switch is connected to several neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches.

[0089] The local switch is configured to, upon detecting the access address of an independent terminal device, generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch, and send the target advertisement route to each remote switch. The remote switch is configured to receive the target advertisement route and, upon receiving a message to be sent to the independent terminal device, tunnel encapsulate the message to be sent based on the globally unique tunnel endpoint address of the local switch and the access address of the independent terminal device as represented by the target advertisement route, thereby obtaining a tunnel message. The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0090] It should be noted that in a network communication system, if a local switch establishes a cross-device link aggregation group neighbor relationship with several neighboring switches, the local switch and the neighboring switches will have the same unified tunnel endpoint address. At the same time, the local switch and the neighboring switches will also have different globally unique tunnel endpoint addresses. The advertised route is a Type 2 route (MAC / IP Advertisement Route) and is mainly used to advertise MAC routes or IP+MAC host routes. The message format is as follows:

[0091]

[0092] Specifically, when an independent terminal device with a network connection to a local switch uses the local switch to communicate externally, the local switch detects the independent terminal device's access address and generates a target advertisement route based on the independent terminal device's access address and the local switch's globally unique tunnel endpoint address. The remote switch then tunnels the message, using the local switch's globally unique tunnel endpoint address as the outer destination address. This allows the remote switch to forward the tunnel message to the local switch based on the outer destination address, avoiding neighboring switches. This ensures that the traffic forwarding path is the shortest and most optimal, thereby improving data communication efficiency.

[0093] Based on the above embodiment, as an implementable manner, in one embodiment, the remote switch is further configured to:

[0094] After receiving the target advertisement route, the network communication tunnel is determined to be established with the local switch based on the globally unique tunnel endpoint address of the local switch indicated by the target advertisement route. If it is determined that the network communication tunnel is not established with the local switch, a network communication tunnel is established with the local switch based on the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel between the network communication tunnel and the local switch.

[0095] It's important to note that Virtual eXtensible Local Area Network (VXLAN) technology effectively addresses the inability of current VLAN technology to meet the needs of large-scale Layer 2 networks. VXLAN is a Layer 2 virtual network technology that introduces a UDP-formatted outer tunnel as the data link layer, with the original datagram content being transmitted as the tunnel payload. Because UDP is used as the outer layer transport, the payload data can be easily transmitted across Layer 2 and Layer 3 networks. VXLAN has become a mainstream virtual network technology. The original VXLAN solution lacked a control plane; instead, VXLAN tunnels were manually configured and host addresses were learned through traffic flooding. This approach is relatively simple to implement, but it results in a high volume of flooded traffic and makes network expansion difficult.

[0096] To solve the above problems, EVPN (Ethernet VPN) is introduced into VXLAN as the control plane of VXLAN. Figure 3 Figure 1 shows a schematic diagram of the VXLAN control plane structure provided by an embodiment of the present application. (VXLAN is a Network Virtualization Overlay (NVO) protocol.) EVPN references the BGP / MPLS IP VPN mechanism and defines several new BGP EVPN routes by extending the BGP protocol. By publishing EVPN routes in the network, it enables automatic VTEP discovery, host address learning, and other behaviors. Using EVPN as the VXLAN control plane has the following advantages: it enables automatic VTEP discovery and VXLAN tunnel establishment, thereby reducing the difficulty of network deployment and expansion; EVPN can simultaneously publish Layer 2 MAC and Layer 3 routing information; and it can reduce network flooding.

[0097] Among them, for Figure 3MP-BGP (Multiprotocol Border Gateway Protocol) is a border gateway protocol used to exchange routing information between autonomous systems (ASs). It supports multiple network layer protocols, such as IPv4, IPv6, and VPN. EVPN (Ethernet VPN) is an Ethernet-based VPN technology used to provide Layer 2 virtual network services in data centers and enterprise networks. EVPN enables Layer 2 interconnection between different sites, as well as isolation and inter-tenant access. RFC 7430 is the standard document for EVPN, defining the protocol specifications and functional requirements of EVPN. It specifies the operation of the control and data planes of EVPN, including route advertisement, MAC address learning, and ARP proxy. MP-BGP EVPN-RFC 7430 refers to EVPN technology based on the MP-BGP protocol and complies with the provisions of the RFC 7430 standard document. For the data plane, NVO stands for Network Virtualization Overlay, which means network virtualization overlay in Chinese. It is a network virtualization technology that virtualizes and isolates network resources by creating a logical overlay network on an existing physical network. Draft-ietf-bess-evpn-overlay is an Internet Engineering Task Force (IETF) draft that describes a network virtualization overlay technology based on EVPN (EthernetVPN). EVPN is a technology used to implement Layer 2 virtual networks in data centers and enterprise networks, providing efficient MAC address learning and forwarding, as well as flexible tenant isolation and inter-access control. The draft proposes an EVPN-based network virtualization overlay architecture that can create multiple logical overlay networks on an existing physical network. Each overlay network can be independently configured and managed, achieving isolation and inter-access between tenants. The draft also defines the control plane and data plane protocols for the EVPN overlay network, as well as related management and configuration mechanisms. Overall, the draft proposes an EVPN-based network virtualization overlay technology that can provide efficient and flexible Layer 2 virtual network services for data centers and enterprise networks.

[0098] EVPN type 3 (Inclusive Multicast Ethernet Route) is used to automatically discover VTEP addresses and automatically create VXLAN tunnels. Its message format is as follows:

[0099]

[0100] The originating router's IP address is the VTEP address of the local switch. After receiving the type 3 route, the peer can establish a VXLAN tunnel with the local VTEP address. The VTEP address is also the globally unique tunnel endpoint address in the above embodiment.

[0101] In actual implementation, when a switch receives a Type 2 or Type 5 route from a peer, it attempts to establish a VXLAN tunnel with the peer. However, it must infer the peer's VTEP address and establish the tunnel with that address. Different vendors may have different implementations, which can lead to discrepancies in the calculation results and incompatibility, ultimately resulting in tunnel establishment not meeting expectations.

[0102] Specifically, in order to further improve the efficiency and reliability of tunnel construction, the embodiment of the present application encapsulates the globally unique tunnel endpoint address into the target announcement route (type 2 route) to omit the inference calculation process of the peer VTEP address.

[0103] Based on the above embodiment, as an implementable manner, based on the above embodiment, in one embodiment, the local switch is configured to:

[0104] When the access address of any connected device is detected, it is determined whether the connected device is an independent terminal device based on the connection port type of the connected device; when it is determined that the connected device is an independent terminal device, a target announcement route is generated based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch.

[0105] The independent terminal device is connected to the local switch via an independent port, and data packets sent to the independent terminal device must be forwarded through the local switch.

[0106] It should be noted that an independent terminal device refers to a device that has a connection relationship only with the local switch and has no connection relationship with the neighboring switches of the local switch. That is, the independent terminal device cannot communicate directly with the neighboring switches.

[0107] Specifically, if the connection port type of the connected device is an orphan port (independent port), the connected device is determined to be an independent terminal device. Since data packets sent to the independent terminal device must pass through the local switch, a target announcement route is generated based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch to prevent tunnel packets sent by the remote switch from being sent to the neighboring switch.

[0108] Specifically, in one embodiment, the local switch is further configured to generate a common advertisement route based on the access address of the connected device when determining that the connected device is not an independent terminal device, and send the common advertisement route to each remote switch.

[0109] For example, Figure 4 Figure 1 shows a schematic diagram of the structure of an exemplary network communication system provided by an embodiment of the present application. Switch 1 through Switch 8 represent eight switches, and PC 1 through PC 4 represent four terminal devices. Switch 1 and Switch 2 are MCLAG neighbors, with a peerlink of PortChannel 4000. To their downstream devices, Switch 7 and PC 1, they appear to be the same switch. Switch 3 and Switch 4 are MCLAG neighbors, with a peerlink of PortChannel 4000. To their downstream devices, Switch 8, PC 2, and PC 3, they appear to be the same switch. Switch 1, Switch 2, Switch 3, and Switch 4 serve as gateways for their downstream devices. When supporting VM migration, their gateway addresses are configured identically: VLAN 100 192.168.10.1 / 24 and VLAN 1000 192.168.20.1 / 24, respectively. Take Switch4 as an example. PC4 is an independent terminal device for the local switch. PC4 is only connected to Switch4. In MCLAG terminology, it is called a terminal connected through the orphan port. Switch8 is not an independent terminal device for the local switch. Figure 4 As can be seen from the figure, the communication paths for the data packets to be sent to Switch8, forwarded by the local switch Switch4, and forwarded by the neighboring switch Switch3, are of equal length. Therefore, if it is determined that the connected device is not an independent terminal device, a normal advertisement route can be generated based on the access address of the connected device.

[0110] Specifically, in one embodiment, the local switch is further configured to synchronize the access address of the connected device to the neighboring switch, so that the neighboring switch generates a common advertisement route according to the access address of the connected device and sends the common advertisement route to each remote switch.

[0111] Specifically, the local switch synchronizes the access address (MAC address) of the connected device to the neighboring switch through ICCP. At this time, both can generate common advertising routes to improve the reachability of the common advertising routes and ensure that the remote switch can receive the common advertising routes.

[0112] Specifically, in Figure 4In the typical MCLAG+EVPN topology shown, when Switch4 learns the MAC address (access address) of a connected device, it synchronizes the MAC address with its peer (Switch3) using the MCLAG ICCP protocol and generates a Type 2 route that it advertises to remote Switch1 and Switch2. Upon receiving the MAC address synchronization message from Switch4, the MCLAG peer (Switch3) distributes the MAC address on peerlink (Portchannel4000) and generates a Type 2 route (a standard advertisement route) that it advertises to remote Switch1 and Switch2.

[0113] Accordingly, in one embodiment, the remote switch is further configured to receive a common advertisement route sent by a local switch or a neighboring switch; upon receiving a message to be sent to a connected device, the remote switch performs tunnel encapsulation on the message to be sent according to the unified tunnel endpoint address of the local switch and the neighboring switch and the access address of the connected device to obtain a tunnel message.

[0114] The outer destination address of the tunnel message is the unified tunnel endpoint address.

[0115] For example, Figure 4 As shown in the figure, the unified tunnel endpoint address of Switch4 and Switch3 is 10.254.0.16, and the globally unique tunnel endpoint address of Switch4 is 10.254.0.17.

[0116] The loopback0 (globally unique tunnel endpoint address) between Switch1 and Switch6 is configured with different IP addresses. This is used to establish EBGP peer relationships (Switch5 and Switch6 establish EBGP peer relationships with Switch1, Switch2, Switch3, and Switch4, respectively) and to transfer EVPN routes. The loopback1 (unified tunnel endpoint address) on Switch1 and Switch2 is configured with the same IP address (10.254.0.12). The loopback1 on Switch3 and Switch4 is also configured with the same IP address (10.254.0.16). Loopback1 serves as the VTEP source IP address. When establishing a VXLAN tunnel, Switch1 and Switch2 appear to be the same remote VTEP (10.254.0.12), and Switch3 and Switch4 appear to be the same remote VTEP (10.254.0.16).

[0117] Furthermore, in one embodiment, the system also includes an uplink switch for receiving a tunnel message sent by a remote switch, and sending the tunnel message to the local switch or the neighboring switch when the outer destination address of the tunnel message is a unified tunnel endpoint address of the local switch and the neighboring switch, so that the tunnel message is forwarded to the connected device through the local switch or the neighboring switch according to the access address of the connected device.

[0118] Specifically, Switch1 and Switch2 receive Type 2 and Type 3 routes from Switch3 or Switch4, respectively. Their remote VTEPs point to the same address (10.254.0.16). When PC1 sends a packet to PC4, Switch1 or Switch2 tunnels the packet, using the outer tunnel IP address as the remote VTEP address (10.254.0.16). When the tunneled packet reaches the spine switch (Switch5 or Switch6), a route lookup is performed based on the destination IP address (10.254.0.16). The destination address 10.254.0.16 has two outbound interfaces, one pointing to Switch3 and the other to Switch4. When ECMP is supported, traffic is evenly distributed from the two interfaces to Switch3 and Switch4. When ECMP is not supported, traffic is sent to either Switch3 or Switch4. Switch3 or Switch4 then forwards the tunnel packets to the connected device based on the access address of the connected device.

[0119] Accordingly, in one embodiment, the upstream switch is configured to receive a tunnel message sent by a remote switch, and when the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch, send the tunnel message to the local switch, so that the tunnel message is forwarded to the independent terminal device through the local switch.

[0120] in, Figure 4 Switch5 and Switch6 in the figure are the uplink switches.

[0121] Furthermore, in one embodiment, the uplink switch is further configured to send the tunnel message to the corresponding neighbor switch when the uplink communication link of the local switch fails, so that the tunnel message is forwarded to the local switch through the neighbor switch.

[0122] Specifically, when uplinks 29 (Ethernet 29) and 35 (Ethernet 35) on Switch 4 fail (for example, go down), traffic is sent to Switch 3, and then sent from Switch 3's peerlink to Switch 4. That is, the neighboring switch forwards tunnel packets to the local switch through the peerlink between the neighboring switch and the local switch. The peerlink then serves as a backup path.

[0123] When Switch3 receives traffic from Switch5 or Switch6, because the port corresponding to the destination MAC (the access address of the independent terminal device) points to the peerlink, Switch3 still needs to forward the traffic from the peerlink to Switch4, and finally Switch4 forwards the traffic to the independent terminal device.

[0124] Specifically, in one embodiment, the uplink switch is configured to, in the event of a failure in the uplink communication link of the local switch, send system link information to the dynamic router, so that the dynamic router can determine the best alternative path to the local switch based on the system link information; and send the tunnel message to the corresponding neighbor switch based on the best alternative path, so that the neighbor switch can forward the tunnel message to the local switch.

[0125] The system link information includes at least the path distance between each switch in the system, and may also include link status, link bandwidth, link delay, etc. Figure 4 All interfaces on Switch1 to Switch6 are configured with the OSPF routing protocol to ensure route reachability. However, the OSPF cost of the peerlink needs to be configured to a larger value to ensure that the peerlink serves only as a backup link for traffic forwarding.

[0126] Specifically, when the local switch has multiple neighbor switches, the path from each neighbor switch to the local switch can be determined based on the system link information based on the dynamic router (OSPF). The shortest path is then used as the best alternative path, and the tunnel message is sent to the neighbor switch corresponding to the best alternative path to maximize the system communication efficiency.

[0127] Based on the above embodiment, as an implementable manner, in one embodiment, the local switch is further configured to, upon detecting an access address of an external network device, generate a target external advertisement route based on the access address of the external network device and the globally unique tunnel endpoint address of the local switch, and send the target external advertisement route to each remote switch.

[0128] Among them, the externally advertised route is the Type 5 route. The Type 5 route (IP Prefix Route) is mainly used to advertise external routes. The message format is as follows:

[0129]

[0130] It's important to note that Type 2 and Type 5 routes lack the OriginatingRouter's IP Address field, similar to the OriginatingRouter's IP Address field in Type 3 routes, to indicate the local VTEP address. Therefore, when a peer receives a Type 2 or Type 5 route and attempts to establish a tunnel, it must infer the remote VTEP address and establish a tunnel with it. Different vendors may implement different solutions, potentially leading to discrepancies and incompatibility in the calculation results. Ultimately, tunnel establishment may not meet expectations.

[0131] In order to solve this technical problem, the present application generates a target external announcement route based on the access address of the external network device and the globally unique tunnel endpoint address of the local switch, and sends the target external announcement route to each remote switch to encapsulate the globally unique tunnel endpoint address of the local switch into the external announcement route to obtain the target external announcement route.

[0132] Specifically, the embodiment of the present application actually adds a new BGP extended community attribute, which is carried in type2 and type5 routes and is used to indicate the VTEP address (globally unique tunnel endpoint address of the local switch) corresponding to the current route. Figure 5 As shown, it is a schematic diagram of the extended community attribute data structure provided in an embodiment of the present application, where Type is 0x06, indicating EVPN; Sub-Type selects a value that is not currently in use, such as 0x0e, indicating that the subtype is a VTEP address; when the Flags value is 0, it indicates an IPv4 address, and when the value is 1, it indicates an IPv6 address; Originating Router's IPAddress indicates the VTEP address.

[0133] Accordingly, in one embodiment, the remote switch is further configured to receive a target external advertisement route; upon obtaining a message to be sent to an external network device, the remote switch performs tunnel encapsulation on the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target external advertisement route and the access address of the external network device to obtain a tunnel message.

[0134] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0135] It should be noted that the external network device may specifically refer to a network endpoint, such as a website server.

[0136] Specifically, if Figure 6 The figure shows a schematic diagram of the routing processing flow of a remote switch provided by an embodiment of the present application. The switch first receives a type 2 or type 5 route and interprets the extended community attribute carried in the route. If Type = 0x06 and Sub_Type = 0x0e, it indicates a VTEP address. The switch then interprets the Flags field. If it is 0, the switch reads the IPv4 address that follows it, and if it is 1, the switch reads the IPv6 address that follows it. (The extended community attribute is an optional transitional attribute that provides forward compatibility: if the switch does not recognize it, it can simply ignore it without causing an exception.) The switch then checks whether a corresponding VXLAN tunnel already exists based on the read IPv4 or IPv6 address. If not, the switch creates a tunnel. Type 2 or type 5 routes carry an Originating Router's IP Address field similar to that in type 3 routes to indicate the local VTEP address. When the remote end receives the type 2 or type 5 route, it can directly establish a tunnel with the remote end based on the read IPv4 or IPv6 VTEP address. This eliminates the need for any inference or calculation, and can be implemented uniformly across different vendors, thus preventing incompatibilities caused by calculation errors.

[0137] Specifically, in one embodiment, the local switch is configured to send the target advertisement route or the target external advertisement route to the upstream switch, so that the upstream switch forwards the target advertisement route or the target external advertisement route to each switch in the system other than the local switch, so that each remote switch obtains the target advertisement route or the target external advertisement route.

[0138] For example, Figure 4As shown in the figure, Switch4 learns PC4's MAC address and generates a Type 2 route for PC4's MAC address. It determines that the MAC address was learned from the orphan port. The VTEP extended community attribute carried in the generated Type 2 route contains a globally unique IP address (such as the BGP router-id, in this example, the loopback0 address 10.254.0.17). Switch4 synchronizes PC4's MAC address to Switch3 via ICCP. Switch3 receives PC4's MAC address from Switch4 via ICCP and recognizes that it was learned from the orphan port. It directs the egress port corresponding to the MAC address to the peerlink. Switch3 determines that the MAC address was learned from the orphan port synchronized from the MCLAG peer and does not generate a Type 2 route for the MAC address. Switch1 and Switch2 receive the Type 2 route sent by Switch4. The destination MAC address is PC4's MAC address and the remote VTEP address is 10.254.0.17.

[0139] Accordingly, in one embodiment, the neighbor switch is further configured to, upon obtaining a target advertisement route or a target external advertisement route forwarded by an upstream switch, determine that the target advertisement route or the target external advertisement route is generated by a local switch with which a cross-device link aggregation group neighbor relationship is established, and discard the target advertisement route or the target external advertisement route, if the target identifier carried in the target advertisement route or the target external advertisement route is the same as its own target identifier.

[0140] Specifically, Switch3 receives a type 2 route from Switch4 (via Switch5 or Switch6), with the destination MAC address being the MAC address of PC4 and the remote VTEP address being 10.254.0.17. Because the AS 300 carried in the route is the same as the AS number of this switch, this route is discarded. That is, Switch3 does not establish a tunnel with Switch4 whose remote VTEP address is 10.254.0.17.

[0141] PC1 then sends a packet to PC4, with the destination MAC address of PC4. Switch1 or Switch2 tunnels the packet, with the destination IP address of the tunnel outer layer being the remote VTEP address 10.254.0.17. When the tunneled packet reaches the spine switch (Switch5 or Switch6), a route lookup is performed based on the destination IP address (10.254.0.17). The outbound interface corresponding to the destination address 10.254.0.17 points to Switch4, and the traffic is then forwarded to Switch4, following the optimal forwarding path. If uplinks 29 (Ethernet 29) and 35 (Ethernet 35) on Switch4 fail (for example, go down), OSPF routes are recalculated. The outbound interface of the route for the destination IP address (10.254.0.17) on the spine switch (Switch5 or Switch6) will be redirected to Switch3. Traffic is now sent to Switch3 and then sent through Switch3's peerlink to Switch4. Similar to the Originating Router's IP Address field in Type2 and Type5 routes, the local VTEP address is included. This allows for flexible control over how tunnels are established between the peer and local ends, further controlling traffic forwarding paths and achieving optimal traffic flow across the entire path.

[0142] The network communication system provided by an embodiment of the present application includes: a local switch and a remote switch; the local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches. The local switch is configured to, upon detecting an access address of an independent terminal device, generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch, and send the target advertisement route to each remote switch; the remote switch is configured to receive the target advertisement route, and upon receiving a message to be sent to the independent terminal device, tunnel encapsulate the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device, thereby obtaining a tunnel message; wherein the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch. The system provided by the above scheme improves data communication efficiency by allowing the target advertisement route sent by the local switch to carry the globally unique tunnel endpoint address of the local switch, so that the remote switch can use the globally unique tunnel endpoint address of the local switch as the outer destination address of the message to be sent based on the target advertisement route, thereby ensuring that the traffic forwarding path is the shortest and optimal path. In addition, by ensuring that all network traffic follows the optimal forwarding path, the traffic forwarding performance of the entire network can be significantly improved, traffic congestion and equipment resource consumption can be reduced, the performance and stability of the entire network can be greatly improved, and users can have a better user experience.

[0143] The present invention provides a network communication method for ensuring that the communication path between switches is the shortest path, thereby improving the communication efficiency between the switches. The embodiment of the present invention is performed by a local switch, which is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches.

[0144] like Figure 7 FIG. 1 is a flow chart of a network communication method according to an embodiment of the present application, the method comprising:

[0145] Step 701: When an access address of an independent terminal device is detected, a target advertisement route is generated according to the access address of the independent terminal device and a globally unique tunnel endpoint address of a local switch.

[0146] In step 702, the target advertisement route is sent to each remote switch, so that when the remote switch receives a message to be sent to the independent terminal device, it tunnel-encapsulates the message to be sent based on the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message.

[0147] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0148] Regarding the network communication method in this embodiment, the specific implementation of each step has been described in detail in the embodiment of the system and will not be elaborated here.

[0149] The network communication method provided in the embodiment of the present application is applied to the local switch in the system provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.

[0150] The embodiment of the present application provides a network communication method for ensuring that the communication path between switches is the shortest path, thereby improving the communication efficiency between switches. The embodiment of the present application is performed by a remote switch.

[0151] like Figure 8 FIG. 1 is a flow chart of another network communication method provided in an embodiment of the present application, the method comprising:

[0152] Step 801: Receive a target advertisement route sent by a local switch.

[0153] Among them, when the local switch detects the access address of the independent terminal device, it generates a target announcement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch. The local switch is connected to several neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches.

[0154] Step 802: When a message to be sent to an independent terminal device is obtained, tunnel encapsulation is performed on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message.

[0155] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0156] Regarding the network communication method in this embodiment, the specific implementation of each step has been described in detail in the embodiment of the system and will not be elaborated here.

[0157] The network communication method provided in the embodiment of the present application is applied to the remote switch in the system provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.

[0158] An embodiment of the present application provides a network communication device for executing the network communication method applied to a local switch provided in the above embodiment.

[0159] like Figure 9FIG. 1 is a schematic diagram of a network communication device according to an embodiment of the present invention. The network communication device 90 includes a generation module 901 and a first communication module 902 .

[0160] The generation module is configured to, upon detecting the access address of the independent terminal device, generate a target advertisement route based on the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch. The first communication module is configured to send the target advertisement route to each remote switch, so that upon receiving a message to be sent to the independent terminal device, the remote switch performs tunnel encapsulation on the message to be sent based on the globally unique tunnel endpoint address of the local switch and the access address of the independent terminal device represented by the target advertisement route, thereby obtaining a tunnel message.

[0161] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0162] Regarding the network communication device in this embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0163] The network communication device provided in the embodiment of the present application is used to execute the network communication method applied to the local switch provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.

[0164] An embodiment of the present application provides a network communication device for executing the network communication method applied to a remote switch provided in the above embodiment.

[0165] like Figure 10 FIG. 1 is a schematic diagram of another network communication device according to an embodiment of the present invention. The network communication device 100 includes a receiving module 1001 and a second communication module 1002 .

[0166] The receiving module is configured to receive a target advertisement route sent by a local switch. Upon detecting an access address of an independent terminal device, the local switch generates a target advertisement route based on the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch. The local switch is connected to a plurality of neighboring switches, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighboring switches. The second communication module is configured to, upon receiving a message to be sent to the independent terminal device, tunnel encapsulate the message to be sent based on the globally unique tunnel endpoint address of the local switch and the access address of the independent terminal device represented by the target advertisement route to obtain a tunnel message.

[0167] The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

[0168] Regarding the network communication device in this embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0169] The network communication device provided in the embodiment of the present application is used to execute the network communication method applied to the remote switch provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.

[0170] An embodiment of the present application provides an electronic device for executing the network communication method provided in the above embodiment.

[0171] like Figure 11 FIG. 1 is a schematic diagram of the structure of an electronic device according to an embodiment of the present application. The electronic device 110 includes at least one processor 1101 and a memory 1102 .

[0172] The memory stores computer-executable instructions; at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the network communication method provided in the above embodiment.

[0173] The electronic device provided in the embodiment of the present application is used to execute the network communication method provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.

[0174] An embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the network communication method provided in any of the above embodiments is implemented.

[0175] The storage medium containing computer-executable instructions provided in the embodiments of the present application can be used to store computer-executable instructions of the network communication method provided in the aforementioned embodiments. Its implementation method and principle are the same and will not be repeated here.

[0176] An embodiment of the present application provides a computer program product, including computer instructions, which are used to enable a computer to execute the network communication method provided in the aforementioned embodiment.

[0177] The embodiments of the present application provide computer program products that can be used to execute computer instructions of the network communication methods provided in the aforementioned embodiments. The implementation method and principle are the same and will not be repeated here.

[0178] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0179] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0180] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0181] The above-mentioned integrated unit implemented in the form of a software functional unit can be stored in a computer-readable storage medium. The above-mentioned software functional unit is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform some steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: USB flash drives, mobile hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, optical disks, and other media that can store program code.

[0182] Part of the present application may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the form in which the computer program instruction exists in a computer-readable medium includes but is not limited to a source file, an executable file, an installation package file, etc. Accordingly, the way in which the computer program instruction is executed by the computer includes but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium that can be accessed by the computer.

[0183] Those skilled in the art will clearly understand that for the sake of convenience and brevity, the division of the above-mentioned functional modules is only used as an example for illustration. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment and will not be repeated here.

[0184] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some or all of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A network communication system, characterized in that: include: A local switch and a remote switch; the local switch is connected to at least one neighbor switch, and a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switch; the local switch and at least one neighbor switch are provided with the same unified tunnel endpoint address, and the local switch and at least one neighbor switch are also provided with different globally unique tunnel endpoint addresses; The local switch is used to generate a target advertisement route according to the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch when the access address of the independent terminal device is detected, and send the target advertisement route to each of the remote switches; The remote switch is used to receive the target announcement route, and when obtaining a message to be sent to the independent terminal device, tunnel encapsulates the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route and the access address of the independent terminal device to obtain a tunnel message; wherein the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch; The remote switch is further used for: After receiving the target advertisement route, judging whether a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route; When it is determined that no network communication tunnel is established with the local switch, a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel with the local switch.

2. The system according to claim 1, characterized in that The local switch is used for: In case of detecting the access address of any connected device, judging whether the connected device is an independent terminal device according to the connection port type of the connected device; In the case where it is determined that the connecting device is an independent terminal device, generating a target advertisement route according to an access address of the independent terminal device and a globally unique tunnel endpoint address of a local switch; The independent terminal device is connected to the local switch via an independent port, and data packets sent to the independent terminal device must be forwarded via the local switch.

3. The system according to claim 2, characterized in that The local switch is further used for: When it is determined that the connecting device is not an independent terminal device, a common advertisement route is generated according to the access address of the connecting device, and the common advertisement route is sent to each of the remote switches.

4. The system according to claim 3, characterized in that The local switch is further used for: The access address of the connection device is synchronized to the neighbor switch, so that the neighbor switch generates a common announcement route according to the access address of the connection device, and sends the common announcement route to each of the remote switches.

5. The system according to claim 4, characterized in that The remote switch is further used for: Receiving a common advertisement route sent by the local switch or the neighbor switch; When a message to be sent to the connection device is obtained, tunnel encapsulation is performed on the message to be sent according to the unified tunnel endpoint address of the local switch and the neighbor switch and the access address of the connection device to obtain a tunnel message; The outer destination address of the tunnel message is the unified tunnel endpoint address.

6. The system according to claim 5, characterized in that The system further comprises: The upstream switch is used to receive the tunnel message sent by the remote switch, and when the outer destination address of the tunnel message is the unified tunnel endpoint address of the local switch and the neighbor switch, send the tunnel message to the local switch or the neighbor switch, so as to forward the tunnel message to the connection device through the local switch or the neighbor switch according to the access address of the connection device.

7. The system according to claim 1, characterized in that The system further comprises: The uplink switch is used to receive the tunnel message sent by the remote switch, and when the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch, send the tunnel message to the local switch, so as to forward the tunnel message to the independent terminal device through the local switch.

8. The system according to claim 7, characterized in that The uplink switch is further used for: In the case that the uplink communication link of the local switch fails, the tunnel message is sent to the corresponding neighbor switch, so that the tunnel message is forwarded to the local switch through the neighbor switch.

9. The system according to claim 8, characterized in that The uplink switch is used for: In the event of a failure of an uplink communication link of the local switch, sending system link information to a dynamic router, so that the dynamic router determines a best alternative path to the local switch based on the system link information; According to the best candidate path, the tunnel message is sent to the corresponding neighbor switch, so that the tunnel message is forwarded to the local switch through the neighbor switch.

10. The system according to claim 9, characterized in that The neighbor switch is used for: The tunnel message is forwarded to the local switch via a peer link with the local switch.

11. The system according to claim 1, characterized in that The local switch is further used for: When the access address of the external network device is detected, a target external advertisement route is generated according to the access address of the external network device and the globally unique tunnel endpoint address of the local switch, and the target external advertisement route is sent to each of the remote switches.

12. The system according to claim 11, characterized in that The remote switch is further used for: Receiving the target external advertisement route; When a message to be sent to the external network device is obtained, tunnel encapsulation is performed on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target external advertisement route and the access address of the external network device to obtain a tunnel message; The outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch.

13. The system according to claim 12, characterized in that The local switch is used for: The target announcement route or the target external announcement route is sent to the upstream switch, so that the target announcement route or the target external announcement route is forwarded to each switch in the system except the local switch through the upstream switch, so that each remote switch obtains the target announcement route or the target external announcement route.

14. The system according to claim 13, characterized in that The neighbor switch is further configured to: When the target announcement route or the target external announcement route forwarded by the upstream switch is obtained, if the target identifier carried in the target announcement route or the target external announcement route is the same as its own target identifier, it is determined that the target announcement route or the target external announcement route is generated by a local switch that has established a cross-device link aggregation group neighbor relationship, and the target announcement route or the target external announcement route is discarded.

15. A network communication method, characterized in that: Applied to a local switch, the local switch is connected to at least one neighbor switch, a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switch, the local switch and the at least one neighbor switch are provided with the same unified tunnel endpoint address, and the local switch and the at least one neighbor switch are also provided with different globally unique tunnel endpoint addresses, the method comprises: In case the access address of the independent terminal device is detected, generating a target advertisement route according to the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch; Sending the target announcement route to each remote switch, so that when the remote switch obtains the message to be sent to the independent terminal device, the remote switch performs tunnel encapsulation on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route and the access address of the independent terminal device to obtain a tunnel message; Wherein, the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch; After receiving the target announcement route, the remote switch determines whether a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route; if it is determined that no network communication tunnel is established with the local switch, the remote switch establishes a network communication tunnel with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel between the remote switch and the local switch.

16. A network communication method, characterized in that: Applied to a remote switch, the method comprises: Receive a target advertisement route sent by a local switch; wherein, when the local switch detects an access address of an independent terminal device, the local switch generates a target advertisement route according to the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch, the local switch is connected to at least one neighbor switch, a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switch, the local switch and the at least one neighbor switch are provided with the same unified tunnel endpoint address, and the local switch and the at least one neighbor switch are also provided with different globally unique tunnel endpoint addresses; When a message to be sent to the independent terminal device is obtained, tunnel encapsulation is performed on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route and the access address of the independent terminal device to obtain a tunnel message; Wherein, the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch; The method further comprises: After receiving the target advertisement route, judging whether a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route; When it is determined that no network communication tunnel is established with the local switch, a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel with the local switch.

17. A network communication device, characterized in that: Applied to a local switch, the local switch is connected to at least one neighbor switch, a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switch, the local switch and the at least one neighbor switch are provided with the same unified tunnel endpoint address, and the local switch and the at least one neighbor switch are also provided with different globally unique tunnel endpoint addresses, the device comprises: A generating module, configured to generate a target advertisement route according to the access address of the independent terminal device and the globally unique tunnel endpoint address of the local switch when the access address of the independent terminal device is detected; A first communication module, configured to send the target announcement route to each remote switch, so that when the remote switch obtains a message to be sent to the independent terminal device, the remote switch performs tunnel encapsulation on the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route and the access address of the independent terminal device to obtain a tunnel message; Wherein, the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch; After receiving the target announcement route, the remote switch determines whether a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route; if it is determined that no network communication tunnel is established with the local switch, the remote switch establishes a network communication tunnel with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel between the remote switch and the local switch.

18. A network communication device, characterized in that: Applied to a remote switch, the device comprises: A receiving module, configured to receive a target advertisement route sent by a local switch; wherein, when the local switch detects an access address of an independent terminal device, the local switch generates a target advertisement route according to the access address of the independent terminal device and a globally unique tunnel endpoint address of the local switch, the local switch is connected to at least one neighbor switch, a cross-device link aggregation group neighbor relationship is established between the local switch and the neighbor switch, the local switch and the at least one neighbor switch are provided with the same unified tunnel endpoint address, and the local switch and the at least one neighbor switch are also provided with different globally unique tunnel endpoint addresses; A second communication module is used for, when obtaining a message to be sent to the independent terminal device, tunnel encapsulating the message to be sent according to the globally unique tunnel endpoint address of the local switch represented by the target announcement route and the access address of the independent terminal device to obtain a tunnel message; Wherein, the outer destination address of the tunnel message is the globally unique tunnel endpoint address of the local switch; The receiving module or the second communication module is also used for: After receiving the target advertisement route, judging whether a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch represented by the target advertisement route; When it is determined that no network communication tunnel is established with the local switch, a network communication tunnel is established with the local switch according to the globally unique tunnel endpoint address of the local switch, so that the tunnel message is transmitted to the local switch through the network communication tunnel with the local switch.

19. An electronic device, characterized in that: include: at least one processor and memory; The memory stores computer-executable instructions; The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor performs the method according to claim 15 or 16.

20. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and when the processor executes the computer-executable instructions, the method according to claim 15 or 16 is implemented.

21. A computer program product, characterized in that The method comprises computer instructions for causing a computer to execute the method according to claim 15 or 16.

Citation Information

Patent Citations

  • Route management method and tunnel endpoint equipment

    CN113556283A