CN116055455A - MAC address aging processing method and device, LPU card and storage medium - Google Patents

MAC address aging processing method and device, LPU card and storage medium Download PDF

Info

Publication number
CN116055455A
CN116055455A CN202310121834.7A CN202310121834A CN116055455A CN 116055455 A CN116055455 A CN 116055455A CN 202310121834 A CN202310121834 A CN 202310121834A CN 116055455 A CN116055455 A CN 116055455A
Authority
CN
China
Prior art keywords
lpu
mac address
card
cards
aging
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310121834.7A
Other languages
Chinese (zh)
Inventor
郭明权
胡祖松
刘一帆
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Maipu Communication Technology Co Ltd
Original Assignee
Maipu Communication 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 Maipu Communication Technology Co Ltd filed Critical Maipu Communication Technology Co Ltd
Priority to CN202310121834.7A priority Critical patent/CN116055455A/en
Publication of CN116055455A publication Critical patent/CN116055455A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/32Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames
    • 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
    • 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
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention provides a method, a device, equipment and a storage medium for processing MAC address aging, and relates to the field of data communication. According to the method, address aging information of preset MAC addresses learned by an aggregation link of distributed equipment, which is sent by an exchange chip, is synchronized to other LPU cards through a source LPU card, whether the preset MAC addresses written in the exchange chip in a dynamic aging mode are deleted or not is determined according to hit mark information which is returned by the other LPU cards and is obtained according to the preset MAC address query hit mark, and therefore flow flooding of the distributed equipment caused by the fact that the preset MAC addresses are directly deleted from the exchange chip is avoided, and packet loss is avoided.

Description

