CN113472699A - Network table item synchronization method and device - Google Patents

Network table item synchronization method and device Download PDF

Info

Publication number
CN113472699A
CN113472699A CN202110966878.0A CN202110966878A CN113472699A CN 113472699 A CN113472699 A CN 113472699A CN 202110966878 A CN202110966878 A CN 202110966878A CN 113472699 A CN113472699 A CN 113472699A
Authority
CN
China
Prior art keywords
network
entry
vsi
network device
sid
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110966878.0A
Other languages
Chinese (zh)
Inventor
王丽媛
陈建
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Security Technologies Co Ltd
Original Assignee
New H3C Security Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by New H3C Security Technologies Co Ltd filed Critical New H3C Security Technologies Co Ltd
Priority to CN202110966878.0A priority Critical patent/CN113472699A/en
Publication of CN113472699A publication Critical patent/CN113472699A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/55Prevention, detection or correction of errors
    • H04L49/557Error correction, e.g. fault recovery or fault tolerance

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the invention provides a network table item synchronization method and a device, which are applied to first network equipment, wherein the first network equipment is arranged in an MLAG system, the first network equipment is provided with a first VSI, the MLAG system also comprises second network equipment, and the method comprises the following steps: determining a first network table entry from within the first VSI, the first network table entry being: the network table entry for which the update operation has been performed. Sending a first table synchronization message to a second network device, so that the second network device performs an update operation on a network table included in the VSI corresponding to the first SID based on information of the first network table, where the first table synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry. The scheme provided by the embodiment of the invention can ensure that the network table entries recorded in the network equipment in the MLAG system are kept consistent.

Description

