In various examples of the present disclosure, a method and apparatus for learning a MAC address in a VXLAN are provided to implement the automatic synchronization of MAC address information in a control plane. In various examples of the present disclosure, a MAC address entry obtained by triggering the MAC address learning of the data frame received from the local network is called a local MAC address entry. When the data frame is received from the tunnel, the egress interface in the configured MAC address entry is a tunnel via which the data frame is received. When the data frame is received from the local network, an egress interface in the configured MAC address entry is a physical port via which the VTEP is connected to a source terminal device sending the data frame.
When receiving a data frame from a local network or a tunnel, the VTEP learns a source MAC address of the data frame and a VXLAN corresponding to the source MAC address to an ingress interface of the data frame, and configures a MAC address entry in a MAC address forwarding table shown in Table 1. The VTEP may trigger MAC address learning when receiving a data frame. In a VXLAN, a VTEP performs MAC address learning by employing a self-learning mode in a data plane. The term “based on” means based at least in part on.
As used herein, the term “includes” means includes but not limited to, the term “including” means including but not limited to. Throughout the present disclosure, the terms “a” and “an” are intended to denote at least one of a particular element. In other instances, some methods and structures have not been described in detail so as not to unnecessarily obscure the present disclosure. It will be readily apparent however, that the present disclosure may be practiced without limitation to these specific details. In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present disclosure. 11 is a diagram illustrating a hardware structure of an apparatus for learning a MAC address according to another example of the present disclosure.DETAILED DESCRIPTIONįor simplicity and illustrative purposes, the present disclosure is described by referring mainly to an example thereof.
10 is a diagram illustrating the structure of an apparatus for learning a MAC address according to another example of the present disclosure.įIG. 9 is a diagram illustrating the structure of an apparatus for learning a MAC address according to another example of the present disclosure.įIG. 8 is a diagram illustrating the structure of an apparatus for learning a MAC address according to another example of the present disclosure.įIG. 7 is a diagram illustrating the structure of an apparatus for learning a MAC address according to an example of the present disclosure.įIG. 6A-6B is a flowchart illustrating an operation process performed by a VTEP when receiving an Intermediate System to Intermediate System (ISIS) Link State Protocol data unit (LSP) message from a peer VTEP according to an example of the present disclosure.įIG. 5 is a flowchart illustrating an operation process performed by a VTEP when a local MAC address entry is removed according to an example of the present disclosure.įIG. 4 is a diagram illustrating a format of Type Length Value (TLV) for containing a VXLAN and a MAC address corresponding to the VXLAN according to an example of the present disclosure.įIG. 3 is a flowchart illustrating an operation process performed by a VTEP when a local MAC address entry is newly added according to an example of the present disclosure.įIG. 2 is a flowchart illustrating a method for learning a MAC address according to an example of the present disclosure.įIG. 1 is a diagram illustrating the structure of a VXLAN according to an example of the present disclosure.įIG. The length of the VNI may for example be 24 bits long.BRIEF DESCRIPTION OF THE DRAWINGSįeatures of the present disclosure are illustrated by way of example and not limited in the following figure(s), in which like numerals indicate like elements, in which:įIG. A VXLAN is identified by a VXLAN Network Identifier (VNI). Any two VTEPs may communicate with each other by establishing a tunnel between them over a layer 3 network. A VTEP is an edge device of the VXLAN, and may be implemented by a physical switch or a virtual switch. For example, an initial message may be encapsulated into a UDP message.Ī VXLAN includes VXLAN Tunnel End Points (VTEPs) and a local network which may be composed of multiple terminal devices such as virtual machines. Virtual eXtensible Local Area Network (VXLAN) is an overlay network technology, in which a message is encapsulated according to a Media Access Control (MAC) in User Datagram Protocol (UDP) method.