CN111818192B - Communication method of gateway cluster, network equipment and gateway cluster system - Google Patents

Communication method of gateway cluster, network equipment and gateway cluster system Download PDF

Info

Publication number
CN111818192B
CN111818192B CN202010564277.2A CN202010564277A CN111818192B CN 111818192 B CN111818192 B CN 111818192B CN 202010564277 A CN202010564277 A CN 202010564277A CN 111818192 B CN111818192 B CN 111818192B
Authority
CN
China
Prior art keywords
mapping data
data table
network device
static
network devices
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.)
Active
Application number
CN202010564277.2A
Other languages
Chinese (zh)
Other versions
CN111818192A (en
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.)
Shenzhen Zhongwang Xin'an Technology Co ltd
Original Assignee
Shenzhen Zhongwang Xin'an Technology 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 Shenzhen Zhongwang Xin'an Technology Co ltd filed Critical Shenzhen Zhongwang Xin'an Technology Co ltd
Priority to CN202010564277.2A priority Critical patent/CN111818192B/en
Publication of CN111818192A publication Critical patent/CN111818192A/en
Application granted granted Critical
Publication of CN111818192B publication Critical patent/CN111818192B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/10Mapping addresses of different types
    • H04L61/103Mapping addresses of different types across network layers, e.g. resolution of network layer into physical layer addresses or address resolution protocol [ARP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network

Landscapes

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

Abstract

The application discloses a communication method of a gateway cluster, network equipment and a gateway cluster system, wherein the method comprises the following steps: the communication method comprises the following steps: acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices in communication connection with a first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one by one based on the first static mapping data table; in response to the state change of the at least one second network device, acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table. By the method, the communication efficiency among the network devices can be improved, and the storage pressure of the gateway cluster system is relieved.

Description

Communication method of gateway cluster, network equipment and gateway cluster system
Technical Field
The present application relates to the field of network communication technologies, and in particular, to a communication method for a gateway cluster, a network device, and a gateway cluster system.
Background
ARP (Address Resolution protocol) is a protocol that resolves an IP Address into a MAC Address (or referred to as a physical Address) of ethernet. In a local area gateway cluster, when a host or other network device has data to send to another host or device, it must know the network layer address (i.e., IP address) of the other. But it is not sufficient to have only an IP address because the IP data packet must be encapsulated into a frame to be sent over the physical network, and because the sending station must also have the physical address of the receiving station, a mapping from IP address to physical address is required. ARP is the protocol that implements this function.
In the current gateway cluster solution, in order to keep the service between cluster devices uninterrupted, the load balance is implemented on the upper network device of the cluster, and besides, the ARP entries of other network devices in the cluster are backed up in each network device of the cluster, and the ARP entries of other network devices are written into a static ARP table for storage and use. This causes the communication efficiency of the whole gateway cluster system to be reduced, and the sharp increase of the ARP cache of the whole cluster also puts storage pressure on the gateway cluster system.
Disclosure of Invention
The technical problem mainly solved by the application is to provide a communication method of a gateway cluster, network equipment and a gateway cluster system, which can improve the communication efficiency between the network equipment and relieve the storage pressure of the gateway cluster system.
A technical solution adopted in the present application is to provide a communication method between gateway clusters, which is applied to a first network device, and the communication method includes: acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices which are in communication connection with the first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table; responding to the state change of at least one second network device, and acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table.
The updating of the first static mapping data table based on the first dynamic mapping data table, and the generating of the first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table include: comparing the first dynamic mapping data table with the first static mapping data table, and if the first static mapping data table does not have second mapping data in the first dynamic mapping data table, adding the second mapping data in the first static mapping data table; and generating a first data list corresponding to the plurality of second network devices one by one based on the second mapping data.
The first network equipment comprises a second dynamic mapping data table; after deleting the first mapping data matched with the first target mapping data in the first static mapping data table, the method further comprises the following steps: sending request instructions to a plurality of second network devices based on the first target mapping data; and if a reply instruction associated with the request instruction is received, adding the first target mapping data in the second dynamic mapping data table.
The second network equipment comprises a second data list and a second static mapping data table, and the first network equipment comprises a second dynamic mapping data table; the communication method further comprises the following steps: and in response to generating second mapping data in the second dynamic mapping data table, sending the second mapping data to the second network devices, so that the second data list and the second static mapping data table are updated by the second network devices based on the second mapping data.
Wherein sending the second mapping data to the plurality of second network devices to enable the plurality of second network devices to update the second data list and the second static mapping data table based on the second mapping data comprises: sending second mapping data to a plurality of second network devices so that the plurality of second network devices judge whether the second mapping data exist in a second data list, and if so, updating time marks of the second mapping data; and if not, adding second mapping data in the second data list and the second static mapping data table.
The communication method further comprises the following steps: acquiring a timestamp of second target mapping data in the first data list; calculating a first difference between the timestamp and the current time; judging whether the first difference value exceeds a preset difference value or not; and if so, deleting the third mapping data matched with the second target mapping data in the first static mapping data table, and deleting the second target mapping data.
The communication method further comprises the following steps: sending heartbeat messages to a plurality of second network devices; and updating the second data list and the second static mapping data table by the plurality of second network devices based on the heartbeat messages respectively, wherein the heartbeat messages comprise the second dynamic mapping data table of the first network device.
Another technical solution adopted by the present application is to provide a network device, where the network device includes a processor and a memory connected to the processor; wherein the memory is adapted to store program data and the processor is adapted to execute the program data for implementing the communication method according to any of claims 1-7.
Another technical solution adopted in the present application is to provide a gateway cluster system, where the gateway cluster system includes a plurality of network devices, and the network devices are the network devices of claim 8.
Another technical solution adopted by the present application is to provide a readable storage medium, wherein the readable storage medium is used for storing program data, and the program data is used for implementing the method provided by the above technical solution when being executed by a processor.
The beneficial effect of this application is: different from the situation in the prior art, the communication method of the gateway cluster provided by the present application is applied to the first network device, and the communication method includes: acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices in communication connection with a first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table; in response to the state change of the at least one second network device, acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table. Through the method, on one hand, the first network equipment only synchronizes the dynamic ARP cache of the second network equipment in the gateway cluster by using a dynamic and static combined mode of ARP synchronization among the network equipment and stores the dynamic ARP cache as the own static ARP cache, so that the seamless access of the service flow after the standby node is newly added in the gateway cluster is realized, on the other hand, when at least one second network equipment in the gateway cluster cannot work, the static ARP cache corresponding to the second network equipment in the first network equipment can be deleted, the static ARP attempt is converted into the dynamic ARP, the storage pressure of the gateway cluster system is reduced, the problem that the static ARP cache cannot be refreshed is solved, and the communication efficiency among the network equipment can be improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts. Wherein:
fig. 1 is a schematic flowchart of a first embodiment of a communication method of a gateway cluster provided in the present application;
FIG. 2 is a schematic flow chart of step 12 of FIG. 1 provided herein;
FIG. 3 is a schematic flow chart diagram showing details of FIG. 1 following step 14 provided herein;
fig. 4 is a schematic flowchart of a second embodiment of a communication method of a gateway cluster provided in the present application;
fig. 5 is a schematic flowchart of a third embodiment of a communication method of a gateway cluster provided in the present application;
FIG. 6 is a schematic structural diagram of an embodiment of a network device provided in the present application;
fig. 7 is a schematic structural diagram of an embodiment of a gateway cluster system provided in the present application;
fig. 8 is a schematic structural diagram of an embodiment of a readable storage medium provided in the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It is to be understood that the specific embodiments described herein are merely illustrative of and not restrictive on the broad application. It should be further noted that, for the convenience of description, only some of the structures associated with the present application are shown in the drawings, not all of them. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
Referring to fig. 1, fig. 1 is a schematic flowchart of a first embodiment of a communication method of a gateway cluster provided in the present application. Applied to a first network device, the method comprises:
step 11: and acquiring a first dynamic mapping data table.
The first dynamic mapping data table is sent by a plurality of second network devices which are in communication connection with the first network device. It is understood that the dynamic mapping data table is a dynamic ARP (Address Resolution Protocol) table, in which an IP (Internet Protocol, protocol for interconnection between networks) Address and a MAC (Media Access Control) Address are stored, and the IP Address and the MAC Address are in one-to-one correspondence.
In this embodiment, the gateway cluster includes a first network device and a plurality of second network devices. The first network device is communicatively coupled to a plurality of second network devices. The first network device and the second network device may be the same type of device or different types of devices. The first network device and the plurality of second network devices can be mobile terminals and PC terminals; or may be a gateway device such as a router, switch, etc.
It can be understood that, since the gateway cluster includes a plurality of second network devices, the first network device may acquire a plurality of first dynamic mapping data tables. Each first dynamic mapping data table corresponds to one second network device.
Step 12: and updating the first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one by one based on the first static mapping data table.
In some embodiments, referring to fig. 2, step 12 may specifically be the following steps:
step 121: and comparing the first dynamic mapping data table with the first static mapping data table, and if the second mapping data in the first dynamic mapping data table does not exist in the first static mapping data table, adding the second mapping data in the first static mapping data table.
In particular, the following table is referred to for illustration:
Figure BDA0002547236480000051
Figure BDA0002547236480000061
the first dynamic mapping data table comprises second mapping data a, second mapping data b, second mapping data c and second mapping data d. The first static mapping data table comprises mapping data a, mapping data d, mapping data e and second mapping data c. And comparing to find that the second mapping data b does not exist in the first static mapping data table, and adding the second mapping data b into the first static mapping data table.
And traversing the first dynamic mapping data tables to find second mapping data which does not exist in the first static mapping data table from the first dynamic mapping data tables and add the second mapping data to the first static mapping data table.
Step 122: and generating a first data list corresponding to the plurality of second network devices one by one based on the second mapping data.
Further, since the second mapping data added to the first static mapping data table is from the first dynamic mapping data table sent by the plurality of second network devices, the second mapping data is generated into the first data list corresponding to the plurality of second network devices one to one. Because a plurality of second network devices exist, a plurality of first data lists correspond to the second network devices. If the plurality of second network devices include the second network device a, the second network device b, and the second network device c, the plurality of second network devices correspond to the first dynamic mapping data table a, the first dynamic mapping data table b, and the first dynamic mapping data table c. If the second mapping data a in the first dynamic mapping data table a, the second mapping data b in the first dynamic mapping data table b, and the second mapping data c in the first dynamic mapping data table c are added to the first static mapping data table in step 121, a first data list a, a first data list b, and a first data list c are correspondingly generated. The first data list a includes information of the second network device a and the second mapping data a. The first data list b includes information of the second network device b and the second mapping data b. The first data list c includes information of the second network device c and the second mapping data c.
Through the mode, the second data in the dynamic mapping data tables in the second network devices are stored in the static mapping data table of the first network device, so that the service flow is not interrupted during working, a large amount of static mapping data can not be stored, and the storage pressure of the whole gateway cluster is relieved.
Step 13: in response to a change in status of the at least one second network device, first target mapping data corresponding to the at least one second network device is obtained from the first data list.
In some embodiments, if the second network device crashes, malfunctions, or does not operate, or is replaced, the first network device obtains the first target mapping data corresponding to the at least one second network device from the first data list in response to the state change of the at least one second network device. The information of the second network device is stored in the first data list, the first data list corresponding to the first network device is found by traversing the plurality of first data lists, and the first target mapping data is obtained from the first data list.
Step 14: first mapping data matching the first target mapping data is deleted in the first static mapping data table.
In some embodiments, referring to fig. 3, after step 14, further comprising:
step 141: request instructions are sent to a plurality of second network devices based on the first target mapping data.
In some embodiments, the status of at least one second network device changes but does not represent a change in the device to which the mapping data stored therein corresponds. Then a request needs to be sent to the plurality of second network devices based on the first target mapping data.
In some embodiments, the first network device sends a request instruction to a device associated therewith based on the first target mapping data.
Step 142: and if a reply instruction associated with the request instruction is received, adding the first target mapping data in the second dynamic mapping data table.
For example, the first target mapping data includes binding information of IP + MAC. The request instruction may here instead execute an "alert IP" command, IP being the IP address information recorded in the first target mapping data, such as alert 192.168.1.8. When this command is executed, the gateway cluster system will automatically query the mac address of the IP. And if a reply instruction of the mac address is received, adding the first target mapping data in the second dynamic mapping data table.
In some embodiments, the first network device and the second network device may be dynamically adjusted, and when the current network device is in processing work, the current network device is the first network device, and the rest of the current network device is the second network device.
In some embodiments, the first network device may be a newly added network device in the entire gateway cluster, and the steps of this embodiment may be implemented when the first network device is added to the gateway cluster. Thus, the first network device synchronizes the first dynamic mapping data table (dynamic ARP cache) from the plurality of second network devices. Therefore, as long as the service flow passing through the second network device is distributed to the first network device for bearing, the first network device can directly realize flow without learning ARP again, and the seamless access of the service flow after the standby node is newly added in the cluster is realized.
In an application scenario, a second network device a and a second network device B exist in a gateway cluster, at this time, a first network device C is newly added, the second network device a and the second network device B detect that a new device is added into the gateway cluster, the second network device a and the second network device B respectively query dynamic ARP caches in corresponding systems, and package and send the dynamic ARP caches to the newly added first network device C. After receiving the dynamic ARP sent by the second network device a and the second network device B, the first network device C queries whether a corresponding dynamic ARP cache already exists in its own system, and if not, the first network device C stores the dynamic ARP cache in a static ARP cache and stores the static ARP cache in an ARP record table (a first data list), and the ARP cache synchronized with the second network device a is stored in a record table ListA, and the ARP cache synchronized with the second network device B is stored in a record table ListB. Thus, the first network device C records the ARP caches synchronized by the second network device a and the second network device B, respectively. Therefore, if the service flow passing through the second network device a and the second network device B is allocated to the first network device C for carrying, the first network device C can directly flow through without learning the ARP again, and seamless access of the service flow after the network device is newly added in the gateway cluster is realized.
In another application field, a gateway cluster may cause a certain network device to be removed from the line during the working process for various reasons. Examples illustrate that: the gateway cluster is provided with three gateways of equipment A, B and C. At this time, the device C is removed from the cluster, and after the devices a and B detect that the device C is removed, the device a traverses the ARP table ListC that is recorded and synchronized with the device C, deletes the corresponding system static ARP cache and table entry, and lets the device learn the corresponding ARP information by sending an ARP request packet, so as to implement the conversion of ARP from static to dynamic. Therefore, the static ARP of the equipment C and the corresponding record table which are originally stored on the equipment A and the equipment B are deleted, and meanwhile, the system learns the dynamic ARP, so that the storage resource of the system is saved, and the seamless switching of the service flow which flows through the equipment C to the equipment A or the equipment B can be ensured.
Different from the situation in the prior art, the communication method of the gateway cluster provided by the present application is applied to the first network device, and the communication method includes: acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices in communication connection with a first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table; in response to the state change of the at least one second network device, acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table. Through the above manner, on one hand, the dynamic ARP cache of the second network equipment in the gateway cluster is only synchronized by the first network equipment by utilizing the dynamic and static combined manner of ARP synchronization among the network equipment and is stored as the own static ARP cache, thereby realizing the seamless access of the service flow after the new addition of the standby node in the gateway cluster, and on the other hand, when at least one second network equipment in the gateway cluster cannot work, the static ARP cache corresponding to the second network equipment in the first network equipment is deleted, and the static ARP attempt is converted into the dynamic ARP, thereby reducing the storage pressure of the gateway cluster system and solving the problem that the static ARP cache cannot be refreshed.
Referring to fig. 4, fig. 4 is a schematic flowchart of a second embodiment of a communication method of a gateway cluster provided in the present application. The communication method comprises the following steps:
step 41: and in response to generating second mapping data in the second dynamic mapping data table, sending the second mapping data to the plurality of second network devices, so that the plurality of second network devices update the second data list and the second static mapping data table based on the second mapping data.
The second network device comprises a second data list and a second static mapping data table, and the first network device comprises a second dynamic mapping data table.
In some embodiments, the second mapping data is sent to a plurality of second network devices, so that the plurality of second network devices determine whether the second mapping data exists in the second data list, and if so, update the time stamp of the second mapping data; and if not, adding second mapping data in the second data list and the second static mapping data table.
In some embodiments, the first network device is further configured to send heartbeat messages to a plurality of second network devices; and updating a second data list and a second static mapping data table by the plurality of second network devices based on heartbeat messages respectively, wherein the heartbeat messages comprise a second dynamic mapping data table of the first network device.
The devices of the gateway cluster send heartbeat messages to each other to confirm whether other devices in the gateway cluster are alive or not. The keep-alive heartbeat messages are sent out at regular time, in order to ensure that the ARP can be completely and accurately synchronized to other second network equipment in the gateway cluster, the heartbeat messages carry the dynamic ARP cache of the first network equipment to be sent to other equipment, and therefore the defect that packet loss or omission exists in the process of adding the dynamic ARP cache in the newly added network equipment and the network equipment is avoided. For example, devices a, B, and C exist in the gateway cluster. The fixed time interval between the devices sends heartbeat messages to other devices. When the device A sends heartbeat messages to the devices B and C, the dynamic ARP cache of the self system is inquired, and the ARP caches are added into the heartbeat messages. The devices B and C receive the heartbeat message of the device A, on one hand, the device A is proved to be still alive in the cluster, on the other hand, the dynamic ARP cache of the device A is analyzed, whether the items exist in the ARP table recorded in the system of the device A is inquired, if the items exist, the time stamps of the items in the record table are not updated, if the items do not exist, a static ARP cache is added to the system, and meanwhile, an item is added to the synchronous ARP record table ListA of the recording device A.
In an application scenario, three devices a, B, and C exist in the gateway cluster, and a new flow passes through the device a to generate a new ARP cache, and at this time, the device is identified as the first network device, and the devices B and C are the second network devices in this embodiment. The device A synchronizes the dynamic ARP cache information to the devices B and C in the cluster immediately, the devices B and C traverse the stored ARP information table (second data list) after receiving the ARP synchronization message, whether the same table entry already exists or not is judged, if yes, the timestamp (time mark) of the corresponding information is updated, if not, an information is added to the ARP recording table ListA, and meanwhile, an ARP static cache is configured for the system. Therefore, the newly added service flow can be ensured to be learned on one device, and all devices in the gateway cluster can learn. If the newly added service flow is switched to the device B and the device C again at this time, the ARP learning can be directly passed without being continued. Therefore, seamless switching and uninterrupted flow of the newly added service flow on any equipment in the cluster are ensured.
Referring to fig. 5, fig. 5 is a schematic flowchart of a communication method of a gateway cluster according to a third embodiment of the present application. The method comprises the following steps:
step 51: a timestamp of the second target mapping data in the first data list is obtained.
In some embodiments, in consideration of the fact that the storage time of the data in the first static mapping data table may be too long, a timing device is provided at the first network device, and when the timing device is started, the timestamp of the second target mapping data in the first data list is obtained.
Step 52: a first difference between the timestamp and the current time is calculated.
For example, the time stamp is 2020-02-28. The current time is 2020-06-17. The first difference is 109.
Step 53: and judging whether the first difference value exceeds a preset difference value.
And judging whether the first difference exceeds a preset difference, if so, executing a step 54, and if not, not changing. If the predetermined difference is 60 and the first difference is 109, go to step 54.
Step 54: and deleting the third mapping data matched with the second target mapping data in the first static mapping data table, and deleting the second target mapping data.
By the mode, system storage can be reduced, system performance is improved, and the problem of flow break after the binding relation between the service stream IP and the MAC is changed can be relieved.
In an application scenario, there are devices a, B, and C in a gateway cluster, and the ARP caches in the devices B and C are written in the device a system, and written in the system in the form of a static ARP cache. Meanwhile, an ARP record list B and a ListC are arranged in the device A and respectively record ARP caches synchronized by the device B and the device C, and a time stamp synchronized by each ARP cache is recorded in the record list. And starting a timer, judging the time stamps recorded by the entries in the ListB and the ListC, comparing the time stamps with the current system time, and comparing the difference value with the set aging time. And if the aging time is over, the ARP is considered to be aged, the corresponding ARP static cache in the equipment A system is deleted, and the ListB or the ListC is removed from the entry. Therefore, the overhead of system storage can be reduced, and the problem of flow interruption after the binding relationship between the service flow IP and the MAC is changed is solved.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an embodiment of a network device provided in the present application. The network device 60 comprises a processor 61 and a memory 62 connected to the processor 61; wherein the memory 62 is adapted to store program data and the processor is adapted to execute the program data to perform the following method steps:
acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices which are in communication connection with the first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one by one based on the first static mapping data table; responding to the state change of at least one second network device, and acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table.
The network device 60 may be a first network device or a second network device.
It will be appreciated that the processor 61 is also operative to execute program data to implement any of the embodiment methods described above.
Referring to fig. 7, fig. 7 is a schematic structural diagram of an embodiment of a gateway cluster system provided in the present application. The gateway cluster system 70 comprises a plurality of network devices 71, wherein the network devices 71 are any network devices in the above embodiments to implement the method in any of the above embodiments.
Referring to fig. 8, fig. 8 is a schematic structural diagram of an embodiment of a readable storage medium provided in the present application. The readable storage medium 80 is for storing program data 81, the program data 81, when being executed by a processor, being for realizing the method steps of:
acquiring a first dynamic mapping data table, wherein the first dynamic mapping data table is sent by a plurality of second network devices in communication connection with a first network device; updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table; in response to the state change of the at least one second network device, acquiring first target mapping data corresponding to the at least one second network device from the first data list; the first mapping data matching the first target mapping data is deleted in the first static mapping data table.
It will be appreciated that the program data 81, when executed by a processor, is also for implementing any of the embodiment methods described above.
In the several embodiments provided in the present application, it should be understood that the disclosed method and apparatus may be implemented in other manners. For example, the above-described device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit. The integrated unit may be implemented in the form of hardware, or may also be implemented in the form of a software functional unit.
The integrated units in the other embodiments described above may be stored in a computer-readable storage medium if they are implemented in the form of software functional units and sold or used as separate products. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, a network device, or the like) or a processor (processor) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above description is only for the purpose of illustrating embodiments of the present application and is not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application or are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (10)