Network table item synchronization method and device
Technical Field
The present invention relates to the field of network technologies, and in particular, to a method and an apparatus for synchronizing network table entries.
Background
Two network devices can be connected to form an MLAG system by using an MLAG (Multi-Chassis Link Aggregation) technology, and the MLAG system can be used as a virtual device to forward a message in a network.
In order to ensure that two network devices in the MLAG system can serve as the same virtual device to implement the same message forwarding function, it is necessary to ensure that network entries recorded in the two network devices are consistent.
Disclosure of Invention
Embodiments of the present invention provide a method and an apparatus for synchronizing network table entries, so as to ensure that network table entries recorded in network devices in an MLAG system are consistent. The specific technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides a network table entry synchronization method, which is applied to a first network device, where the first network device is in an MLAG system, a first VSI is configured in the first network device, the MLAG system further includes a second network device, and the method includes:
determining a first network table entry from within the first VSI, wherein the first network table entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
sending a first entry synchronization message to the second network device, so that the second network device performs an update operation on a network entry included in the VSI corresponding to the first SID based on information of the first network entry, where the first entry synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
In an embodiment of the present invention, the determining a first network table entry from within the first VSI includes:
determining a new network table entry from the first VSI;
the sending of the first entry synchronization message to the second network device, so that the second network device performs an update operation on the network entry included in the VSI corresponding to the first SID based on the information of the first network entry, includes:
sending a first entry addition message to the second network device, so that the second network device adds the new network entry in the VSI corresponding to the first SID, where the first entry addition message carries: the first SID and the information of the newly added network table entry.
In an embodiment of the present invention, the determining a first network table entry from within the first VSI includes:
determining deleted network table entries from within the first VSI;
the sending of the first entry synchronization message to the second network device, so that the second network device performs an update operation on the network entry included in the VSI corresponding to the first SID based on the information of the first network entry, includes:
sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID, where the first entry deletion message carries: the first SID and the information of deleting the network table entry.
In an embodiment of the present invention, in a case that there is a newly added VSI newly configured in the first network device, the method further includes:
sending a first entry request to the second network device, so that the second network device feeds back, to the first network device, a network entry included in a VSI corresponding to the first newly added SID, where the first entry request carries: a first newly added SID corresponding to the newly added VSI;
and recording the network table entry fed back by the second network device as the network table entry contained in the newly added VSI.
In one embodiment of the invention, the method further comprises:
receiving a second table item synchronization message sent by the second network device, where the second table item synchronization message carries: a second SID corresponding to a second VSI in the second network device and information of a second network entry, where the second network entry is: network table entries in the second VSI that have performed an update operation;
searching for a VSI corresponding to the second SID in the first network device;
and updating the network table items contained in the searched VSI based on the information of the second network table item.
In an embodiment of the present invention, the receiving a second entry synchronization message sent by the second network device includes:
receiving a second entry addition message sent by the second network device, wherein the second entry addition message carries: the second SID and information of a newly added network table entry in the second VSI;
the updating the network table entry included in the searched VSI based on the information of the second network table entry includes:
and adding the new network table entry into the searched VSI based on the information of the new network table entry.
In an embodiment of the present invention, the receiving a second entry synchronization message sent by the second network device includes:
receiving a second entry deletion message sent by the second network device, where the second entry deletion message carries: the second SID and the deleted network table entry information in the second VSI;
the updating the network table entry included in the searched VSI based on the information of the second network table entry includes:
and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
In one embodiment of the invention, the method further comprises:
receiving a second entry request sent by the second network device, where the second entry request carries: a second newly added SID corresponding to the newly added VSI in the second network device;
searching for a VSI corresponding to the second newly-added SID in the first network device;
and sending the network table items contained in the searched VSI to the second network equipment.
In an embodiment of the present invention, the network table entry includes at least one of the following entries: MAC table item, ARP table item, ND table item.
In a second aspect, an embodiment of the present invention provides a network table entry synchronization apparatus, which is applied to a first network device, where the first network device is in an MLAG system, a first VSI is configured in the first network device, and the MLAG system further includes a second network device, where the apparatus includes:
an entry determining module, configured to determine a first network entry from within the first VSI, where the first network entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
a message sending module, configured to send a first entry synchronization message to the second network device, so that the second network device performs an update operation on a network entry included in a VSI corresponding to the first SID based on information of the first network entry, where the first entry synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
In an embodiment of the present invention, the table entry determining module is specifically configured to:
determining a new network table entry from the first VSI;
the message sending module is specifically configured to:
sending a first entry addition message to the second network device, so that the second network device adds the new network entry in the VSI corresponding to the first SID, where the first entry addition message carries: the first SID and the information of the newly added network table entry.
In an embodiment of the present invention, the table entry determining module is specifically configured to:
determining deleted network table entries from within the first VSI;
the message sending module is specifically configured to:
sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID, where the first entry deletion message carries: the first SID and the information of deleting the network table entry.
In an embodiment of the present invention, in a case that there is a newly added VSI newly configured in the first network device, the apparatus further includes:
a request sending module, configured to send a first entry request to the second network device, so that the second network device feeds back, to the first network device, a network entry included in a VSI corresponding to the first newly added SID, where the first entry request carries: a first newly added SID corresponding to the newly added VSI;
and the table entry recording module is used for recording the network table entries fed back by the second network device as the network table entries contained in the newly added VSI.
In one embodiment of the present invention, the apparatus further comprises:
a message receiving module, configured to receive a second table synchronization message sent by the second network device, where the second table synchronization message carries: a second SID corresponding to a second VSI in the second network device and information of a second network entry, where the second network entry is: network table entries in the second VSI that have performed an update operation;
a first VSI searching module, configured to search for a VSI in the first network device corresponding to the second SID;
and the table item updating module is used for updating the network table items contained in the searched VSI based on the information of the second network table item.
In an embodiment of the present invention, the message receiving module is specifically configured to:
receiving a second entry addition message sent by the second network device, wherein the second entry addition message carries: the second SID and information of a newly added network table entry in the second VSI;
the entry updating module is specifically configured to:
and adding the new network table entry into the searched VSI based on the information of the new network table entry.
In an embodiment of the present invention, the message receiving module is specifically configured to:
receiving a second entry deletion message sent by the second network device, where the second entry deletion message carries: the second SID and the deleted network table entry information in the second VSI;
the entry updating module is specifically configured to:
and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
In one embodiment of the present invention, the apparatus further comprises:
a request receiving module, configured to receive a second entry request sent by the second network device, where the second entry request carries: a second newly added SID corresponding to the newly added VSI in the second network device;
a second VSI searching module, configured to search for a VSI in the first network device, where the VSI corresponds to the second newly-added third SID;
and the table item sending module is used for sending the network table items contained in the searched VSI to the second network equipment.
In an embodiment of the present invention, the network table entry includes at least one of the following entries: MAC table item, ARP table item, ND table item.
In a third aspect, an embodiment of the present invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor and the communication interface complete communication between the memory and the processor through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any of the first aspect when executing a program stored in the memory.
In a fourth aspect, the present invention provides a computer-readable storage medium, in which a computer program is stored, and the computer program, when executed by a processor, implements the method steps of any one of the first aspect.
In a fifth aspect, embodiments of the present invention also provide a computer program product comprising instructions, which when run on a computer, cause the computer to perform the method steps of any of the first aspects described above.
The embodiment of the invention has the following beneficial effects:
the embodiment of the invention provides a network table entry synchronization method, which is applied to first network equipment in an MLAG system, wherein the first network equipment determines a first network table entry which is contained in a first VSI in the first network equipment and has executed updating operation. And sending a table item synchronization message carrying information of the first SID corresponding to the first VSI and the first network table item to a second network device except the first network device in the MLAG system, so that the second network device updates the network table item contained in the VSI corresponding to the first SID based on the information of the first network table item.
As can be seen from the above, if the first network table entry in the first VSI in the first network device has executed the update operation, the first network device sends a table entry synchronization message to the second network device, where the table entry synchronization message carries the first SID corresponding to the first VSI, and the table entry synchronization message also carries the information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings can be obtained by those skilled in the art according to the drawings.
Fig. 1 is a schematic flowchart of a first network table entry synchronization method according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of an MLAG system according to an embodiment of the present invention;
fig. 3 is a schematic diagram of a network structure according to an embodiment of the present invention;
FIG. 4 is a diagram illustrating an MLAG system in a network according to an embodiment of the present invention;
fig. 5 is a flowchart illustrating a second network table entry synchronization method according to an embodiment of the present invention;
fig. 6 is a flowchart illustrating a third network table entry synchronization method according to an embodiment of the present invention;
fig. 7 is a flowchart illustrating a fourth network table entry synchronization method according to an embodiment of the present invention;
fig. 8 is a flowchart illustrating a fifth network table entry synchronization method according to an embodiment of the present invention;
fig. 9 is a flowchart illustrating a sixth network table entry synchronization method according to an embodiment of the present invention;
fig. 10 is a schematic structural diagram of a first network table entry synchronization apparatus according to an embodiment of the present invention;
fig. 11 is a schematic structural diagram of a second network table entry synchronization apparatus according to an embodiment of the present invention;
fig. 12 is a schematic structural diagram of a third network table entry synchronization apparatus according to an embodiment of the present invention;
fig. 13 is a schematic structural diagram of a fourth network table entry synchronization apparatus according to an embodiment of the present invention;
fig. 14 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived from the embodiments given herein by one of ordinary skill in the art, are within the scope of the invention.
In order to ensure that network table entries recorded in network devices in an MLAG system are consistent, embodiments of the present invention provide a method and an apparatus for synchronizing network table entries.
An embodiment of the present invention provides a network table entry synchronization method, which is applied to a first network device, where the first network device is in an MLAG system, a first VSI is configured in the first network device, the MLAG system further includes a second network device, and the method includes:
determining a first network table entry from within the first VSI, wherein the first network table entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
sending a first entry synchronization message to the second network device, so that the second network device performs an update operation on a network entry included in the VSI corresponding to the first SID based on information of the first network entry, where the first entry synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
As can be seen from the above, if the first network table entry in the first VSI in the first network device has executed the update operation, the first network device sends a table entry synchronization message to the second network device, where the table entry synchronization message carries the first SID corresponding to the first VSI, and the table entry synchronization message also carries the information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
Referring to fig. 1, a flowchart of a first network entry synchronization method provided in an embodiment of the present invention is applied to a first network device, where the first network device is in an MLAG system, a first VSI (Virtual Switch Instance) is configured in the first network device, and the MLAG system further includes a second network device.
The first network device may be any network device in an MLAG system. The network devices in the MLAG system may be referred to as DR (Distributed Relay) devices, two network devices in the MLAG system respectively include an ip (Intra-Port, internal control Link Port), the IPPs of the two network devices may be connected by an IPL (Intra-Port Link, internal control Link), and the first network device and the second network device may interact a protocol message and transmit data traffic through the IPL. Each MLAG system contains one IPL. An interface of the DR apparatus connected to an apparatus such as a network apparatus or a terminal other than the MLAG system may be referred to as a DR interface, and DR interfaces connected to the same apparatus on two network apparatuses in the MLAG system form a DR group.
Referring to fig. 2, a schematic structural diagram of an MLAG system according to an embodiment of the present invention is shown, where a portion enclosed by a dashed line box is the MLAG system, DR1 and DR2 are two network devices in the MLAG system, a DR interface 1 on DR1 and a DR interface 2 on DR2 are both connected to a network device M, and the network device M is connected to a terminal N. The DR interface 1 and the DR interface 2 form a DR group. DR1 is connected to IPP on DR2 via IPL, which indicates in form of double line that DR1 and DR2 on both sides of IPL can communicate with each other. In addition, an MLAG system consisting of the DR1 and the DR2 is connected with the IP network. The terminal N can communicate with other devices in the IP network via the network device M and the MLAG system.
In addition, the network device in the MLAG system may be a network device located in an IP backbone network or an MPLS (Multi-Protocol Label Switching) network.
Fig. 3 is a schematic diagram of a network structure according to an embodiment of the present invention.
As can be seen, the network includes 4 PEs (Provider Edge). Each PE may be an MLAG system composed of two network devices. The PE device is connected to a CE (Customer Edge) device through an AC (access Circuit), and the PEs are connected to each other through a PW (Pseudowire).
The PEs are connected to form an IP backbone network or an MPLS network, and a PW in the MPLS network is formed by a pair of unidirectional LSPs (label Switching Path) in opposite directions.
The MPLS or IP backbone network described above can implement a communication Service based on VPLS (Virtual Private LAN Service).
Fig. 4 is a schematic diagram of an MLAG system in a network according to an embodiment of the present invention.
It can be seen from the figure that the portion enclosed by the dashed line is an MLAG system, switch1 and switch2 form an MLAG system, switch1 and switch2 are connected by IPL, switch1 and switch2 are both connected to switch3, switch3 is connected to switch4, so that VM (Virtual Machine) 1 and VM2 connected to the MLAG system can transmit messages to switch3 through switch1 or switch2, and then switch3 forwards the messages to switch4, and switch4 forwards the messages to VM3, thereby realizing communication connection between VM1 and VM3, and VM2 and VM 3.
The above method includes the following steps S101-S102.
S101: a first network table entry is determined from within the first VSI.
Wherein, the first network table entry is: and the network table entry which is subjected to the updating operation is used for forwarding the message. The network table entry may be at least one of the following table entries: MAC (Media Access Control Address) table, ARP (Address Resolution Protocol) table, and ND (Neighbor Discovery) table. The first network table entry that has been updated may be a new network table entry or a deleted network table entry.
Specifically, the VSI in the first network device may be a virtual instance manually created in the first network device by a user, and the VSI is equivalent to a virtual switch and has each function of a physical switch. Different VSIs in the first network device may forward the packet based on different technologies, where the first VSI is a VSI for forwarding the packet based on SRv6(Segment Routing IPv6, version 6 of internet protocol) technology.
The first VSI may send a SID (Segment Identifier) to a third VSI in another network device except the second network device based on SRv6 technology, so as to establish a SRv6 tunnel between the first VSI and the third VSI. After the SRv6 tunnel is established, SRv6 messages may be mutually sent between the first VSI and the third VSI through the SRv6 tunnel, where the VSI sending SRv6 messages may be referred to as a source node, and the VSI receiving SRv6 messages may be referred to as a tail node.
Specifically, the SRv6 message is: an SRH (Segment Routing Header) is encapsulated on an IPv6 message, where the SRH may be referred to as an extension Header, and the SRv6 message is a message in the prior art, which is not described in detail herein in this embodiment of the present invention.
The SID includes a Locator field, a Function field, and an definitions field, where the Function field may also be referred to as an Opcode field, and may be divided into a static Opcode field manually set by a user and a dynamic Opcode field allocated based on a Protocol, for example, the Protocol may be an IGP (Interior Gateway Protocol) Protocol.
In an embodiment of the present invention, the first VSI may send an end.dt2m SID, whose value is end.dt2m, of a Function field between the first VSI and the third VSI to establish a broadcast SRv6 tunnel between the first VSI and the third VSI, where the value of the Function field is end.dt2m may be used to instruct the VSI to remove an IPv6 packet header and an extension header of a SRv6 packet, and then broadcast and flood the remaining packets in the network.
The first VSI may send an end.dt2u SID of the Function field, whose value is end.dt2u, to the third VSI, so as to establish a unicast SRv6 tunnel between the first VSI and the third VSI, where the value of the Function field is end.dt2u is used to instruct the VSI to remove a SRv6 packet header and an extension header thereof, and then use a destination MAC address of the remaining packet to search the MAC table, and forward the packet to a corresponding egress interface according to the MAC table entry.
The first VSI may mutually send an end.dx2 SID of which the value of the Function field is end.dx2 between the first VSI and the third VSI to establish a unicast SRv6 tunnel between the first VSI and the third VSI, where the value of the Function field is end.dx2 is used to instruct the VSI to remove SRv6 a packet header and an extension header thereof, and then use a destination MAC address of the remaining packet to search for an MAC table, and forward the packet to a corresponding egress interface according to the MAC table entry.
In addition, the first VSI may store the self-generated SID through a local SID table, and a Locator field in the self-generated SID records an address of the first VSI.
S102: and sending a first table synchronization message to the second network device, so that the second network device performs an update operation on the network table included in the VSI corresponding to the first SID based on the information of the first network table.
Wherein, the first table item synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
In addition, information contained in the SIDs corresponding to different VSIs is different, so that the second network device can determine the VSI corresponding to the first SID after receiving the first SID.
In addition, if the first network table entry is an MAC table entry, the information of the first network table entry may include: the MAC address, the DR group identifier, etc. recorded in the first network table entry.
If the first network entry is an ARP entry, the information of the first network entry may include: the IP address, MAC address, DR group identifier, etc. contained in the first network table entry.
If the first network table entry is an ND table entry, the information of the first network table entry may include: the IP address, MAC address, DR group identifier, etc. contained in the first network table entry.
In addition, the first SID may be a SID included in a local SID table of the first VSI recorded by the first network device.
In an embodiment of the present invention, the first network device may send the entry synchronization message to the second network device through the IPL.
Specifically, in order to ensure that the first network device and the second network device can serve as the same virtual device to implement the same message forwarding function, the first network device and the second network device may be configured with the same VSI, and then, under a condition that a first network entry in the first VSI changes, an entry synchronization message carrying the first SID may be sent to the second network device, where the first SID corresponds to the first VSI, and then the second network device may determine a VSI in the second network device corresponding to the first SID, and update a network entry in the determined VSI based on the first network entry.
The above-mentioned scheme for the second network device to update the network table entry stored in the second network device is similar to the embodiment shown in fig. 8 below, and the embodiment of the present invention is not described in detail here.
As can be seen from the above, if the first network table entry in the first VSI in the first network device has executed the update operation, the first network device sends a table entry synchronization message to the second network device, where the table entry synchronization message carries the first SID corresponding to the first VSI, and the table entry synchronization message also carries the information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
In addition, in order to ensure that the network entries in the first network device and the second network device are kept synchronized, when the network entries included in the VSI in the second network device change, the second network device may also send an entry synchronization message to the first network device by using a method similar to that in the embodiment shown in fig. 1, so that the first network device updates the network entries in the VSI configured by the first network device.
In another embodiment of the present invention, the VSI may forward the packet in a SR-BE (Segment Routing-Best Effort) mode, a SR-TE (Segment Routing-Traffic Engineering) mode, or a hybrid mode of SR-TE and SR-BE, and since the packet forwarding mode belongs to the prior art, the embodiment of the present invention is not described herein again.
Referring to fig. 5, a flowchart of a second network entry synchronization method according to an embodiment of the present invention is shown, where, compared with the foregoing embodiment shown in fig. 1, the foregoing step S101 may be implemented by the following step S101A.
S101A: and determining a new network table entry from the first VSI.
Specifically, the newly added network entry may be a dynamic network entry learned by the first VSI based on the network protocol, or may be a static network entry manually set by the user.
In addition, compared to the aforementioned embodiment shown in fig. 1, the above step S102 can be realized by the following step S102A.
S102A: and sending a first entry addition message to the second network device, so that the second network device adds the new entry in the VSI corresponding to the first SID.
Wherein, the first table item new-adding information carries: the first SID and information of the newly added network table entry.
In an embodiment of the present invention, if the newly added network table entry is an MAC table entry, the information of the newly added network table entry may include: and newly adding the MAC address and the DR group identification recorded in the network table entry.
If the newly added network table entry is an ARP table entry, the information of the newly added network table entry may include: and the newly added network table entry comprises the IP address, the MAC address and the DR group identifier.
If the newly added network table entry is an ND table entry, the information of the newly added network table entry may include: and the newly added network table entry comprises the IP address, the MAC address and the DR group identifier.
In addition, the step of adding the new network table entry in the VSI corresponding to the first SID by the second network device is similar to the step C below, and details of this step are not described in this embodiment of the present invention.
As can be seen from the above, if a newly added network entry exists in a first VSI in a first network device, the first network device sends a first entry newly added message to a second network device, where the first entry newly added message carries a first SID for identifying the first VSI, and the first entry newly added message also carries information of the newly added network entry. After sending the first entry addition message to the second network device, the second network device may determine, based on the first SID carried in the first entry addition message, a VSI in the second network device corresponding to the first VSI, and add, based on information of the newly added network entry, the newly added network entry in the determined VSI. Therefore, if a network table entry is added to the first network device, the second network device may add the new network table entry based on the first table entry addition message, so that the network table entries recorded in the corresponding VSIs in the first network device and the second network device in the MLAG system are kept consistent.
Referring to fig. 6, a flowchart of a third network entry synchronization method provided in the embodiment of the present invention is shown, and compared with the foregoing embodiment shown in fig. 1, the foregoing step S101 may be implemented by the following step S101B.
S101B: and determining deleted network table entries from the first VSI.
The network entry deletion may be a dynamic network entry deleted by the first VSI based on the network protocol, or a static network entry manually deleted by the user.
In addition, compared to the aforementioned embodiment shown in fig. 1, the above step S102 can be realized by the following step S102B.
S102B: and sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID.
Wherein, the first table item deleting message carries: the first SID and the information of deleting the network table entry.
In an embodiment of the present invention, if the deleted network entry is an MAC entry, the information of deleting the network entry may include: and deleting the MAC address recorded in the network table entry.
If the deleted network entry is an ARP entry, the information for deleting the network entry may include: and deleting the IP address contained in the network table entry.
If the deleted network entry is an ND entry, the information of deleting the network entry may include: and deleting the IP address contained in the network table entry.
In addition, the step of deleting the network entry in the VSI corresponding to the first SID by the second network device is similar to step D shown below, and details of this step are not described in this embodiment of the present invention.
As can be seen from the above, if a deleted network entry exists in a first VSI in a first network device, the first network device may send a first entry deletion message to a second network device, where the first entry deletion message carries a first SID for identifying the first VSI, and the first entry deletion message also carries information for deleting the network entry. After sending the first entry deletion message to the second network device, the second network device may determine, based on the first SID carried in the first entry deletion message, a VSI in the second network device corresponding to the first VSI, and delete, based on the information of deleting the network entry, the network entry in the determined VSI. Therefore, if the network table entry is deleted from the first network device, the second network device may delete the network table entry synchronously based on the first table entry deletion message, so that the network table entries recorded in the corresponding VSIs in the first network device and the second network device in the MLAG system are kept consistent.
Referring to fig. 7, which is a flowchart illustrating a fourth network entry synchronization method according to an embodiment of the present invention, in a case that a newly configured new VSI exists in the first network device, compared with the embodiment shown in fig. 1, the method further includes the following steps S103 to S104.
Specifically, the newly added VSI may be manually configured in the first network device by a user.
S103: and sending a first entry request to the second network device, so that the second network device feeds back a network entry which is stored by the second network device and is included in the VSI corresponding to the first newly added SID to the first network device.
Wherein, the first table entry request carries: a first newly added SID corresponding to the newly added VSI.
In an embodiment of the present invention, the first network device may send the first entry request to the second network device through the IPL.
In addition, the above steps of the second network device feeding back the network table entry to the first network device are similar to the following steps S108 to S110 shown in fig. 9, and details of the steps are not described in this embodiment of the present invention.
S104: and recording the network table entry fed back by the second network device as the network table entry contained in the newly added VSI.
Specifically, the first network device records the network table entry as a network table entry included in the newly added VSI, so that the network table entry included in the newly added VSI in the first network device is the same as the network table entry included in the VSI corresponding to the first newly added SID in the second network device, thereby achieving synchronization of the network table entries in the first network device and the second network device.
As can be seen from the above, if the newly added VSI exists in the first network device, the network entries included in the newly added VSI are often fewer, and the difference between the network entries included in the VSI corresponding to the newly added first SID in the second network device is often greater, so that the first network device may actively send the first entry request carrying the first newly added SID to the second network device, so that the second network device may send the network entries included in the VSI corresponding to the first newly added SID, which are stored by the second network device, to the first network device. The first network device stores the received network table entry as the network table entry of the newly added VSI, so that the network table entry in the newly added VSI and the network table entry in the same VSI in the second network device are kept synchronous.
Referring to fig. 8, a flowchart of a fifth network entry synchronization method according to an embodiment of the present invention is shown, and compared with the foregoing embodiment shown in fig. 1, the method further includes the following steps S105 to S107.
S105: and receiving a second table item synchronization message sent by the second network equipment.
Wherein, the second table item synchronization message carries: a second SID and information of a second network entry corresponding to a second VSI in the second network device, where the second network entry is: and the network table entry in the second VSI is subjected to updating operation.
Specifically, the second network device may send the second table synchronization message to the first network device in a manner corresponding to the embodiment shown in fig. 1, which is not described again in this embodiment of the present invention.
In an embodiment of the present invention, the step S105 may be implemented by the step a.
Step A: and receiving a second table item addition message sent by the second network equipment.
Wherein, the second table item new message carries: and the second SID and information of the newly added network table entry in the second VSI.
In another embodiment of the present invention, the step S105 may be implemented by a step B.
And B: and receiving a second item deleting message sent by the second network equipment.
Wherein, the second table item deleting message carries: and the second SID and the deleted network entry information in the second VSI.
S106: and searching the VSI corresponding to the second SID in the first network equipment.
In one embodiment of the invention, the VSI corresponding to the second SID may be determined by traversing the VSIs in the first network device.
S107: and updating the network table items contained in the searched VSI based on the information of the second network table item.
In an embodiment of the present invention, if the step S105 is implemented by the step a, that is, the second entry synchronization message sent by the second network device is a second entry addition message, the step S107 may be implemented by the following step C.
And C: and adding the newly-added network table entry into the searched VSI based on the information of the newly-added network table entry.
Specifically, the first network device may generate a network entry that includes information of the newly added network entry as a newly added network entry, and add the generated newly added network entry to the searched VSI.
Therefore, after the newly added network table entry is newly added in the VSI of the second network device, the newly added network table entry is also newly added in the corresponding VSI of the first network device, so that the network table entries recorded in the first network device and the second network device can be kept synchronous.
In an embodiment of the present invention, if the step S105 is implemented by the step B, that is, the second entry synchronization message sent by the second network device is a second entry deletion message, the step S107 may be implemented by the following step D.
Step D: and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
Specifically, the first network device may traverse the network table entry included in the searched VSI, search for the network table entry including the information, serve as a deleted network table entry, and delete the deleted network table entry.
Therefore, after the deleted network entry in the VSI of the second network device is deleted, the deleted network entry is also deleted in the corresponding VSI of the first network device, so that the network entries recorded in the first network device and the second network device can be kept synchronized.
As can be seen from the above, after the first network device receives the second entry synchronization message sent by the second network device, the first network device may determine, based on the second SID carried in the second entry synchronization message, the VSI corresponding to the second SID, and update, based on the information of the second network entry carried in the second entry synchronization message, the network entry included in the determined VSI. Therefore, if the network table entry stored in the second network device changes, the first network device may update the network table entry stored in the first network device based on the second table entry synchronization message, so that the network table entries recorded in the VSI of the first network device and the corresponding network table entries in the second network device in the MLAG system are kept consistent.
Referring to fig. 9, a flowchart of a sixth network entry synchronization method according to an embodiment of the present invention is shown, and compared with the foregoing embodiment shown in fig. 1, the method further includes the following steps S108 to S110.
S108: and receiving a second table item request sent by the second network equipment.
Wherein, the second table entry request carries: and a second new SID corresponding to the new VSI in the second network device.
Specifically, the second entry request indicates that the second network device requests each network entry included in the VSI corresponding to the second new SID and stored by the first network device.
S109: and searching the VSI corresponding to the second newly-added SID in the first network equipment.
In an embodiment of the invention, the first network device may traverse the VSI configured in itself to search for the VSI corresponding to the second newly added SID.
S110: and sending the network table items contained in the searched VSI to the second network equipment.
Specifically, the first network device may send the network table entry to the VSI through an IPL between the first network device and the second network device.
As can be seen from the above, if the first network device receives the second entry request sent by the second network device, the first network device may send the network entry included in the VSI corresponding to the second newly added SID, which is stored in the first network device, to the second network device. So that the second network device can record the network table entry, and the first network device and the network table entry stored in the second network device keep synchronous.
Corresponding to the network table entry synchronization method, the embodiment of the invention also provides a network table entry synchronization device.
Referring to fig. 10, a schematic structural diagram of a first network table entry synchronization apparatus provided in an embodiment of the present invention is applied to a first network device, where the first network device is in an MLAG system, and a first VSI is configured in the first network device, and the MLAG system further includes a second network device, where the apparatus includes:
an entry determining module 1001, configured to determine a first network entry from within the first VSI, where the first network entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
a message sending module 1002, configured to send a first entry synchronization message to the second network device, so that the second network device performs an update operation on a network entry included in a VSI corresponding to the first SID based on information of the first network entry, where the first entry synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
As can be seen from the above, if the first network table entry in the first VSI in the first network device has executed the update operation, the first network device sends a table entry synchronization message to the second network device, where the table entry synchronization message carries the first SID corresponding to the first VSI, and the table entry synchronization message also carries the information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
In an embodiment of the present invention, the table entry determining module 1001 is specifically configured to:
determining a new network table entry from the first VSI;
the message sending module 1002 is specifically configured to:
sending a first entry addition message to the second network device, so that the second network device adds the new network entry in the VSI corresponding to the first SID, where the first entry addition message carries: the first SID and the information of the newly added network table entry.
As can be seen from the above, if a newly added network entry exists in a first VSI in a first network device, the first network device sends a first entry newly added message to a second network device, where the first entry newly added message carries a first SID for identifying the first VSI, and the first entry newly added message also carries information of the newly added network entry. After sending the first entry addition message to the second network device, the second network device may determine, based on the first SID carried in the first entry addition message, a VSI in the second network device corresponding to the first VSI, and add, based on information of the newly added network entry, the newly added network entry in the determined VSI. Therefore, if a network table entry is added to the first network device, the second network device may add the new network table entry based on the first table entry addition message, so that the network table entries recorded in the corresponding VSIs in the first network device and the second network device in the MLAG system are kept consistent.
In an embodiment of the present invention, the table entry determining module 1001 is specifically configured to:
determining deleted network table entries from within the first VSI;
the message sending module 1002 is specifically configured to:
sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID, where the first entry deletion message carries: the first SID and the information of deleting the network table entry.
As can be seen from the above, if a deleted network entry exists in a first VSI in a first network device, the first network device may send a first entry deletion message to a second network device, where the first entry deletion message carries a first SID for identifying the first VSI, and the first entry deletion message also carries information for deleting the network entry. After sending the first entry deletion message to the second network device, the second network device may determine, based on the first SID carried in the first entry deletion message, a VSI in the second network device corresponding to the first VSI, and delete, based on the information of deleting the network entry, the network entry in the determined VSI. Therefore, if the network table entry is deleted from the first network device, the second network device may delete the network table entry synchronously based on the first table entry deletion message, so that the network table entries recorded in the corresponding VSIs in the first network device and the second network device in the MLAG system are kept consistent.
Referring to fig. 11, a schematic structural diagram of a second network table entry synchronization apparatus according to an embodiment of the present invention is provided, where in a case that a newly configured new VSI exists in the first network device, compared with the embodiment shown in fig. 10, the apparatus further includes:
a request sending module 1003, configured to send a first entry request to the second network device, so that the second network device feeds back, to the first network device, a network entry included in a VSI corresponding to the first newly added SID, where the first entry request carries: a first newly added SID corresponding to the newly added VSI;
the table entry recording module 1004 is configured to record a network table entry fed back by the second network device, as a network table entry included in the newly added VSI.
As can be seen from the above, if the newly added VSI exists in the first network device, the network entries included in the newly added VSI are often fewer, and the difference between the network entries included in the VSI corresponding to the newly added first SID in the second network device is often greater, so that the first network device may actively send the first entry request carrying the first newly added SID to the second network device, so that the second network device may send the network entries included in the VSI corresponding to the first newly added SID, which are stored by the second network device, to the first network device. The first network device stores the received network table entry as the network table entry of the newly added VSI, so that the network table entry in the newly added VSI and the network table entry in the same VSI in the second network device are kept synchronous.
Referring to fig. 12, a schematic structural diagram of a third network table entry synchronization apparatus according to an embodiment of the present invention is provided, where compared with the foregoing embodiment shown in fig. 10, the apparatus includes:
a message receiving module 1005, configured to receive a second table synchronization message sent by the second network device, where the second table synchronization message carries: a second SID corresponding to a second VSI in the second network device and information of a second network entry, where the second network entry is: network table entries in the second VSI that have performed an update operation;
a first VSI searching module 1006, configured to search for a VSI in the first network device corresponding to the second SID;
an entry updating module 1007, configured to update the network entry included in the searched VSI based on the information of the second network entry.
As can be seen from the above, after the first network device receives the second entry synchronization message sent by the second network device, the first network device may determine, based on the second SID carried in the second entry synchronization message, the VSI corresponding to the second SID, and update, based on the information of the second network entry carried in the second entry synchronization message, the network entry included in the determined VSI. Therefore, if the network table entry stored in the second network device changes, the first network device may update the network table entry stored in the first network device based on the second table entry synchronization message, so that the network table entries recorded in the VSI of the first network device and the corresponding network table entries in the second network device in the MLAG system are kept consistent.
In an embodiment of the present invention, the message receiving module 1005 is specifically configured to:
receiving a second entry addition message sent by the second network device, wherein the second entry addition message carries: the second SID and information of a newly added network table entry in the second VSI;
the entry updating module 1007 is specifically configured to:
and adding the new network table entry into the searched VSI based on the information of the new network table entry.
As can be seen from the above, after the newly added network table entry is newly added in the VSI in the second network device, the newly added network table entry is also newly added in the corresponding VSI in the first network device, so that the network table entries recorded in the first network device and the second network device can be kept synchronized.
In an embodiment of the present invention, the message receiving module 1005 is specifically configured to:
receiving a second entry deletion message sent by the second network device, where the second entry deletion message carries: the second SID and the deleted network table entry information in the second VSI;
the entry updating module 1007 is specifically configured to:
and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
As can be seen from the above, after the deleted network entry in the VSI of the second network device is deleted, the deleted network entry is also deleted in the corresponding VSI of the first network device, so that the network entries recorded in the first network device and the second network device can be kept synchronized.
Referring to fig. 13, a schematic structural diagram of a fourth network table entry synchronization apparatus provided in the embodiment of the present invention is shown, and compared with the embodiment shown in fig. 10, the apparatus further includes:
a request receiving module 1008, configured to receive a second entry request sent by the second network device, where the second entry request carries: a second newly added SID corresponding to the newly added VSI in the second network device;
a second VSI searching module 1009, configured to search for a VSI in the first network device corresponding to the second bath energy SID;
the table entry sending module 1010 is configured to send the network table entry included in the searched VSI to the second network device.
As can be seen from the above, if the first network device receives the second entry request sent by the second network device, the first network device may send the network entry included in the VSI corresponding to the second newly added SID, which is stored in the first network device, to the second network device. So that the second network device can record the network table entry, and the first network device and the network table entry stored in the second network device keep synchronous.
In an embodiment of the present invention, the network table entry includes at least one of the following entries: MAC table item, ARP table item, ND table item.
The embodiment of the present invention further provides an electronic device, as shown in fig. 14, which includes a processor 1401, a communication interface 1402, a memory 1403, and a communication bus 1404, wherein the processor 1401, the communication interface 1402, and the memory 1403 complete communication with each other through the communication bus 1404,
a memory 1403 for storing a computer program;
the processor 1401 is configured to implement the method steps of any of the above network table entry synchronization methods when executing the program stored in the memory 1403.
When the electronic device provided by the embodiment of the present invention is applied to synchronize network table entries, if a first network table entry in a first VSI in a first network device has executed an update operation, the first network device sends a table entry synchronization message to a second network device, where the table entry synchronization message carries a first SID corresponding to the first VSI, and the table entry synchronization message also carries information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components.
In yet another embodiment of the present invention, a computer-readable storage medium is also provided, in which a computer program is stored, and the computer program, when executed by a processor, implements the method steps of any of the above network table entry synchronization methods.
When the network table entry is synchronized by applying the computer program stored in the computer-readable storage medium provided in this embodiment, if the first network table entry in the first VSI in the first network device has executed the update operation, the first network device sends a table entry synchronization message to the second network device, where the table entry synchronization message carries the first SID corresponding to the first VSI, and the table entry synchronization message also carries information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
In yet another embodiment, a computer program product containing instructions is provided, which when run on a computer causes the computer to perform any of the above described network table entry synchronization methods.
When the computer program product provided in this embodiment is executed to synchronize network table entries, if a first network table entry in a first VSI in a first network device has been updated, the first network device sends a table entry synchronization message to a second network device, where the table entry synchronization message carries a first SID corresponding to the first VSI, and the table entry synchronization message also carries information of the first network table entry. After sending the entry synchronization message to the second network device, the second network device may determine, based on the first SID, a VSI corresponding to the first SID, and update, based on information of the first network entry, a network entry included in the determined VSI. The determined VSI and the first VSI both correspond to the first SID, and thus are corresponding VSIs used in the MLAG system to achieve the same function. If the network table entry stored in the first network device is updated, the second network device may update the network table entry stored in the second network device based on the table entry synchronization message, so that the network table entries recorded in the VSIs of the first network device and the second network device in the MLAG system are consistent.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, as for the apparatus, the electronic device, the computer-readable storage medium and the computer program product, since they are substantially similar to the method embodiments, the description is relatively simple, and in relation to them, reference may be made to the partial description of the method embodiments.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (18)