MAC address aging processing method and device, LPU card and storage medium
Technical Field
The present invention relates to the field of data communications, and in particular, to a method and apparatus for aging a MAC address, an LPU card, and a storage medium.
Background
Aging of the MAC (Media Access Control, medium access control) address means that, within a certain time range, the device does not receive a message with the learned MAC address as the source MAC, and the device considers that the MAC entry has failed, deletes the entry information of the MAC address, and relearns the MAC address when receiving the message next time.
With the rapid development of data centers, the bandwidth of a single-port link cannot be used, and an aggregate link can bind a plurality of single-port links together, so that the bandwidth is increased, and the reliability of the link is improved. The aging processing mode of the MAC address learned based on the aggregation link is to delete and restore the MAC address, namely the equipment directly deletes the MAC address after receiving the address aging information aiming at the MAC address, informs other equipment, and relearns the MAC address after receiving the learning information about the MAC address sent by other equipment, wherein before restoring the MAC address, the flow forwarded by the equipment is flooded and more bandwidth is required to be consumed. Since the bandwidth of the aggregate link is limited, the bandwidth of the flooding traffic is also typically limited, that is, packet loss occurs.
Disclosure of Invention
In order to overcome the defects in the prior art, the embodiment of the invention provides a method and a device for processing aging of an MAC address, an LPU card and a storage medium.
The technical scheme of the embodiment of the invention can be realized as follows:
in a first aspect, an embodiment of the present invention provides a method for aging a MAC address, which is applied to an LPU card in a distributed device, where the distributed device further includes a switch chip, and the LPU card is communicatively connected to the switch chip, where the method includes:
if the self is a source LPU card and address aging information of a preset MAC address learned by an aggregation link of the distributed equipment and sent by the exchange chip is received, synchronizing the address aging information to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address;
and determining whether the preset MAC address written in by the self in a dynamic aging mode is deleted from the exchange chip according to hit mark information returned by other LPU cards in the distributed equipment.
Optionally, the step of determining whether to delete the preset MAC address written in the dynamic aging manner from the switch chip according to hit mark information returned by other LPU cards in the distributed device includes:
if hit mark information returned by other LPU cards in the distributed equipment meets a preset deleting condition, deleting the preset MAC address written in by the dynamic aging mode from the exchange chip.
Optionally, the method further comprises:
and sending an address deleting instruction to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment delete the preset MAC address written in the switching chip in a dynamic non-aging mode from the switching chip.
Optionally, the step of determining whether to delete the preset MAC address written in the dynamic aging manner from the switch chip according to hit mark information returned by other LPU cards in the distributed device further includes:
if hit mark information returned by other LPU cards in the distributed equipment does not meet a preset deletion condition, determining a new source LPU card from the other LPU cards in the distributed equipment according to the hit mark information returned by the other LPU cards in the distributed equipment, and sending an address update instruction to the new source LPU card so that the new source LPU card rewrites the preset MAC address into the exchange chip in a dynamic aging mode.
Optionally, the method further comprises:
according to the update synchronization instruction sent by the new source LPU card, modifying the source LPU card information recorded in the local table entry so that the source LPU card is not used as the source LPU card;
and rewriting the preset MAC address into the exchange chip in a dynamic aging-free mode.
Optionally, the method further comprises:
if the self is not the source LPU card and the address aging information aiming at the preset MAC address and sent by the current source LPU card in the distributed equipment is received, inquiring whether the self receives a message carrying the preset MAC address or not;
and generating hit mark information according to the query result, and returning the hit mark information to the current source LPU card.
In a second aspect, an embodiment of the present invention provides an apparatus for aging MAC addresses, which is applied to an LPU card in a distributed device, where the distributed device further includes a switch chip, and the LPU card is communicatively connected to the switch chip, where the apparatus includes:
the synchronization module is used for synchronizing the address aging information to other LPU cards in the distributed equipment if the LPU card is a source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment, which is sent by the exchange chip, is received, so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address;
and the processing module is used for determining whether the preset MAC address written by the LPU card in a dynamic aging mode is deleted from the exchange chip according to hit mark information returned by other LPU cards in the distributed equipment.
In a third aspect, an embodiment of the present invention provides an LPU card, where the LPU card includes a logic device, and the logic device is burned with a computer program, and when the computer program is executed, the MAC address aging processing method described in the foregoing first aspect is implemented.
In a fourth aspect, the present invention provides a distributed device comprising a switching chip and a plurality of LPU cards as described in the foregoing third aspect.
In a fifth aspect, the present invention provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the MAC address aging processing method as described in the foregoing first aspect.
Compared with the prior art, the method for processing the MAC address aging of the LPU card applied to the distributed equipment provided by the embodiment of the invention firstly, if the LPU card is the source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment and sent by the exchange chip is received, the address aging information is synchronized to other LPU cards in the distributed equipment, so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address; then, according to hit mark information returned by other LPU cards in the distributed equipment, whether the preset MAC address written in the dynamic aging mode is deleted from the exchange chip is determined. According to the embodiment of the invention, the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment, which is sent by the exchange chip, is synchronized to other LPU cards through the source LPU card, whether the preset MAC address written in by the exchange chip in a dynamic aging mode is deleted or not is determined according to the hit mark information which is returned by the other LPU cards and is obtained according to the hit mark of the preset MAC address query, so that the problem that the flow flooding of the distributed equipment is caused by directly deleting the preset MAC address from the exchange chip is avoided, and further the packet loss is avoided.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic structural diagram of a distributed device according to an embodiment of the present invention;
fig. 2 is a flowchart of a method for aging a MAC address according to an embodiment of the present invention;
fig. 3 is a schematic flow chart II of a method for aging a MAC address according to an embodiment of the present invention;
fig. 4 is a flowchart of a MAC address aging processing method according to an embodiment of the present invention;
fig. 5 is a diagram illustrating an exemplary MAC address aging process according to an embodiment of the present invention;
fig. 6 is a functional unit block diagram of a MAC address aging processing apparatus according to an embodiment of the present invention.
Icon: 100-MAC address aging processing device; 101-a synchronization module; 102-a processing module.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. The components of the embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the invention, as presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It should be noted that: like reference numerals and letters denote like items in the following figures, and thus once an item is defined in one figure, no further definition or explanation thereof is necessary in the following figures.
It should be noted that the features of the embodiments of the present invention may be combined with each other without conflict.
The MAC address is an identification identifying the LAN (Local Area Network ) node, and is globally unique to the device. The MAC address is in the two-layer switching equipment and is mainly used for guiding the known data forwarding, so that the stability of the MAC address is ensured to be a necessary basic function of the equipment.
With the rapid development of data centers, the bandwidth of a single-port link cannot be used, and an aggregate link can bind a plurality of single-port links together, so that the bandwidth is increased, and the reliability of the link is improved. It can be understood that based on the MAC address learned by the aggregated link, the correct processing of the aging of the MAC address needs to be ensured, so as to effectively reflect the reliability of the link.
The aging of the MAC address means that the whole device does not receive a message taking the learned MAC address as the source MAC within a certain time range, the device considers that the table entry information of the MAC address has failed, and the device deletes the table entry information of the MAC address, and relearns the MAC address when receiving the message next time.
In a data center scenario, an aggregation link is widely used to improve the reliability of the link, and when traffic migrates between aggregation member ports, the stability of the address will affect the reliability of the link, and the bandwidth consumption under large data. The aging treatment scheme after the learning of the MAC address of the aggregation link is as follows: after the equipment receives the aging information, the related table entry information of the MAC address is directly deleted, a notification is sent, other equipment with the function of receiving the MAC address message sends out learning information, and the table entry information of the MAC address is restored after the equipment receives the learning information.
That is, the existing aging processing method for the MAC address learned based on the aggregated link is "delete before restore", and before the MAC address is restored, the traffic forwarded by the device is flooded, which requires more bandwidth consumption. Since the bandwidth of the aggregate link is limited, the bandwidth of the flooding traffic is also typically limited, that is, packet loss occurs.
Because the data center has strict requirements on packet loss, and zero packet loss is generally required, the embodiment of the invention provides a method for aging the MAC address, which is described in detail below.
The MAC address aging processing method provided by the embodiment of the invention is applied to any LPU card in the distributed equipment shown in figure 1.
As shown in fig. 1, there are a plurality of LPU (Line Processing Unit ) cards, such as LPU card 1, LPU card 2, …, and LPU card n, respectively, on a distributed device, and there is an aggregate link port L on the distributed device, where the aggregate link port L includes a plurality of member ports, and the member ports may be ports of LPU card 1, LPU card 2, …, and LPU card n, for example, the member port of the aggregate link port L includes port C of port B, LPU card 3 of port A, LPU card 2 of LPU card 1.
In the embodiment of the present invention, only the active LPU card among the LPU cards on the distributed device is a switch chip (not shown in fig. 1) that writes the MAC address learned for the aggregation link of the distributed device in a dynamic aging manner, and the other LPU cards are switch chips that write the MAC address learned for the aggregation link of the distributed device in a dynamic non-aging manner.
Referring to fig. 2, the MAC address aging processing method includes steps S101 to S102.
S101, if the LPU card is the source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment and sent by the exchange chip is received, synchronizing the address aging information to other LPU cards in the distributed equipment, so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address.
It can be understood that only the active LPU card in the distributed device writes the preset MAC address learned for the aggregation link of the distributed device into the switch chip in a dynamic aging manner, which means that after reaching the aging detection period, the switch chip will send corresponding address aging information to the source LPU card if detecting that the MAC address is aged.
The other LPU cards write the preset MAC address learned by the aggregation link for the distributed device into the switch chip in a dynamic non-aging manner, which means that the preset MAC address does not perform aging detection on the switch chip, and the source LPU card can only synchronize the address aging information to the other LPU cards.
In the embodiment of the invention, two possible situations exist, namely, the exchange chip reports address aging information aiming at a preset MAC address to the source LPU card, one is that the distributed equipment does not receive a message taking the preset MAC address as the source MAC, and the other is that the distributed equipment receives the message taking the preset MAC address as the source MAC, but the traffic in the distributed equipment migrates from the source LPU card to other LPU cards.
Therefore, in the latter case, it is required that other LPU cards query whether there is a message hit entering the distributed device through the aggregation link and the source MAC is a preset MAC address according to the preset MAC address, generate hit flag information according to the query result, and return the hit flag information to the source LPU card.
S102, determining whether to delete the preset MAC address written in the exchange chip in a dynamic aging mode according to hit mark information returned by other LPU cards in the distributed equipment.
Referring to FIG. 3, step S102 may include substeps S102-1 to S102-2.
S102-1, if hit mark information returned by other LPU cards in the distributed equipment meets a preset deleting condition, deleting the preset MAC address written in by the dynamic aging mode from the exchange chip.
The preset deleting condition refers to a message that hit mark information returned by other LPU cards all shows that the hit source MAC is a preset MAC address.
It can be understood that when the hit mark information returned by the other LPU cards meets the preset deletion condition, the reason for making the switch chip report the address aging information for the preset MAC address to the source LPU card is that the distributed device does not receive the message with the preset MAC address as the source MAC, but the traffic in the distributed device has migrated from the source LPU card to the other LPU card.
S102-2, sending an address deleting instruction to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment delete preset MAC addresses written in the switching chip in a dynamic non-aging mode from the switching chip.
In the embodiment of the invention, the distributed device does not receive the message taking the preset MAC address as the source MAC, and the flow in the distributed device does not migrate from the source LPU card to other LPU cards, so that the source LPU card needs to send an address deleting instruction to other LPU cards when deleting the preset MAC address from the exchange chip, and the other LPU cards also delete the preset MAC address from the exchange chip.
Referring again to FIG. 3, step S102 may include sub-steps S102-3 through S102-5 in parallel with sub-steps S102-1 through S102-2.
S102-3, if hit mark information returned by other LPU cards in the distributed equipment does not meet a preset deletion condition, determining a new source LPU card from the other LPU cards in the distributed equipment according to the hit mark information returned by the other LPU cards in the distributed equipment, and sending an address update instruction to the new source LPU card so that the new source LPU card rewrites the preset MAC address into the exchange chip in a dynamic aging mode.
It can be understood that, when the hit mark information returned by the other LPU cards does not meet the preset deletion condition, it means that the reason for making the switch chip report the address aging information for the preset MAC address to the source LPU card is that the traffic in the distributed device has migrated from the source LPU card to the other LPU card, and the distributed device is still actually receiving the message with the preset MAC address as the source MAC.
In the embodiment of the invention, when the traffic in the distributed equipment migrates from the current source LPU card to other LPU cards, a new source LPU card needs to be determined again.
In the embodiment of the invention, only one message with the preset MAC address of the hit source MAC of the other LPU card may exist, or a plurality of messages with the preset MAC address of the hit source MAC of the other LPU card may exist at the same time.
In the former case, the LPU card may be determined directly as a new source LPU card, while in the latter case, a new source LPU card needs to be determined from among the LPU cards.
As a possible implementation manner, each LPU card in the distributed device may be assigned a number in advance, and the current source LPU card will hit the new source LPU card with the smallest or largest number among other LPU cards of the message whose source MAC is the preset MAC address.
As another possible implementation, the other LPU card that hits the message with the source MAC being the preset MAC address with the largest number of messages may be determined as the new source LPU card.
Since only the source LPU card in the distributed device writes the preset MAC address into the switch chip in a dynamic aging manner, after determining the new source LPU card, the new source LPU card needs to re-write the preset MAC address into the switch chip in a dynamic aging manner.
S102-4, according to the update synchronization instruction sent by the new source LPU card, modifying the source LPU card information recorded in the local table entry so that the source LPU card is not used as the source LPU card.
S102-5, rewriting the preset MAC address into the exchange chip in a dynamic non-aging mode.
In the embodiment of the invention, the new source LPU card sends the update synchronization instruction to other LPU cards, so that the other LPU cards can acquire that the new source LPU card is the new source LPU card, and the original source LPU card is triggered to rewrite the preset MAC address into the exchange chip in a dynamic non-aging mode.
Referring to fig. 4, the MAC address aging processing method further includes steps S103 to S104 juxtaposed with steps S101 to S102.
S103, if the message is not the source LPU card and the address aging information aiming at the preset MAC address and sent by the current source LPU card in the distributed equipment is received, inquiring whether the message carrying the preset MAC address is received or not.
In the embodiment of the invention, other LPU cards inquire the source MAC of a received message within a certain time range after receiving the address aging information sent by the current source LPU card.
As a possible implementation manner, in a set time range, as long as a message with a preset MAC address is queried, the query is stopped, the query result is a "hit message", and if a message with a preset MAC address is not queried in the set time range, the query result is a "miss message".
As another possible implementation manner, the number of messages with the source MAC as the preset MAC address, which are queried in the set time range, may be used as the query result.
S104, generating hit mark information according to the query result, and returning the hit mark information to the current source LPU card.
As one possible implementation, the hit flag information may be a value reflecting different query results, for example, hit flag information is 1 when the query result is "hit message", and hit flag information is 0 when the query result is "miss message".
As another possible implementation manner, when the query result is the number of messages with the queried carried source MAC being the preset MAC address, the query result may be directly used as hit mark information.
The above method provided by the embodiment of the present invention will be further described using the following examples.
As shown in fig. 5, it is assumed that there are 4 LPU cards, i.e., LPU card 1, LPU card 2, LPU card 3, and LPU card 4, on a distributed device, and there are one aggregation link port L, i.e., L with three member ports, i.e., port B of LPU card 1 and port C of LPU card 3, respectively, of port A, LPU of LPU card 1.
When the traffic entering the distributed device through the aggregation link is subjected to decision by the port A on the LPU card 1 after the decision is made on the L, and the source MAC carried by the message is MAC1, and the port B and the port C do not receive the message that the source MAC is MAC1, the LPU card 1 learns the address MAC1 and synchronizes to other LPU cards.
LPU card 1 writes MAC1 to the switch chip in a dynamically aged manner, while LPU card 2, LPU card 3, and LPU card 4 write MAC1 to the switch chip in a dynamically unaged manner.
Within a certain time range, the distributed device does not receive the message with the MAC1 as the source MAC, the exchange chip reports the address aging information aiming at the MAC1 to the LPU card 1, and the LPU card 1 synchronizes the address aging information aiming at the MAC1 to the LPU card 2, the LPU card 3 and the LPU card 4.
After the LPU card 2, the LPU card 3 and the LPU card 4 receive the address aging information for the MAC1, they all query whether there is a message hit that enters the distributed device through the aggregation link and the carried source MAC is the MAC1, and determine whether the traffic of the distributed device migrates to itself.
The LPU card 2, the LPU card 3, and the LPU card 4 generate hit flag information according to the query result, and return to the LPU card 1.
If the LPU card 1 receives the hit mark information returned by the LPU card 2, the LPU card 3 and the LPU card 4 and meets the preset deletion condition, deleting the address written in the MAC1 of the exchange chip, and notifying the LPU card 2, the LPU card 3 and the LPU card 4 to also delete the address written in the MAC1 of the exchange chip.
If the LPU card 1 receives the message that the hit source MAC of the hit flag information of the LPU card 2 is the preset MAC address from the hit flag information of the LPU card 2, the LPU card 3 and the LPU card 4 returned, the LPU card 1 determines that the LPU card 2 is a new source LPU card.
The LPU card 2 rewrites the MAC1 into the exchange chip in a dynamic aging mode, the LPU card 1 rewrites the MAC1 into the exchange chip in a dynamic non-aging mode, and the LPU card 3 and the LPU card 4 update the information record of the source LPU card, so that the change of the source LPU card in the distributed equipment is realized.
Compared with the prior art, the embodiment of the invention has the beneficial effects that: only the source LPU card in the distributed equipment writes the MAC address learned based on the aggregation link into the exchange chip in a dynamic aging mode, and other LPU cards write the MAC address into the exchange chip in a dynamic non-aging mode, so that only the source LPU card can receive the address aging information sent by the exchange chip, and the source LPU card determines whether the traffic in the distributed equipment migrates or not by synchronizing the address aging information to other LPU cards, thereby avoiding the traffic flooding of the distributed equipment caused by directly deleting the MAC address and further avoiding packet loss.
In order to perform the above method embodiments and the corresponding steps in each possible implementation manner, an implementation manner of the MAC address aging processing apparatus 100 applied to any LPU card in the distributed device is given below.
Referring to fig. 6, the MAC address aging processing apparatus 100 includes a synchronization module 101 and a processing module 102.
And the synchronization module 101 is configured to synchronize the address aging information to other LPU cards in the distributed device if the LPU card is a source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed device sent by the switch chip is received, so that the other LPU cards in the distributed device query the hit mark according to the preset MAC address.
And the processing module 102 is used for determining whether to delete the preset MAC address written by the LPU card in a dynamic aging mode from the exchange chip according to hit mark information returned by other LPU cards in the distributed equipment.
Optionally, when determining whether to delete the preset MAC address written by the LPU card in the dynamic aging manner from the switch chip according to the hit mark information returned by the other LPU cards in the distributed device, the processing module 102 is specifically configured to delete the preset MAC address written by the LPU card in the dynamic aging manner from the switch chip if the hit mark information returned by the other LPU cards in the distributed device meets a preset deletion condition; and sending an address deletion instruction to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment delete the MAC addresses written in the switching chip in a dynamic non-aging manner from the switching chip.
Optionally, when determining whether to delete the preset MAC address written by the LPU card in the dynamic aging manner from the switch chip according to the hit mark information returned by the other LPU cards in the distributed device, the processing module 102 is further specifically configured to determine, if the hit mark information returned by the other LPU cards in the distributed device does not meet the preset deletion condition, a new source LPU card from among the other LPU cards in the distributed device according to the hit mark information returned by the other LPU cards in the distributed device, and send an address update instruction to the new source LPU card, so that the new source LPU card rewrites the preset MAC address into the switch chip in the dynamic aging manner; according to the update synchronization instruction sent by the new source LPU card, modifying the source LPU card information recorded in the local table entry so that the LPU card is not used as the source LPU card any more; and rewriting the preset MAC address into the exchange chip in a dynamic aging-free mode.
Optionally, the processing module 102 is further configured to query whether the LPU card receives a message carrying a preset MAC address if the LPU card is not the source LPU card and the address aging information for the preset MAC address sent by the current source LPU card in the distributed device is received; and generating hit mark information according to the query result, and returning the hit mark information to the current source LPU card.
It will be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process of the MAC address aging processing apparatus 100 described above may refer to the corresponding process in the foregoing method embodiment, and will not be described herein again.
Further, the embodiment of the invention also provides an LPU card, which may include a logic device, where the logic device is burned with a computer program, and the computer program may be used to execute the related operations in the MAC address aging processing method provided in the above method embodiment when executed.
The embodiment of the invention also provides a computer readable storage medium containing a computer program, which when executed can be used for executing the related operations in the MAC address aging processing method provided in the above method embodiment.
In summary, in the method, the device, the equipment and the storage medium for processing the aging of the MAC address provided by the embodiments of the present invention, first, if the device is the source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed device sent by the switch chip is received, the address aging information is synchronized to other LPU cards in the distributed device, so that the other LPU cards in the distributed device query hit marks according to the preset MAC address; then, according to hit mark information returned by other LPU cards in the distributed equipment, whether the preset MAC address written in the dynamic aging mode is deleted from the exchange chip is determined. According to the embodiment of the invention, the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment, which is sent by the exchange chip, is synchronized to other LPU cards through the source LPU card, whether the preset MAC address written in by the exchange chip in a dynamic aging mode is deleted or not is determined according to the hit mark information which is returned by the other LPU cards and is obtained according to the hit mark of the preset MAC address query, so that the problem that the flow flooding of the distributed equipment is caused by directly deleting the preset MAC address from the exchange chip is avoided, and further the packet loss is avoided.
The present invention is not limited to the above embodiments, and any changes or substitutions that can be easily understood by those skilled in the art within the technical scope of the present invention are intended to be included in the scope of the present invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.