1. A communication method of a gateway cluster is applied to a first network device, and the communication method comprises the following steps:
acquiring a plurality of first dynamic mapping data tables, wherein each first dynamic mapping data table is sent by a plurality of second network devices in communication connection with the first network device, and each first dynamic mapping data table corresponds to one second network device;
updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one by one based on the first static mapping data table;
in response to the state change of at least one second network device, acquiring first target mapping data corresponding to the at least one second network device from the first data list;
deleting the first mapping data matched with the first target mapping data in the first static mapping data table.
2. The communication method according to claim 1,
the updating a first static mapping data table based on the first dynamic mapping data table, and generating a first data list corresponding to the plurality of second network devices one to one based on the first static mapping data table, includes:
comparing the first dynamic mapping data table with the first static mapping data table, and if the second mapping data in the first dynamic mapping data table does not exist in the first static mapping data table, adding the second mapping data in the first static mapping data table;
and generating a first data list corresponding to the plurality of second network devices in a one-to-one manner based on the second mapping data.
3. The communication method according to claim 1,
the first network device comprises a second dynamic mapping data table;
after deleting the first mapping data matched with the first target mapping data in the first static mapping data table, the method further includes:
sending request instructions to the plurality of second network devices based on the first target mapping data;
and if a reply instruction associated with the request instruction is received, adding the first target mapping data in the second dynamic mapping data table.
4. The communication method according to claim 1,
the second network device comprises a second data list and a second static mapping data table, and the first network device comprises a second dynamic mapping data table;
the communication method further comprises the following steps:
in response to generating second mapping data in the second dynamic mapping data table, sending the second mapping data to the plurality of second network devices to cause the plurality of second network devices to update the second data list and the second static mapping data table based on the second mapping data.
5. The communication method according to claim 4,
the sending the second mapping data to the plurality of second network devices to cause the plurality of second network devices to update the second data list and the second static mapping data table based on the second mapping data comprises:
sending the second mapping data to the plurality of second network devices, so that the plurality of second network devices judge whether the second mapping data exist in the second data list, and if yes, updating time marks of the second mapping data; and if not, adding the second mapping data in the second data list and the second static mapping data table.
6. The communication method according to claim 1,
the communication method further comprises the following steps:
acquiring a timestamp of second target mapping data in the first data list;
calculating a first difference between the timestamp and the current time;
judging whether the first difference value exceeds a preset difference value or not;
and if so, deleting third mapping data matched with the second target mapping data in the first static mapping data table, and deleting the second target mapping data.
7. The communication method according to claim 1,
the communication method further comprises the following steps:
sending heartbeat messages to the plurality of second network devices; and updating a second data list and a second static mapping data table by the plurality of second network devices based on the heartbeat messages respectively, wherein the heartbeat messages comprise a second dynamic mapping data table of the first network device.
8. A network device comprising a processor and a memory coupled to the processor;
wherein the memory is used for storing program data and the processor is used for executing the program data to realize the communication method according to any one of claims 1-7.
9. A gateway cluster system, characterized in that the gateway cluster system comprises a plurality of network devices, the network devices being as claimed in claim 8.
10. A readable storage medium for storing program data for implementing a communication method according to any one of claims 1 to 7 when executed by a processor.
CN202010564277.2A 2020-06-19 2020-06-19 Communication method of gateway cluster, network equipment and gateway cluster system Active CN111818192B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010564277.2A CN111818192B (en) 2020-06-19 2020-06-19 Communication method of gateway cluster, network equipment and gateway cluster system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010564277.2A CN111818192B (en) 2020-06-19 2020-06-19 Communication method of gateway cluster, network equipment and gateway cluster system