1. A network table entry synchronization method is applied to a first network device, the first network device is in a multi-device link aggregation (MLAG) system, a first Virtual Switch Instance (VSI) is configured in the first network device, and a second network device is further included in the MLAG system, and the method comprises the following steps:
determining a first network table entry from within the first VSI, wherein the first network table entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
sending a first table synchronization message to the second network device, so that the second network device performs an update operation on a network table included in the VSI corresponding to the first segment identifier SID based on information of the first network table, where the first table synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
2. The method of claim 1, wherein said determining a first network table entry from within the first VSI comprises:
determining a new network table entry from the first VSI;
the sending of the first entry synchronization message to the second network device, so that the second network device performs an update operation on the network entry included in the VSI corresponding to the first SID based on the information of the first network entry, includes:
sending a first entry addition message to the second network device, so that the second network device adds the new network entry in the VSI corresponding to the first SID, where the first entry addition message carries: the first SID and the information of the newly added network table entry.
3. The method of claim 1, wherein said determining a first network table entry from within the first VSI comprises:
determining deleted network table entries from within the first VSI;
the sending of the first entry synchronization message to the second network device, so that the second network device performs an update operation on the network entry included in the VSI corresponding to the first SID based on the information of the first network entry, includes:
sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID, where the first entry deletion message carries: the first SID and the information of deleting the network table entry.
4. The method according to any of claims 1-3, wherein in the presence of a newly added VSI for the new configuration in the first network device, the method further comprises:
sending a first entry request to the second network device, so that the second network device feeds back, to the first network device, a network entry included in a VSI corresponding to the first newly added SID, where the first entry request carries: a first newly added SID corresponding to the newly added VSI;
and recording the network table entry fed back by the second network device as the network table entry contained in the newly added VSI.
5. The method according to any one of claims 1-3, further comprising:
receiving a second table item synchronization message sent by the second network device, where the second table item synchronization message carries: a second SID corresponding to a second VSI in the second network device and information of a second network entry, where the second network entry is: network table entries in the second VSI that have performed an update operation;
searching for a VSI corresponding to the second SID in the first network device;
and updating the network table items contained in the searched VSI based on the information of the second network table item.
6. The method of claim 5, wherein the receiving the second entry synchronization message sent by the second network device comprises:
receiving a second entry addition message sent by the second network device, wherein the second entry addition message carries: the second SID and information of a newly added network table entry in the second VSI;
the updating the network table entry included in the searched VSI based on the information of the second network table entry includes:
and adding the new network table entry into the searched VSI based on the information of the new network table entry.
7. The method of claim 5, wherein the receiving the second entry synchronization message sent by the second network device comprises:
receiving a second entry deletion message sent by the second network device, where the second entry deletion message carries: the second SID and the deleted network table entry information in the second VSI;
the updating the network table entry included in the searched VSI based on the information of the second network table entry includes:
and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
8. The method according to any one of claims 1-3, further comprising:
receiving a second entry request sent by the second network device, where the second entry request carries: a second newly added SID corresponding to the newly added VSI in the second network device;
searching for a VSI corresponding to the second newly-added SID in the first network device;
and sending the network table items contained in the searched VSI to the second network equipment.
9. The method according to any of claims 1-3, wherein the network table entry comprises at least one of the following entries: MAC table entry, ARP table entry and neighbor discovery ND table entry.
10. A network table entry synchronization apparatus, applied to a first network device, where the first network device is in an MLAG system, a first VSI is configured in the first network device, and the MLAG system further includes a second network device, where the apparatus includes:
an entry determining module, configured to determine a first network entry from within the first VSI, where the first network entry is: the network table entry which is executed with the updating operation is used for forwarding the message;
a message sending module, configured to send a first entry synchronization message to the second network device, so that the second network device performs an update operation on a network entry included in a VSI corresponding to the first SID based on information of the first network entry, where the first entry synchronization message carries: and the first SID corresponding to the first VSI and the information of the first network table entry.
11. The apparatus of claim 10, wherein the entry determination module is specifically configured to:
determining a new network table entry from the first VSI;
the message sending module is specifically configured to:
sending a first entry addition message to the second network device, so that the second network device adds the new network entry in the VSI corresponding to the first SID, where the first entry addition message carries: the first SID and the information of the newly added network table entry.
12. The apparatus of claim 10, wherein the entry determination module is specifically configured to:
determining deleted network table entries from within the first VSI;
the message sending module is specifically configured to:
sending a first entry deletion message to the second network device, so that the second network device deletes the deleted network entry in the VSI corresponding to the first SID, where the first entry deletion message carries: the first SID and the information of deleting the network table entry.
13. The apparatus according to any of claims 10-12, wherein in case there is a newly added VSI in the first network device for the new configuration, the apparatus further comprises:
a request sending module, configured to send a first entry request to the second network device, so that the second network device feeds back, to the first network device, a network entry included in a VSI corresponding to the first newly added SID, where the first entry request carries: a first newly added SID corresponding to the newly added VSI;
and the table entry recording module is used for recording the network table entries fed back by the second network device as the network table entries contained in the newly added VSI.
14. The apparatus according to any one of claims 10-12, further comprising:
a message receiving module, configured to receive a second table synchronization message sent by the second network device, where the second table synchronization message carries: a second SID corresponding to a second VSI in the second network device and information of a second network entry, where the second network entry is: network table entries in the second VSI that have performed an update operation;
a first VSI searching module, configured to search for a VSI in the first network device corresponding to the second SID;
and the table item updating module is used for updating the network table items contained in the searched VSI based on the information of the second network table item.
15. The apparatus of claim 14, wherein the message receiving module is specifically configured to:
receiving a second entry addition message sent by the second network device, wherein the second entry addition message carries: the second SID and information of a newly added network table entry in the second VSI;
the entry updating module is specifically configured to:
and adding the new network table entry into the searched VSI based on the information of the new network table entry.
16. The apparatus of claim 14, wherein the message receiving module is specifically configured to:
receiving a second entry deletion message sent by the second network device, where the second entry deletion message carries: the second SID and the deleted network table entry information in the second VSI;
the entry updating module is specifically configured to:
and deleting the deleted network table entry in the searched VSI based on the information for deleting the network table entry.
17. The apparatus according to any one of claims 10-12, further comprising:
a request receiving module, configured to receive a second entry request sent by the second network device, where the second entry request carries: a second newly added SID corresponding to the newly added VSI in the second network device;
the second VSI searching module is configured to search for a VSI corresponding to the second newly added SID in the first network device;
and the table item sending module is used for sending the network table items contained in the searched VSI to the second network equipment.
18. The apparatus according to any of claims 10-12, wherein the network table entry comprises at least one of the following entries: MAC table item, ARP table item, ND table item.
CN202110966878.0A 2021-08-23 2021-08-23 Network table item synchronization method and device Pending CN113472699A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110966878.0A CN113472699A (en) 2021-08-23 2021-08-23 Network table item synchronization method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110966878.0A CN113472699A (en) 2021-08-23 2021-08-23 Network table item synchronization method and device