Claims (10)

1. A method for aging a MAC address, which is applied to an LPU card in a distributed device, where the distributed device further includes a switch chip, and the LPU card is communicatively connected to the switch chip, the method includes:
if the self is a source LPU card and address aging information of a preset MAC address learned by an aggregation link of the distributed equipment and sent by the exchange chip is received, synchronizing the address aging information to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address;
and determining whether the preset MAC address written in by the self in a dynamic aging mode is deleted from the exchange chip according to hit mark information returned by other LPU cards in the distributed equipment.
2. The method of claim 1, wherein the step of determining whether to delete the preset MAC address written in a dynamic aging manner from the switch chip according to hit flag information returned by other LPU cards in the distributed device comprises:
if hit mark information returned by other LPU cards in the distributed equipment meets a preset deleting condition, deleting the preset MAC address written in by the dynamic aging mode from the exchange chip.
3. The method of claim 2, wherein the method further comprises:
and sending an address deleting instruction to other LPU cards in the distributed equipment so that the other LPU cards in the distributed equipment delete the preset MAC address written in the switching chip in a dynamic non-aging mode from the switching chip.
4. The method of claim 2, wherein the step of determining whether to delete the preset MAC address written by itself in a dynamic aging manner from the switch chip according to hit flag information returned by other LPU cards in the distributed device further comprises:
if hit mark information returned by other LPU cards in the distributed equipment does not meet a preset deletion condition, determining a new source LPU card from the other LPU cards in the distributed equipment according to the hit mark information returned by the other LPU cards in the distributed equipment, and sending an address update instruction to the new source LPU card so that the new source LPU card rewrites the preset MAC address into the exchange chip in a dynamic aging mode.
5. The method of claim 4, wherein the method further comprises:
according to the update synchronization instruction sent by the new source LPU card, modifying the source LPU card information recorded in the local table entry so that the source LPU card is not used as the source LPU card;
and rewriting the preset MAC address into the exchange chip in a dynamic aging-free mode.
6. The method of claim 1, wherein the method further comprises:
if the self is not the source LPU card and the address aging information aiming at the preset MAC address and sent by the current source LPU card in the distributed equipment is received, inquiring whether the self receives a message carrying the preset MAC address or not;
and generating hit mark information according to the query result, and returning the hit mark information to the current source LPU card.
7. An apparatus for aging MAC addresses, applied to an LPU card in a distributed device, the distributed device further comprising a switch chip, the LPU card being communicatively connected to the switch chip, the apparatus comprising:
the synchronization module is used for synchronizing the address aging information to other LPU cards in the distributed equipment if the LPU card is a source LPU card and the address aging information of the preset MAC address learned by the aggregation link of the distributed equipment, which is sent by the exchange chip, is received, so that the other LPU cards in the distributed equipment inquire hit marks according to the preset MAC address;
and the processing module is used for determining whether the preset MAC address written by the LPU card in a dynamic aging mode is deleted from the exchange chip according to hit mark information returned by other LPU cards in the distributed equipment.
8. An LPU card, wherein the LPU card includes a logic device, and the logic device is burned with a computer program, and when the computer program is executed, the MAC address aging processing method according to any one of claims 1 to 6 is implemented.
9. A distributed device comprising a switch chip and a plurality of LPU cards as defined in claim 8.
10. A computer-readable storage medium, storing a computer program which, when executed by a processor, implements the MAC address aging processing method according to any one of claims 1 to 6.
CN202310121834.7A 2023-02-14 2023-02-14 MAC address aging processing method and device, LPU card and storage medium Pending CN116055455A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310121834.7A CN116055455A (en) 2023-02-14 2023-02-14 MAC address aging processing method and device, LPU card and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310121834.7A CN116055455A (en) 2023-02-14 2023-02-14 MAC address aging processing method and device, LPU card and storage medium