Publications (2)

Publication Number Publication Date
CN111818192A CN111818192A (en) 2020-10-23
CN111818192B true CN111818192B (en) 2022-11-01

Family

ID=72846241

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010564277.2A Active CN111818192B (en) 2020-06-19 2020-06-19 Communication method of gateway cluster, network equipment and gateway cluster system

Country Status (1)

Country Link
CN (1) CN111818192B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101175080A (en) * 2007-07-26 2008-05-07 杭州华三通信技术有限公司 Method and system for preventing ARP message attack
CN101483602A (en) * 2009-01-23 2009-07-15 清华大学 Method for IPv4 server access by IPv6 server based on quasi-static mapping
CN101634942A (en) * 2008-07-24 2010-01-27 北大方正集团有限公司 Method and system for dynamically creating data tables
CN102123078A (en) * 2010-12-31 2011-07-13 上海顶竹通讯技术有限公司 Method and device for generating third-level user adaptation layer dynamic routing table in soft switch gateway
US8934378B1 (en) * 2012-09-30 2015-01-13 Emc Corporation Resilient cache-based topology detection of a dynamic cluster
CN106453120A (en) * 2015-08-05 2017-02-22 北京网御星云信息技术有限公司 Dynamic clustering method and dynamic clustering system
CN109669716A (en) * 2018-09-25 2019-04-23 深圳壹账通智能科技有限公司 Page control method, device, equipment and readable storage medium storing program for executing

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070014301A1 (en) * 2005-07-13 2007-01-18 Motient Corporation Method and apparatus for providing static addressing
US9996058B2 (en) * 2013-12-19 2018-06-12 General Electric Company Systems and methods for dynamic mapping for end devices of control systems
US10037388B2 (en) * 2015-04-27 2018-07-31 Microsoft Technology Licensing, Llc Fast querying of social network data

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101175080A (en) * 2007-07-26 2008-05-07 杭州华三通信技术有限公司 Method and system for preventing ARP message attack
CN101634942A (en) * 2008-07-24 2010-01-27 北大方正集团有限公司 Method and system for dynamically creating data tables
CN101483602A (en) * 2009-01-23 2009-07-15 清华大学 Method for IPv4 server access by IPv6 server based on quasi-static mapping
CN102123078A (en) * 2010-12-31 2011-07-13 上海顶竹通讯技术有限公司 Method and device for generating third-level user adaptation layer dynamic routing table in soft switch gateway
US8934378B1 (en) * 2012-09-30 2015-01-13 Emc Corporation Resilient cache-based topology detection of a dynamic cluster
CN106453120A (en) * 2015-08-05 2017-02-22 北京网御星云信息技术有限公司 Dynamic clustering method and dynamic clustering system
CN109669716A (en) * 2018-09-25 2019-04-23 深圳壹账通智能科技有限公司 Page control method, device, equipment and readable storage medium storing program for executing

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
基于ARP欺骗的中间人攻击的检测与防范;刘衍斌等;《微计算机信息》;20120815(第08期);全文 *
应用粒子群优化的绿色虚拟网络映射算法;曲桦等;《电信科学》;20160120(第01期);全文 *
针对ARP攻击的网络防御模式设计与实现;李海鹰等;《计算机工程》;20050505(第05期);全文 *

