CN107666445A - A kind of distributed system MAC Address treating method and apparatus - Google Patents

A kind of distributed system MAC Address treating method and apparatus Download PDF

Info

Publication number
CN107666445A
CN107666445A CN201610619156.7A CN201610619156A CN107666445A CN 107666445 A CN107666445 A CN 107666445A CN 201610619156 A CN201610619156 A CN 201610619156A CN 107666445 A CN107666445 A CN 107666445A
Authority
CN
China
Prior art keywords
mac address
subsystem
entry
distributed system
flag
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.)
Granted
Application number
CN201610619156.7A
Other languages
Chinese (zh)
Other versions
CN107666445B (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.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN201610619156.7A priority Critical patent/CN107666445B/en
Publication of CN107666445A publication Critical patent/CN107666445A/en
Application granted granted Critical
Publication of CN107666445B publication Critical patent/CN107666445B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/08Learning-based routing, e.g. using neural networks or artificial intelligence

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Medical Informatics (AREA)
  • Small-Scale Networks (AREA)

Abstract

The present invention proposes a kind of distributed system MAC Address treating method and apparatus, wherein, this method includes:In the case that aging occurs for MAC Address in the second subsystem, the first subsystem receives the notice message for the MAC address aging that second subsystem is sent, wherein, first subsystem is located in same distributed system with second subsystem;First subsystem obtains the MAC Address entry of the MAC Address according to the notice message;The MAC Address entry is sent to second subsystem by first subsystem, learns the MAC Address according to the MAC Address entry for second subsystem.The present invention solves the problems, such as that message caused by subsystem MAC Address premature aging floods in the prior art, it is ensured that link aggregation field, can timely be recovered after subsystem MAC Address premature aging.

Description

A kind of distributed system MAC Address treating method and apparatus
Technical field
It is more particularly to a kind of to answer the present invention relates to the maintaining method of media access control in distributed system (MAC) address Distributed system MAC Address treating method and apparatus for link aggregation field.
Background technology
MAC address aging refers to that within a period of time system does not receive the message using some MAC Address as source MAC, Then system can be deleted the information of the MAC Address list item from the MAC Address hardware list of exchange chip, wait next message When relearn the information of the MAC Address, including MAC Address, port, the VLAN id information belonging to port.
Link aggregation (link aggregation), follows IEEE 802.3AD link aggregation protocols.Fig. 1 is according to correlation The distributed aggregated link system schematic of technology, as shown in figure 1, several physical ports can be tied up by link aggregation mechanism The a port together, formed in logic is scheduled on, realizes the purpose of increase bandwidth, and the load balancing of flow can be realized.
For distributed aggregated links system, once the port of system is not due to having new data flow in a period of time Maintain and MAC address aging occurs, but the system subsequently needs to turn the message using the MAC Address as purpose address again Hair, the message forwarding that may result in corresponding MAC Address is changed into unknown message flooding from known unicast, so as to cause channel resource Waste.
In a distributed system, message is caused to flood once MAC Address premature aging occurs for some subsystems, prior art Common practice is:
First, the subsystem MAC address aging is let alone, waits and being relearned when data flow is come next time, this method Substantially do not solve the problems, such as that MAC Address premature aging causes message to flood;
Second, notify other subsystems to concentrate aging, wait another rise when data flow is come next time to learn, this method Aging occurs for the subsystem that may cause some should not be aging, and causes the waste of resource;
3rd, by configuration order, the exchange chip that the MAC Address items for information directly is written into some subsystems is hard In part table, although this method realizes that effect is relatively good, but may be only available for physical port and be not applied for aggregation port.
Message caused by MAC Address premature aging when being E-Packeted for correlation technique in distributed aggregated links system Flooding problem, prior art do not provide solution.
The content of the invention
The present invention proposes a kind of distributed system MAC Address treating method and apparatus applied to link aggregation field, Message floods caused by solve the problems, such as subsystem MAC Address premature aging in the prior art.
To solve the above problems, technical scheme realization is as follows:
A kind of distributed system MAC Address processing method, it is characterised in that including:
In the case that aging occurs for MAC Address in the second subsystem, the first subsystem receives the second subsystem hair The notice message of the MAC address aging sent, wherein, first subsystem is located at same distribution with second subsystem In formula system;
First subsystem obtains the MAC Address entry of the MAC Address according to the notice message;
The MAC Address entry is sent to second subsystem by first subsystem, for second subsystem The MAC Address is learnt according to the MAC Address entry.
Further, first subsystem obtains the MAC Address entry bag of the MAC Address according to the notice message Include:
First subsystem inquires about the hit flag of the MAC Address from the MAC Address hardware list of exchange chip;
When the hit flag is 1, first subsystem obtains the MAC Address entry, wherein, the MAC VLAN id information where address entry includes mac address information, port information, port.
Preferably, first subsystem inquires about the hit of the MAC Address from the MAC Address hardware list of exchange chip Flag includes:
First subsystem inquires about MAC Address software register, the MAC Address software register and the MAC Address hardware list In first subsystem;
Safeguard that first subsystem is being preset when having the MAC Address entry in the MAC Address software register Time in the hit flag is repeatedly inquired about from the MAC Address hardware list.
Preferably, after first subsystem inquires about the MAC Address software register, in the MAC Address software register In also safeguard that methods described also includes when having inquiry flag corresponding to the MAC Address:
First subsystem judges whether from the MAC Address hardware list described in inquiry according to the inquiry flag Flag is hit, wherein, inquiry flag set when first subsystem receives the notice message is 1, The hit flag remains 1 when being 0, and 0 is reset to when the hit flag is 1;
First subsystem it is described inquiry flag be 1 when, within the time set in advance periodically inquiry described in Hit flag;First subsystem terminates when the inquiry flag is 0 and inquires about the hit flag.
Preferably, first subsystem according to the notice message obtain the MAC Address MAC Address entry it Afterwards, methods described also includes:
The MAC Address entry is sent in the distributed system and removes first subsystem by first subsystem Subsystem beyond system and second subsystem.
Preferably, first subsystem according to the notice message obtain the MAC Address MAC Address entry it Before, methods described also includes:
First subsystem receives the study notice message for the study MAC Address that the 3rd subsystem is sent, wherein, 3rd subsystem is located in the distributed system, and the study notice message is used for second subsystem according to Learn notice message and learn the MAC Address;
First subsystem terminates the acquisition to the MAC Address entry according to the study notice message.
Present invention also offers a kind of distributed system MAC Address processing unit, and applied in subsystem, its feature exists In, including:
Receiving module, in the case that aging occurs for MAC Address in the second subsystem, receive second subsystem The notice message of the MAC address aging sent, wherein, the subsystem is located at same distribution with second subsystem In system;
Acquisition module, for obtaining the MAC Address entry of the MAC Address according to the notice message;
Sending module, for the MAC Address entry to be sent into second subsystem, for the second subsystem root Learn the MAC Address according to the MAC Address entry.
Further, the acquisition module includes:
Submodule is inquired about, the hit for inquiring about the MAC Address from the MAC Address hardware list of exchange chip identifies Position;
Acquisition submodule, for when the hit flag is 1, obtaining the MAC Address entry, wherein, the MAC VLAN id information where address entry includes mac address information, port information, port.
Preferably, the inquiry submodule includes:
First query unit, for inquiring about MAC Address software register, the MAC Address software register and the MAC Address hardware Epitope is in the subsystem;
Second query unit, when having the MAC Address entry for being safeguarded in the MAC Address software register, advance The hit flag is repeatedly inquired about in the time of setting from the MAC Address hardware list.
Present invention also offers a kind of distributed system MAC Address processing method, it is characterised in that including:
Son in the distributed system that second subsystem is located to second subsystem in addition to second subsystem System sends the notice message of MAC address aging;
Second subsystem receives the MAC sent positioned at one or more of distributed system subsystem The MAC Address entry of address;
Second subsystem carries out the study of the MAC Address according to the MAC Address entry.
The present invention is notified to institute in distributed system when aging occurs for the MAC Address of subsystem by sending MAC agings There are other subsystems, the MAC Address entry that other subsystems are inquired about in exchange chip after having notice, be somebody's turn to do inquiring to exist After MAC Address entry, the subsystem that the MAC Address entry is returned to the generation MAC address aging learns.The present invention solves In the prior art subsystem MAC Address premature aging and caused by message the problem of flooding, it is ensured that aggregation port field, son It can be recovered in time after system MAC Address premature aging.
Brief description of the drawings
Fig. 1 is distributed aggregated link system schematic;
Fig. 2 is a kind of distributed system MAC Address process flow figure one according to embodiments of the present invention;
Fig. 3 is a kind of distributed system MAC Address processing unit being applied in subsystem according to embodiments of the present invention Block diagram one;
Fig. 4 is a kind of distributed system MAC Address processing unit being applied in subsystem according to embodiments of the present invention Block diagram two;
Fig. 5 is a kind of distributed system MAC Address processing unit being applied in subsystem according to embodiments of the present invention Block diagram three;
Fig. 6 is a kind of distributed system MAC Address process flow figure two according to embodiments of the present invention;
Fig. 7 is the method flow diagram of subsystem exchange chip reporting MAC address notice according to embodiments of the present invention;
Fig. 8 is MAC address learning/aging that a subsystem according to embodiments of the present invention receives the transmission of other subsystems The method flow diagram of notice;
Fig. 9 is the method flow diagram that a subsystem according to embodiments of the present invention obtains MAC Address entry.
Specific embodiment
Below by drawings and examples, technical scheme is described in further detail.
The embodiments of the invention provide a kind of distributed system MAC Address processing method, occurs in the MAC Address of subsystem During aging, notify to look into after having notice to every other subsystem in distributed system, other subsystems by sending MAC agings The MAC Address entry in exchange chip is ask, after inquiring in the presence of the MAC Address entry, the MAC Address entry is returned Subsystem to the generation MAC address aging learns.Fig. 2 is a kind of distributed system MAC Address according to embodiments of the present invention Process flow figure one, as shown in Fig. 2 this method is from the subsystem side for receiving aging notice, including following processing Step:
Step S202, in the case that aging occurs for MAC Address in the second subsystem, the first subsystem receives second son The notice message for the MAC address aging that system is sent, wherein, first subsystem is located at same distribution with second subsystem In formula system;
Step S204, first subsystem obtain the MAC Address entry of the MAC Address according to the notice message;
There are multiple subsystems in distributed system, for any one subsystem m, when receiving the transmission of other subsystems When MAC address aging notifies, subsystem m needs to inquire about exchange chip to help other subsystems to recover the entry.
The MAC Address entry is sent to second subsystem by step S206, first subsystem, for second subsystem The MAC Address is learnt according to the MAC Address entry.
Further, first subsystem obtains the MAC Address entry according to the notice message and included:
First subsystem inquires about the hit flag (Hit of the MAC Address from the MAC Address hardware list of exchange chip Flag);
When the hit flag is 1, first subsystem obtains the MAC Address entry, wherein, the MAC Address entry Include the information of VLAN where mac address information, port information, port.
Preferably, first subsystem inquires about the hit mark of the MAC Address from the MAC Address hardware list of exchange chip Position includes:
First subsystem inquires about MAC Address software register, and the MAC Address software register and the MAC Address hardware list are positioned at the In one subsystem;
Safeguard that first subsystem is in the time set in advance when having the MAC Address entry in the MAC Address software register Inside repeatedly inquire about the hit flag.
MAC Address entry in software register and the MAC Address entry in hardware list are consistent.Subsystem receives new During message, the subsystem writes the MAC Address entry of message in exchange chip, and subsequent reporting MAC learns, in MAC software registers The information of the MAC Address is equally write, and sends MAC address learning and notifies to every other subsystem;Identical, subsystem When no longer receiving the message, the exchange chip aging over time of the subsystem MAC Address, this is deleted in hardware list Mesh, subsequent reporting MAC aging, equally delete the information of the MAC Address in MAC software registers, and send MAC address aging notify to Every other subsystem.By setting software register, it is possible to achieve easily and efficiently inquire about and obtain the effect of MAC Address entry.
First subsystem within the predetermined time periodically or aperiodic ground query hit flag, and can ordered Middle flag goes to obtain MAC Address entry when being 1 from software register, naturally it is also possible to goes to obtain from the hardware list of exchange chip The entry, flag is hit within the predetermined time to occur the situation for being 1, the first subsystem can side as long as ensuring that The second subsystem is helped to recover the MAC Address.
Preferably, after first subsystem inquires about the MAC Address software register, also tieed up in the MAC Address software register When shield has inquiry flag corresponding to the MAC Address, this method also includes:
First subsystem judges whether to inquire about hit mark from the MAC Address hardware list according to the inquiry flag Position, wherein, inquiry flag set when first subsystem receives the notice message is 1, is 0 in the hit flag When remain 1, the hit flag be 1 when be reset to 0;
First subsystem inquires about the hit mark periodically when the inquiry flag is 1 within the time set in advance Know position;First subsystem terminates when the inquiry flag is 0 and inquires about the hit flag.
Flag is inquired about by setting, it is possible to achieve once hit flag is 1, the first subsystem will stop inquiry should Flag is hit, prevents subsystem from continuing to inquire about after MAC Address entry has been got and obtains the MAC Address entry, Cause the waste of resource.
Preferably, should after first subsystem obtains the MAC Address entry of the MAC Address according to the notice message Method also includes:
First subsystem by the MAC Address entry be sent in the distributed system except first subsystem and Subsystem beyond second subsystem.
Preferably, should before first subsystem obtains the MAC Address entry of the MAC Address according to the notice message Method also includes:
The study notice message for the study MAC Address that first subsystem receives that the 3rd subsystem sends, wherein, this Three subsystems are located in the distributed system, and the study notice message is used for second subsystem according to the study notice message Practise the MAC Address;
First subsystem terminates the acquisition to the MAC Address entry according to the study notice message.
Any one subsystem m, when receiving the MAC address learning notice of other subsystems transmission, then illustrate all sons System can maintain the entry.Subsystem m inquires about MAC Address software register, will if not having the MAC Address in software register MAC Address entry writes exchange chip, increases MAC Address list item newly in MAC Address software register, and initial interrogation flag is 0;If the MAC Address entry and inquiry flag in software register be present is 1, inquiry flag bit is resetted, without inquiring about friendship again Chip is changed, so as to reach the effect to economize on resources.
The embodiment of the present invention additionally provides a kind of distributed system MAC Address processing unit being applied in subsystem, Fig. 3 It is a kind of distributed system MAC Address processing unit block diagram one being applied in subsystem according to embodiments of the present invention, such as Fig. 3 Shown, the device includes:
Receiving module 32, in the case that aging occurs for MAC Address in the second subsystem, receive second subsystem The notice message of the MAC address aging sent, wherein, the subsystem is located at same distributed system with second subsystem In;
Acquisition module 34, for obtaining the MAC Address entry of the MAC Address according to the notice message;
Sending module 36, for the MAC Address entry to be sent into second subsystem, for the second subsystem according to this MAC Address entry learns the MAC Address.
Further, the sending module 36 is additionally operable to obtaining the MAC Address entry of the MAC Address according to the notice message Afterwards, by the MAC Address entry be sent in the distributed system except first subsystem and second subsystem with Outer subsystem.
Fig. 4 is a kind of distributed system MAC Address processing being applied in subsystem according to the preferred embodiment of the invention Device block diagram two, as shown in figure 4, the acquisition module 34 includes:
Submodule 42 is inquired about, the hit for inquiring about the MAC Address from the MAC Address hardware list of exchange chip identifies Position;
Acquisition submodule 44, for when the hit flag is 1, obtaining the MAC Address entry, wherein, the MAC Address VLAN id information where entry includes mac address information, port information, port.
Preferably, the inquiry submodule 42 includes:
First query unit, for inquiring about MAC Address software register, the MAC Address software register and the MAC Address hardware epitope In the subsystem;
Second query unit, when having the MAC Address entry for being safeguarded in the MAC Address software register, presetting Time in repeatedly inquire about the hit flag.
Preferably, first query unit includes:
Judgment sub-unit, flag is inquired about corresponding to the MAC Address for also safeguarding to have in the MAC Address software register When, judge whether to inquire about the hit flag from the MAC Address hardware list according to the inquiry flag, wherein, the inquiry mark It is 1 to know position set when first subsystem receives the notice message, 1 is remained when the hit flag is 0, in the life Middle flag is reset to 0 when being 1;
Subelement is inquired about, for when the inquiry flag is 1, inquiring about the hit periodically within the time set in advance Flag;When the inquiry flag is 0, terminates and inquire about the hit flag.
Fig. 5 is a kind of distributed system MAC Address processing being applied in subsystem according to the preferred embodiment of the invention Device block diagram three, as shown in figure 5, the device also includes:
Second receiving module 52, for obtaining the MAC Address of the MAC Address according to the notice message in first subsystem Before entry, the study notice message for learning the MAC Address that the 3rd subsystem is sent is received, wherein, the 3rd subsystem position In the distributed system, the study notice message be used for second subsystem according to the study notice message with learning the MAC Location;
Acquisition module 54 is terminated, for terminating the acquisition to the MAC Address entry according to the study notice message.
Fig. 6 is a kind of distributed system MAC Address process flow figure two according to embodiments of the present invention, such as Fig. 6 institutes Show, this method is from the subsystem side for sending aging notice, including following processing step:
Step S602, in the distributed system that the second subsystem is located to second subsystem in addition to second subsystem Subsystem send MAC address aging notice message;
Step S604, second subsystem receives to be somebody's turn to do positioned at what one or more of distributed system subsystem was sent The MAC Address entry of MAC Address;
Step S606, second subsystem carry out the study of the MAC Address according to the MAC Address entry.
Embodiment one
The embodiment of the present invention additionally provides a kind of distributed system MAC Address processing method, including:
It is assumed that there are 3 subsystems in a distributed system.The port x of subsystem 1, the port y of subsystem 2, subsystem 3 Port z, add aggregation group sg1.In a period of time, port trunking group is by hash algorithm or other modes selection by member Port x receives message, and message carries source MAC 1 and purpose MAC 2, and member port y, z do not receive the message.
Member port x receives message, write in exchange chip MAC Address hardware list the message MAC Address entry it Afterwards, the exchange chip reporting MAC study notice of subsystem 1, MAC software registers increase list item newly, and (MAC1, sg1, inquiry mark are 0), sub System 1 sends MAC address learning and notified to subsystem 2 and subsystem 3.
Fig. 7 is the method flow diagram of subsystem exchange chip reporting MAC address notice, as shown in fig. 7, this method includes step Suddenly:
The notice of step S702, the study of subsystem exchange chip reporting MAC address or aging;
Step S704, subsystem start exchange chip and report processing module;
Step S706, exchange chip report processing module to judge whether notice is aging notice;
When judged result is to be, into step S708;
Step S708, exchange chip report processing module to delete the MAC Address list item from MAC Address software register;
Step S710, exchange chip report processing module to send MAC address aging and notified to all in distributed system Other subsystems;
When judged result is no, into step S712;
Step S712, exchange chip report processing module to increase MAC Address list item newly in software register, with initializing the MAC The inquiry flag of location is 0;
Step S714, exchange chip report processing module to send MAC address learning and notified to all in distributed system Other subsystems.
Subsystem 2 and subsystem 3 receive subsystem 1 and send MAC address learning notice, inquire about respective MAC software registers, send out The MAC Address is not present in existing software register, then writes the MAC Address entry in exchange chip MAC Address hardware list, and MAC Address software register increases list item newly, and (MAC1, sg1, inquiry mark is 0).
Fig. 8 is that subsystem receives the method flow diagram that MAC address learning/aging of other subsystems transmission notifies, such as Fig. 8 Shown, the method comprising the steps of:
Step S802, subsystem receive the MAC address learning or aging notice of other subsystems transmission;
Step S804, judge whether MAC Address notice is aging notice;
When judged result is is not aging notice, i.e. study notice, into step S806;
Step S806, judge to whether there is the MAC Address list item in MAC Address software register;
When judged result is in the absence of the MAC Address list item, into step S808;
Step S808, the MAC Address entry of the MAC Address is write in the hardware list of exchange chip;
Step S810, subsystem start exchange chip and report processing module;
Step S812, exchange chip report processing module to increase MAC Address list item newly in software register;
Step S814, the inquiry flag for initializing the MAC Address are 0;
When judged result is in the presence of the MAC Address list item, into step S816;
Step S816, the inquiry flag for resetting the MAC Address are 0;
When judged result is that aging notifies, into step S818;
Step S818, judge to whether there is the MAC Address list item in MAC Address software register;
When judged result is in the presence of the MAC Address list item, into step S820;
Step S820, the inquiry flag of the set MAC Address is 1.
Subsystem 2 and subsystem 3 learn a period of time, member port y, z after the MAC Address entry and do not receive message, By ageing time, MAC agings can occur for subsystem 2 and subsystem 3.
It is assumed that the reporting MAC aging of 2 exchange chip elder generations of subsystem, then subsystem 2 deletes the MAC Address bar from MAC software registers Mesh, and send MAC address aging and notify to subsystem 1 and subsystem 3.
Subsystem 1 and subsystem 3 receive MAC agings notice, are inquired respectively from MAC Address software register in the presence of the MAC Address, then modification inquiry flag is 1.Therefore the MAC address entries of subsystem 1 and subsystem 3 are all updated to (MAC1, sg1, look into Ask mark 1).
It is assumed that subsystem 3 arrives first the scan period, each MAC Address list item is successively read.It is 1 for inquiry flag (1) MAC1, sg1, inquiry mark, inquire about the hit flag HIT flag of the MAC Address in exchange chip to MAC address entries.Due to Member port z does not receive message, therefore HIT flag are 0, can do nothing to help other subsystems and recovers entry, therefore does not make to locate Reason.
Fig. 9 is the method flow diagram that subsystem obtains MAC Address entry, as shown in figure 9, the method comprising the steps of:
Step S902, when reaching the scan period, subsystem starts MAC Address scan module;
Step S904, whether the inquiry flag for judging current MAC address is 0;
Step S906, when judged result is no, whether the hit flag for judging current MAC address is 0;
Step S908, when judged result is no, obtain the MAC Address entry of the MAC Address;
Step S910, send MAC address learning and notify to give other all subsystems;
Step S912, the inquiry flag for resetting the MAC Address are 0;
Step S914, judge whether to need the information for reading next MAC Address list item;
When judged result is to be, continue step S904.
The then also reporting MAC aging of the exchange chip of subsystem 3, then delete the MAC Address list item, concurrently from MAC software registers MAC address aging is sent to notify to subsystem 1 and subsystem 2.
Subsystem 1 and subsystem 2 receive MAC agings notice.Due to the weathered MAC of subsystem 2, cannot also help Recovery entry is helped, therefore is not dealt with.Subsystem 1, which inquires, has the MAC address entries in software register, set inquiry flag is 1.
Subsystem 1 is successively read each MAC Address list item to the scan period.The MAC table for being 1 for inquiry flag (MAC1, sg1, inquire about and identify 1), the HIT flag of the MAC Address in inquiry exchange chip.Because member port x is received always To message, therefore HIT flag are 1, then send MAC address learning and notify to subsystem 2 and subsystem 3, and reset inquiry mark Position is 0.
Subsystem 2 and subsystem 3 notify to carry out the study of MAC Address according to MAC address learning.
Embodiment two
The embodiment of the present invention additionally provides a kind of distributed system MAC Address processing method, including:
It is assumed that there are 3 subsystems in a distributed system.The port x of subsystem 1, the port y of subsystem 2, subsystem 3 Port z, add aggregation group sg1.In a period of time, port trunking group is by hash algorithm or other modes selection by member Port x receives message, and message carries source MAC 1 and purpose MAC 2, and member port y, z do not receive the message.This time Afterwards, member port x no longer receives message, and member port y, z do not receive the message yet.
Member port x receives message, the exchange chip reporting MAC study of subsystem 1, and MAC software registers increase list item newly (MAC1, sg1,0), subsystem 1 sends MAC address learning and notified inquiry mark to subsystem 2 and subsystem 3.
Subsystem 2 and subsystem 3 receive mac learning notice, inquire about respective MAC software registers, find not deposit in software register In the MAC Address, then the MAC Address entry is write in exchange chip MAC hardware lists, and list item is increased newly in MAC software registers (MAC1, sg1, inquiry mark is 0).
In a period of time, member port y, z do not receive message, and by ageing time, subsystem 2 and subsystem 3 can be sent out Raw MAC agings.
It is assumed that the reporting MAC aging of 2 exchange chip elder generations of subsystem, then subsystem 2 deletes the MAC Address bar from MAC software registers Entry, and send MAC address aging and notify to subsystem 1 and subsystem 3.
Subsystem 1 and subsystem 3 receive MAC agings notice, are inquired respectively from MAC software registers in the presence of the MAC Address List item, and it is 1 to change inquiry flag.Therefore the MAC address entries of subsystem 1 and subsystem 3 are all updated to (MAC1, sg1, inquiry Mark is 1).It is assumed that subsystem 3 arrives first the scan period.It is successively read each MAC Address list item.The MAC for being 1 for inquiry flag (1) MAC1, sg1, inquiry mark, inquire about the hit flag HIT flag of the MAC Address in exchange chip to list item.Due to member Port z does not receive message, therefore HIT flag are 0, can do nothing to help other subsystems and recovers entry, therefore does not deal with.
The also reporting MAC aging of the exchange chip of subsystem 3, then delete the MAC, and send MAC address aging from MAC software registers Notify to subsystem 1 and subsystem 2.
Subsystem 1 and subsystem 2 receive MAC agings notice.Due to the weathered MAC of subsystem 2, cannot also help Recovery entry is helped, therefore is not dealt with.Subsystem 1 inquires the MAC, and set inquiry flag is 1.
Subsystem 1 is successively read each MAC Address list item to the scan period.For the MAC address entries of inquiry mark 1 (1) MAC1, sg1, inquiry mark, inquire about the HIT flag of the MAC Address in exchange chip.Because member port x is no longer received Message, therefore HIT flag are 0, can do nothing to help other subsystems and recover entry, therefore do not deal with.
After a period of time, the also reporting MAC aging of the exchange chip of subsystem 1, due to subsystem 2, subsystem 3 are weathered should It MAC, cannot also help to recover entry, therefore not deal with.So far, subsystem 1, subsystem 2 and all agings of subsystem 3 should MAC.
The foregoing is only presently preferred embodiments of the present invention, be not intended to limit the invention, it is all the present invention spirit and Any modification, equivalent substitution and improvements done within principle etc., should be included within the scope of protection of the invention.

Claims (10)

  1. A kind of 1. distributed system MAC Address processing method, it is characterised in that including:
    In the case that aging occurs for MAC Address in the second subsystem, the first subsystem receives what second subsystem was sent The notice message of the MAC address aging, wherein, first subsystem is with second subsystem positioned at same distributed system In system;
    First subsystem obtains the MAC Address entry of the MAC Address according to the notice message;
    The MAC Address entry is sent to second subsystem by first subsystem, for second subsystem according to The MAC Address entry learns the MAC Address.
  2. 2. the method as described in claim 1, it is characterised in that first subsystem is according to obtaining the notice message The MAC Address entry of MAC Address includes:
    First subsystem inquires about the hit flag of the MAC Address from the MAC Address hardware list of exchange chip;
    When the hit flag is 1, first subsystem obtains the MAC Address entry, wherein, the MAC Address VLAN id information where entry includes mac address information, port information, port.
  3. 3. method as claimed in claim 2, it is characterised in that MAC Address hardware of first subsystem from exchange chip The hit flag of the MAC Address is inquired about in table to be included:
    First subsystem inquires about MAC Address software register, and the MAC Address software register is located at the MAC Address hardware list In first subsystem;
    Safeguarded in the MAC Address software register when having the MAC Address entry, first subsystem is when set in advance It is interior that the hit flag is repeatedly inquired about from the MAC Address hardware list.
  4. 4. method as claimed in claim 3, it is characterised in that inquire about the MAC Address software register in first subsystem Afterwards, also safeguard that methods described is also wrapped when having inquiry flag corresponding to the MAC Address in the MAC Address software register Include:
    First subsystem judges whether to inquire about the hit from the MAC Address hardware list according to the inquiry flag Flag, wherein, inquiry flag set when first subsystem receives the notice message is 1, described Hit flag remains 1 when being 0, and 0 is reset to when the hit flag is 1;
    First subsystem inquires about the hit periodically when the inquiry flag is 1 within the time set in advance Flag;First subsystem terminates when the inquiry flag is 0 and inquires about the hit flag.
  5. 5. the method as described in Claims 1-4 is any, it is characterised in that reported in first subsystem according to the notice After text obtains the MAC Address entry of the MAC Address, methods described also includes:
    First subsystem by the MAC Address entry be sent in the distributed system except first subsystem and Subsystem beyond second subsystem.
  6. 6. method as claimed in claim 5, it is characterised in that institute is obtained according to the notice message in first subsystem Before the MAC Address entry for stating MAC Address, methods described also includes:
    First subsystem receives the study notice message for the study MAC Address that the 3rd subsystem is sent, wherein, it is described 3rd subsystem is located in the distributed system, and the study notice message is used for second subsystem according to the study Notice message learns the MAC Address;
    First subsystem terminates the acquisition to the MAC Address entry according to the study notice message.
  7. A kind of 7. distributed system MAC Address processing unit, applied in subsystem, it is characterised in that including:
    Receiving module, in the case that aging occurs for MAC Address in the second subsystem, receive second subsystem and send The MAC address aging notice message, wherein, the subsystem and second subsystem are located at same distributed system In;
    Acquisition module, for obtaining the MAC Address entry of the MAC Address according to the notice message;
    Sending module, for the MAC Address entry to be sent into second subsystem, for second subsystem according to institute State MAC Address entry and learn the MAC Address.
  8. 8. device as claimed in claim 7, it is characterised in that the acquisition module includes:
    Submodule is inquired about, for inquiring about the hit flag of the MAC Address from the MAC Address hardware list of exchange chip;
    Acquisition submodule, for when the hit flag is 1, obtaining the MAC Address entry, wherein, the MAC Address VLAN id information where entry includes mac address information, port information, port.
  9. 9. device as claimed in claim 8, it is characterised in that the inquiry submodule includes:
    First query unit, for inquiring about MAC Address software register, the MAC Address software register and the MAC Address hardware epitope In the subsystem;
    Second query unit, when having the MAC Address entry for being safeguarded in the MAC Address software register, presetting Time in the hit flag is repeatedly inquired about from the MAC Address hardware list.
  10. A kind of 10. distributed system MAC Address processing method, it is characterised in that including:
    Subsystem in the distributed system that second subsystem is located to second subsystem in addition to second subsystem Send the notice message of MAC address aging;
    Second subsystem receives the MAC Address sent positioned at one or more of distributed system subsystem MAC Address entry;
    Second subsystem carries out the study of the MAC Address according to the MAC Address entry.
CN201610619156.7A 2016-07-29 2016-07-29 Distributed system MAC address processing method and device Active CN107666445B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610619156.7A CN107666445B (en) 2016-07-29 2016-07-29 Distributed system MAC address processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610619156.7A CN107666445B (en) 2016-07-29 2016-07-29 Distributed system MAC address processing method and device

Publications (2)

Publication Number Publication Date
CN107666445A true CN107666445A (en) 2018-02-06
CN107666445B CN107666445B (en) 2021-09-07

Family

ID=61122399

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610619156.7A Active CN107666445B (en) 2016-07-29 2016-07-29 Distributed system MAC address processing method and device

Country Status (1)

Country Link
CN (1) CN107666445B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109413225A (en) * 2018-11-28 2019-03-01 新华三技术有限公司 A kind of MAC address entries processing method and equipment
CN111935337A (en) * 2020-09-17 2020-11-13 南京中兴软件有限责任公司 MAC address keep-alive method, equipment and storage medium of aggregation link

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100440200B1 (en) * 2001-10-23 2004-07-14 엘지전자 주식회사 MAC Address Table Management Method In L2 Switch
US20100158019A1 (en) * 2008-12-22 2010-06-24 Fujitsu Limited Frame transfer apparatus and frame transfer method
CN101834781A (en) * 2010-03-16 2010-09-15 中兴通讯股份有限公司 Media access control address keep-alive device and method for convergence port
CN101969398A (en) * 2010-09-17 2011-02-09 中兴通讯股份有限公司 Aging method and system of MAC (Media Access Control) address
CN103731355A (en) * 2013-12-31 2014-04-16 迈普通信技术股份有限公司 Method and system for avoiding Hash collision during MAC address learning

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100440200B1 (en) * 2001-10-23 2004-07-14 엘지전자 주식회사 MAC Address Table Management Method In L2 Switch
US20100158019A1 (en) * 2008-12-22 2010-06-24 Fujitsu Limited Frame transfer apparatus and frame transfer method
CN101834781A (en) * 2010-03-16 2010-09-15 中兴通讯股份有限公司 Media access control address keep-alive device and method for convergence port
CN101969398A (en) * 2010-09-17 2011-02-09 中兴通讯股份有限公司 Aging method and system of MAC (Media Access Control) address
CN103731355A (en) * 2013-12-31 2014-04-16 迈普通信技术股份有限公司 Method and system for avoiding Hash collision during MAC address learning

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109413225A (en) * 2018-11-28 2019-03-01 新华三技术有限公司 A kind of MAC address entries processing method and equipment
CN111935337A (en) * 2020-09-17 2020-11-13 南京中兴软件有限责任公司 MAC address keep-alive method, equipment and storage medium of aggregation link
CN111935337B (en) * 2020-09-17 2021-01-08 南京中兴软件有限责任公司 MAC address keep-alive method, equipment and storage medium of aggregation link
WO2022057865A1 (en) * 2020-09-17 2022-03-24 中兴通讯股份有限公司 Mac address keep-alive method and device for aggregated link, and storage medium

Also Published As

Publication number Publication date
CN107666445B (en) 2021-09-07

Similar Documents

Publication Publication Date Title
US11297000B2 (en) Data transmission method, apparatus, and system
US8611361B2 (en) Switching hub, line card and frame relay method
EP1779605B1 (en) Forwarding database in a network switch device
US8259718B2 (en) Network relay apparatus
WO2016050158A1 (en) Learning a mac address in vxlan
CN105247831A (en) Flow table modifying method, flow table modifying device, and openflow network system
US10652145B2 (en) Managing data frames in switched networks
US8750122B1 (en) Method and apparatus for layer 2 loop prevention in a multi-node switch cluster
US20180167311A1 (en) Forwarding of Multicast Packets in a Network
CN103931144B (en) A kind of method, apparatus and system communicated in virtual Domain
CN101662426A (en) T-MPLS tunnel protection processing method and system thereof
JPWO2007066814A1 (en) Frame processing method and frame processing apparatus
CN105187311A (en) Message forwarding method and message forwarding device
CN107666445A (en) A kind of distributed system MAC Address treating method and apparatus
CN104734953A (en) Method and device for achieving message layer-2 isolation based on VLAN and interchanger
CN108683606A (en) Method, apparatus, the network equipment and the readable storage medium storing program for executing of IPsec anti-replays
US20160301628A1 (en) Consolidation Encodings Representing Designated Receivers in a Bit String
JP5889218B2 (en) Data transfer apparatus and data transfer method
US9521091B2 (en) Relay system and switching device
KR20150145700A (en) Method of using a unique packet identifier to identify structure of a packet and an apparatus thereof
CN103139067B (en) Based on the mthods, systems and devices of VRRP protocol extension virtual router quantity
CN104883337A (en) Ring network user safety realizing method and apparatus
EP2847933B1 (en) Methods, systems, and computer readable media for combining ip fragmentation evasion techniques
CN112543142B (en) Method and device for realizing RSTP ring network protocol based on FPGA
US10708166B2 (en) Method and a first device for managing data frames in switched networks

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