Publications (1)

Publication Number Publication Date
CN113472699A true CN113472699A (en) 2021-10-01

Family

ID=77867947

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110966878.0A Pending CN113472699A (en) 2021-08-23 2021-08-23 Network table item synchronization method and device

Country Status (1)

Country Link
CN (1) CN113472699A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102932499A (en) * 2012-11-01 2013-02-13 杭州华三通信技术有限公司 Method and device for learning media access control (MAC) addresses in virtual private lan service (VPLS) networks
CN103685022A (en) * 2012-09-17 2014-03-26 杭州华三通信技术有限公司 Message forwarding method and service provider network edge equipment
CN109462515A (en) * 2018-09-11 2019-03-12 锐捷网络股份有限公司 Loop circuit processing method, the network equipment, MLAG networking and storage medium
WO2021088808A1 (en) * 2019-11-05 2021-05-14 中兴通讯股份有限公司 Method for dual-homing device access traffic forwarding, device, and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103685022A (en) * 2012-09-17 2014-03-26 杭州华三通信技术有限公司 Message forwarding method and service provider network edge equipment
CN102932499A (en) * 2012-11-01 2013-02-13 杭州华三通信技术有限公司 Method and device for learning media access control (MAC) addresses in virtual private lan service (VPLS) networks
CN109462515A (en) * 2018-09-11 2019-03-12 锐捷网络股份有限公司 Loop circuit processing method, the network equipment, MLAG networking and storage medium
WO2021088808A1 (en) * 2019-11-05 2021-05-14 中兴通讯股份有限公司 Method for dual-homing device access traffic forwarding, device, and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
唐永林等: "SRv6的分段标识符结构的改善", 《电信科学》 *