Also Published As

Publication number Publication date
CN111818192A (en) 2020-10-23

Similar Documents

Publication Publication Date Title
CN109379291B (en) Method and device for processing service request in networking
CN100490411C (en) Method for studying MAC address and network element apparatus
CN102025630A (en) Load balancing method and load balancing system
CN108011958B (en) Network device and MAC address table synchronization method
US9270558B2 (en) Method, local gateway, and system for local voice survivability
US20150326526A1 (en) Keeping a terminal access location record alive
CN101764751A (en) Method, system and equipment for forwarding roaming messages for wireless user terminal travelling across VLAN
CN109274592B (en) MAC address table item processing method and device and computer readable medium
CN103560961A (en) Method for dynamically updating host routing table entries of Ethernet switch and switch
CN113839862B (en) Method, system, terminal and storage medium for synchronizing ARP information between MCLAG neighbors
CN112367257B (en) Route notification method and device
CN101316234B (en) Route condition detecting method, device and system
US9130938B2 (en) Method, switch, and system for processing a message
CN1319338C (en) Method for soluting IP address conflicts in network communication
CN103812957B (en) ARP record management method and apparatus
CN111327509B (en) Information updating method and device
CN101404594B (en) Hot backup performance test method and apparatus, communication equipment
CN112866107B (en) IP address notification method, traffic guidance method and network equipment
CN100423514C (en) Data synchronization method in distributed equipment according to address resolution protocol
EP3570169A1 (en) Method and system for processing device failure
CN111818192B (en) Communication method of gateway cluster, network equipment and gateway cluster system
EP4184822A1 (en) Method and apparatus for keeping user terminal alive
CN109361781B (en) Message forwarding method, device, server, system and storage medium
CN113949658A (en) Table item processing method, system, device, electronic equipment and storage medium
CN111555970A (en) Network switching method, system and storage medium based on dual-computer redundancy system

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
GR01 Patent grant
GR01 Patent grant
CP03 Change of name, title or address

Address after: 1401, No. 100 Zhihe Road, Dakang Community, Yuanshan Street, Longgang District, Shenzhen City, Guangdong Province 518100

Patentee after: Shenzhen Zhongwang Xin'an Technology Co.,Ltd.

Country or region after: China

Address before: 518000 Room 201, building A, No. 1, Qian Wan Road, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen, Guangdong (Shenzhen Qianhai business secretary Co., Ltd.)

Patentee before: Shenzhen Zhongwang Xin'an Technology Co.,Ltd.

Country or region before: China