Publications (1)

Publication Number Publication Date
CN116055455A true CN116055455A (en) 2023-05-02

Family

ID=86120382

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310121834.7A Pending CN116055455A (en) 2023-02-14 2023-02-14 MAC address aging processing method and device, LPU card and storage medium

Country Status (1)

Country Link
CN (1) CN116055455A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101969398A (en) * 2010-09-17 2011-02-09 中兴通讯股份有限公司 Aging method and system of MAC (Media Access Control) address
US8155150B1 (en) * 2009-03-11 2012-04-10 Juniper Networks, Inc. Cooperative MAC learning/aging in highly distributed forwarding system
CN104506462A (en) * 2014-12-16 2015-04-08 福建星网锐捷网络有限公司 MAC (Media Access Control) address management method and equipment in distributed switch
CN108011958A (en) * 2017-12-06 2018-05-08 新华三技术有限公司 The network equipment and mac address table synchronous method
CN108023974A (en) * 2017-11-30 2018-05-11 新华三技术有限公司 A kind of address aging method and apparatus
CN111327717A (en) * 2020-01-20 2020-06-23 新华三大数据技术有限公司 MAC address learning method and device
CN114884878A (en) * 2022-07-12 2022-08-09 常州楠菲微电子有限公司 MAC address synchronization method for multi-switch chip stacking in hardware learning mode

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8155150B1 (en) * 2009-03-11 2012-04-10 Juniper Networks, Inc. Cooperative MAC learning/aging in highly distributed forwarding system
CN101969398A (en) * 2010-09-17 2011-02-09 中兴通讯股份有限公司 Aging method and system of MAC (Media Access Control) address
CN104506462A (en) * 2014-12-16 2015-04-08 福建星网锐捷网络有限公司 MAC (Media Access Control) address management method and equipment in distributed switch
CN108023974A (en) * 2017-11-30 2018-05-11 新华三技术有限公司 A kind of address aging method and apparatus
CN108011958A (en) * 2017-12-06 2018-05-08 新华三技术有限公司 The network equipment and mac address table synchronous method
CN111327717A (en) * 2020-01-20 2020-06-23 新华三大数据技术有限公司 MAC address learning method and device
CN114884878A (en) * 2022-07-12 2022-08-09 常州楠菲微电子有限公司 MAC address synchronization method for multi-switch chip stacking in hardware learning mode