Similar Documents

Publication Publication Date Title
WO2018040530A1 (en) Method and apparatus for determining virtual machine migration
CN107547349B (en) Virtual machine migration method and device
US9992106B2 (en) Generating a host route
EP3720066A1 (en) Packet sending and processing method and apparatus, pe node, and node
WO2021258754A1 (en) Message indication method and apparatus, and device and storage medium
CN111736958B (en) Virtual machine migration method, system, computer equipment and storage medium
WO2016066119A1 (en) Deployment of virtual extensible local area network
US9369293B2 (en) Compressing singly linked lists sharing common nodes for multi-destination group expansion
CN109218200B (en) Message processing method and device
US10791051B2 (en) System and method to bypass the forwarding information base (FIB) for interest packet forwarding in an information-centric networking (ICN) environment
CN113162857B (en) Method and gateway for acquiring route on demand
US20210119906A1 (en) Loop Avoidance Communications Method, Device, and System
CN108199968B (en) Route processing method and device
US10404598B1 (en) Managing next hop groups in routers
CN112702773B (en) Communication method and device
CN113438329B (en) MAC address sending method, device and system
CN113055295A (en) Communication method, communication device and communication system
US20220124024A1 (en) Establishment of method and apparatus for implementing entry backup
US20190215191A1 (en) Deployment Of Virtual Extensible Local Area Network
CN106911549B (en) Data message processing method and device
EP4236245A1 (en) Route advertisement method, apparatus, and system
CN105763444A (en) Route synchronization method and route synchronization device
CN109347748A (en) A kind of method and apparatus of synchronization of routing information
CN109831378B (en) Message timeout response method and device
CN109218182B (en) Method and device for synchronizing routing information

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20211001