Similar Documents

Publication Publication Date Title
US6128296A (en) Method and apparatus for distributed packet switching using distributed address tables
US9753954B2 (en) Data node fencing in a distributed file system
CN108011958B (en) Network device and MAC address table synchronization method
US20010049749A1 (en) Method and system for storing duplicate data
CN108762668B (en) Method and device for processing write conflict
CN108173691B (en) Cross-device aggregation method and device
US20190347167A1 (en) Primary Node-Standby Node Data Transmission Method, Control Node, and Database System
CN105528373A (en) Database fault processing method, device, system and server
CN104866234A (en) Data migration method, device and system
CN103152390A (en) Method and device and nodes and system for node configuration of distributed storage system
CN111049765A (en) Aggregation port switching method, device, chip, switch and storage medium
WO2016124105A1 (en) Media access control address learning method, device and system
US10073878B1 (en) Distributed deduplication storage system with messaging
JP2008172292A (en) Link trace frame transfer program, link trace frame transfer device and link trace frame transfer method
CN110912826A (en) Method and device for expanding IPFIX table items by using ACL
US20180121531A1 (en) Data Updating Method, Device, and Related System
CN107038092B (en) Data copying method and device
CN102073733A (en) Method and device for managing Hash table
CN113259264B (en) Data transmission method and device, computer equipment and storage medium
CN113612814B (en) Session information screening method, device, terminal and storage medium
CN104702508A (en) Method and system for dynamically updating table items
CN102891902B (en) Media access control address updating method and network equipment
CN116055455A (en) MAC address aging processing method and device, LPU card and storage medium
CN102984739A (en) Breakdown information processing method and processing device
CN104866245B (en) The method and apparatus of synchronisation snapshot between buffer memory device and storage 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