CN108924066B - Message forwarding method and device - Google Patents

Message forwarding method and device Download PDF

Info

Publication number
CN108924066B
CN108924066B CN201810636682.3A CN201810636682A CN108924066B CN 108924066 B CN108924066 B CN 108924066B CN 201810636682 A CN201810636682 A CN 201810636682A CN 108924066 B CN108924066 B CN 108924066B
Authority
CN
China
Prior art keywords
message
unicast
forwarding
gport
destination
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810636682.3A
Other languages
Chinese (zh)
Other versions
CN108924066A (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.)
Hangzhou H3C Technologies Co Ltd
Original Assignee
Hangzhou H3C Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou H3C Technologies Co Ltd filed Critical Hangzhou H3C Technologies Co Ltd
Priority to CN201810636682.3A priority Critical patent/CN108924066B/en
Publication of CN108924066A publication Critical patent/CN108924066A/en
Application granted granted Critical
Publication of CN108924066B publication Critical patent/CN108924066B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/25Routing or path finding in a switch fabric
    • H04L49/253Routing or path finding in a switch fabric using establishment or release of connections between ports
    • H04L49/254Centralised controller, i.e. arbitration or scheduling

Landscapes

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

Abstract

The application provides a message forwarding method and a message forwarding device. The message type of the stacked multicast message which should be originally stored in the first message queue is modified into the C2C unicast message, so that the modified message is stored in the second message queue, the problem that stacked multicast messages cannot be mutually interacted among stacked member devices due to the fact that the stacked multicast message is stored in no redundant space because a large number of data messages are stored in the first message queue is avoided, and the stability of a stacked system is guaranteed.

Description

Message forwarding method and device
Technical Field
The present application relates to network communication technologies, and in particular, to a method and an apparatus for forwarding a packet.
Background
Multiple network devices can be interconnected together through virtualization to form a distributed switching architecture. For ease of description, the distributed switching architecture will be referred to herein as a stacked system, with the network devices in the distributed switching fabric being stack member devices.
In a stacked system, the message queues supported by the forwarding chips on the stack member devices are limited. In one example, the forwarding chip on the stack member device supports 16 message queues at most, where the first 8 message queues (denoted as the first message queue) are used to store data messages and stack protocol messages such as Hello messages, and the remaining 8 message queues (denoted as the second message queue) are used to store C2C (C2C: CPU to CPU) unicast protocol messages. The C2C unicast protocol message herein refers to a unicast message for cross-device communication in a stacked system.
In application, when a large number of data messages are transmitted in the stacking system, a large number of data messages are stored in the first message queue supported by the forwarding chip on the stacking member device, which may cause that the stacking protocol messages cannot enter the first message queue because the first message queue has no extra space, and finally cause that the stacking protocol messages cannot be interacted among the stacking member devices to cause the stacking system to be split.
Disclosure of Invention
The application provides a message forwarding method and a message forwarding device, which are used for preventing stack protocol messages from being incapable of interacting among stack member equipment due to a large amount of data messages and avoiding the splitting of a stack system.
The technical scheme provided by the application comprises the following steps:
a message forwarding method is applied to stacking member equipment and comprises the following steps:
converting a stack multicast message to be sent through a local stack port into a C2C unicast message, setting a destination global port GPort of the C2C unicast message as a designated GPort, and recording the C2C unicast message to a designated message queue for forwarding; the appointed message queue is a message queue which is corresponding to a forwarding chip where the stacking port is located and used for storing C2C unicast protocol messages;
the designated GPort is used for indicating the stack member device receiving the C2C unicast message to directly send the received C2C unicast message to the CPU of the local main control board and forbid forwarding.
According to the technical scheme, the message type of the stacked multicast message which is originally stored in the first message queue is modified into the C2C unicast message, so that the modified message is stored in the second message queue, the problem that stacked multicast messages cannot be mutually interacted among stacked member devices due to the fact that a large number of data messages are stored in the first message queue and stacked multicast messages cannot be stored in a redundant space is avoided, and the stability of a stacked system is maintained.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
FIG. 1 is a flow chart of a method provided herein;
fig. 2 is a schematic diagram of implementing networking in embodiment 1 provided in the present application;
FIG. 3 is a flow chart of another method provided herein;
fig. 4 is a schematic diagram of implementing networking in embodiment 2 provided by the present application;
fig. 5 is a schematic structural diagram of the device provided in the present application.
Detailed Description
In a stacking system, there are two types of messages that affect the stability of the stacking system, one of which is: the stacking system establishes interactive messages among initial stacking member devices, and for convenience of description, such messages may be referred to as stacking multicast messages, such as commonly used Intelligent Resilient Framework (IRF) multicast messages. Another type of message is: the stack member device elected as the Master device (Master) after the stack system is established manages the remaining messages of the stack member device as the Slave device (Slave), and for convenience of description, such messages may be referred to as management control broadcast messages such as a transmission control protocol (LIPC) broadcast message.
In the stacking system, after receiving the stacking multicast message and the management control broadcast message, the stacking member device stores the received stacking multicast message and the management control broadcast message in a message queue (referred to as a first message queue) supported by a local chip and used for storing a data message, a stacking protocol message and the like. As mentioned above, the first packet queue stores data packets in addition to the stack protocol packets. When a large number of data messages are interacted among the stacking member devices, the number of data messages stored in the first message queue is large, and since the message containing capacity of the first message queue is limited, when a large number of data messages are stored in the first message queue, the first message queue is not enough to store stacking protocol messages such as stacking multicast messages and management control broadcast messages due to the limited message containing capacity, and finally stacking protocol messages such as stacking multicast messages and management control broadcast messages cannot be interacted among the stacking member devices, so that the stability of a stacking system is affected, and finally the splitting of the stacking system may be caused.
In order to solve the above problem, avoid the splitting of the stacking system which may be caused by that stacking member devices cannot interact with each other to stack protocol messages, such as stacking multicast messages and management control broadcast messages, and improve the stability of the stacking system, the present application provides the flow shown in fig. 1.
Referring to fig. 1, fig. 1 is a flow chart of a method provided by the present application. The process is applied to any stack member device in the stack system.
As shown in fig. 1, the process may include the following steps:
step 101, converting a stack multicast packet to be sent through a local stack port into a C2C unicast packet, and setting a destination global port (GPort) of the C2C unicast packet as a designated GPort.
In the application, the message type of the stacked multicast message is modified from multicast to unicast of C2C, so that the stacked multicast message is converted into a unicast message of C2C. The converted C2C unicast message herein refers to a unicast protocol message for cross-device communication in the stacked system.
In this application, as an embodiment, a designated GPort is used to indicate that the stacking member device that receives the C2C unicast message directly sends the received C2C unicast message to the CPU of the local main control board and prohibits forwarding.
As to what the specified GPort is specifically, in the present application, as an embodiment, the specified GPort may be determined by a specified Gchip identifier allocated to the present device and a port identifier of the CPU of the main control board in the present device, for example, by performing setting operation on the specified Gchip identifier allocated to the present device and the port identifier of the CPU of the main control board in the present device. As an embodiment, the setting operation may be a Hash (Hash) operation or a logical operation such as an exclusive or, and the present application is not limited in particular.
In this application, as an embodiment, each stacking member device in the stacking system is assigned a designated global chip (Gchip) identifier, and the designated Gchip identifiers assigned by different stacking member devices are different. Here, the assigned Gchip identifier assigned to the stacking member device is not within a preset Gchip identifier range for assigning a Gchip identifier to a forwarding chip on each stacking member device in the stacking system, for example, if the Gchip identifier range for assigning a Gchip identifier to a forwarding chip on each stacking member device in the stacking system is pre-assigned to be 0 to 100, the assigned Gchip identifier assigned to the stacking member device is outside the Gchip identifier range of 0 to 100.
After the stacked multicast packet is converted into the C2C unicast packet in step 101, the converted C2C unicast packet may be stored in a packet queue for storing the C2C unicast protocol packet, which is specifically described in step 102.
And 102, recording the C2C unicast message to a specified message queue for forwarding, wherein the specified message queue is a message queue corresponding to a forwarding chip where the stacking port is located and used for storing the C2C unicast protocol message.
In a specific application, the number of the C2C unicast protocol packets is not large, which results in a large space for the packet queue (denoted as the second packet queue) storing the C2C unicast protocol packets. Based on this, the method and the device make full use of the free space of the second message queue, modify the message type of the stacked multicast message originally stored in the first message queue into a C2C unicast message, and store the modified message into the second message queue, so that on one hand, the problem that the stacked multicast messages cannot be mutually interacted among stacked member devices due to the fact that a large amount of data messages are stored in the first message queue and no redundant space is used for storing the stacked multicast messages is avoided, the stability of a stacked system is guaranteed, and on the other hand, the space resource utilization rate of the second message queue is also improved.
Thus, the flow shown in fig. 1 is completed.
As can be seen from the flow shown in fig. 1, in the present application, the message types of the stacked multicast message and the management control broadcast message that should be originally stored in the first message queue are modified into the C2C unicast message, so as to store the modified message into the second message queue, thereby avoiding that the stacked multicast message cannot be mutually stacked between the stacked member devices due to the fact that the first message queue stores a large amount of data messages and no redundant space is available for storing the stacked multicast message, and maintaining the stability of the stacking system.
In this application, any stack member device in the stack system executes according to the flow shown in fig. 1, and similarly, any stack member device in the stack system also receives a C2C unicast message sent by other interconnected stack member devices according to the flow shown in fig. 1. When receiving a C2C unicast message sent by other interconnected stack member devices, if a destination GPort of the received C2C unicast message is as described above, and is used to indicate that the unicast message is sent to the CPU of the local main control board and forwarding is prohibited, the received C2C unicast message is sent to the CPU of the local main control board, and forwarding of the received C2C unicast message is prohibited.
The flow shown in fig. 1 is described below by taking the stacked multicast packet as a Hello packet as an example through embodiment 1:
example 1:
referring to fig. 2, fig. 2 is a schematic diagram of implementing networking in embodiment 1 provided by the present application. At the initial stage of the stack system setup shown in fig. 2, each stack member device in the stack system does not know the member number of the adjacent device, and once the local stack port UP is UP, a Hello message is sent.
Taking the stack member device 201 shown in fig. 2 as an example, the local stack Port1_2UP of the stack member device 201 sends a Hello packet.
Based on the description of fig. 1, the stack member device 201 (specifically, a driver (MR)) modifies the packet type of the Hello packet from multicast to unicast of C2C, at this time, the Hello packet after the modification of the type is referred to as a C2C unicast packet (which may be denoted as C2C unicast packet 200 for convenience of distinction), and sets the destination GPort of the C2C unicast packet 200 as the first GPort. The first GPort is obtained by performing setting calculation according to the assigned Gchip identifier assigned to the stack member device 201 and the CPU port identifier of the main master control board on the stack member device 201. As an embodiment, the setting operation may be a Hash (Hash) operation or a logical operation such as an exclusive or, and the present application is not limited in particular.
The stack member device 201 locally drives the MR to send the C2C unicast message 200 to the stack board (LC) where the UP Port1_2 is located. It is noted that, for one embodiment, the stack Port1_2 of the UP local to the stack member device 201 may be an aggregation Port. Based on this, if the stack Port1_2 of the local UP of the stack member device 201 is an aggregation Port, the local driver MR of the stack member device 201 selects a member Port from the Port1_2 according to the set method, such as selecting the Port1_2a, and sends the C2C unicast message 200 to the stack board where the Port1_2a is located. Here, a setting method such as a static Hash (Hash) method or the like is set.
The stacked board stores the received C2C unicast message 200 in the second message queue for storing the C2C unicast protocol message.
When the set sending time arrives, the stack member device 201 sends the C2C unicast packet 200 in the second packet queue through a stack Port on the stack board, such as Port1_2 or Port1_2 a.
After the stacking member device 202 receives the C2C unicast packet 200, analyze a destination GPort of the C2C unicast packet 200 to obtain a Gchip (referred to as a destination Gchip), and find that the destination Gchip is not within a preset Gchip identifier range for allocating a Gchip identifier to a forwarding chip on each stacking member device in the stacking system, and the destination Gchip is not a designated Gchip allocated to the present stacking member device 202, which means that the destination GPort of the C2C unicast packet 200 indicates that the stacking member device that receives the C2C unicast packet 200 directly sends the received C2C unicast packet 200 to a CPU of the local main control board and prohibits forwarding, and then directly sends the C2C unicast packet 200 to the CPU of the local main control board, and does not forward to a next hop. Here, the stack member device 202 is restricted from uploading the C2C unicast packet 200 to the CPU of the local master host board and not forwarding to the next hop, in order to avoid loops. Here, after the CPU of the local master control board of the stack member device 202 receives the C2C unicast message 200, the CPU processes the C2C unicast message 200, and the processing method is similar to the prior art and is not described here again.
Above, the stacking member device 201 is taken as an example, and other stacking member devices are similar and are not described again.
The description of embodiment 1 is completed so far.
In embodiment 1, the message type of the stacked multicast message that should be originally stored in the first message queue is modified into a C2C unicast message, so that the modified message is stored in the second message queue, which prevents the stacking member devices from being unable to interact with each other to stack the multicast message due to the fact that the first message queue stores a large amount of data messages and the stacking member devices do not have extra space to store the stacked multicast message, and ensures the stability of the stacking system.
The above is described by taking a stacked multicast packet as an example, and the following describes managing and controlling a broadcast packet:
in the stack system, the management control broadcast message is broadcast by the stack member device elected as Master in the stack system, and the purpose of the management control broadcast message is to control the stack member device as Slave. The following is described by means of fig. 3:
referring to fig. 3, fig. 3 is a flow chart of another method provided by the present application. The process is applied to any stacking member device in the stacking system, and as shown in fig. 3, the process may include the following steps:
step 301, when the device is elected to be Master, step 302 is executed, and when the device is taken as Slave, step 303 is executed.
Step 302, for each destination board on the Slave, converting the management control broadcast message to be broadcasted into a C2C unicast message of the GPort of the destination board, and recording the unicast message to the specified message queue for forwarding.
In the application, the management control broadcast message is converted into the C2C unicast message by modifying the message type of the management control broadcast message from broadcast to C2C unicast. The converted C2C unicast message herein refers to a unicast protocol message for cross-device communication in the stacked system.
Here, the target board on the Slave may specifically be each board (including an interface board, a mesh board, a main control board, etc.) on the Slave.
Here, the GPort of the destination board is obtained by performing a setting operation on a Gchip identifier allocated to a designated forwarding chip on the destination board and a port identifier of a CPU on the destination board, and as an embodiment, the setting operation may be a Hash (Hash) operation or a logical operation such as an exclusive or, and the present application is not limited in particular. In the stacking system, the Gchip of the forwarding chip on each board in each stacking member device (Master or Slave) is within a preset Gchip identification range for allocating a Gchip identification to the forwarding chip on each stacking member device in the stacking system. The above-mentioned appointed forwarding chip refers to: when the target single board has only one forwarding chip, the designated forwarding chip is the only one forwarding chip on the target single board, and when the target single board has more than two forwarding chips, the designated forwarding chip is the first forwarding chip or one of the forwarding chips on the target single board.
It should be noted that, in this step 302, the forwarding the C2C unicast packet of the GPort of which the destination GPort is the destination board may include: calculating the shortest forwarding path from the equipment to the target single board; if the calculated number of the shortest forwarding paths is 1, forwarding the C2C unicast message of the GPort with the destination GPort as the destination single board according to the calculated shortest forwarding path; if the calculated number of the shortest forwarding paths is greater than 1, selecting one path to forward the C2C unicast message with the destination GPort as the GPort of the destination single board according to a specified rule.
In step 302, the management control broadcast message, such as the LIPC broadcast message, is converted into a C2C unicast message, and the converted C2C unicast message is stored in the second message queue. As described above, the second message queue has a lot of empty spaces, and based on this, the application makes full use of the empty spaces of the second message queue, modifies the message type of the management control broadcast message that should be originally stored in the first message queue into a C2C unicast message, and stores the modified message in the second message queue, which on one hand avoids that Master cannot manage Slave due to the fact that a large amount of data messages are stored in the first message queue and no extra space is used to store the management control broadcast message, ensures stable management control of the stacking system, and on the other hand, improves the space resource utilization rate of the second message queue.
Step 303, receiving a C2C unicast message sent by a stack of interconnected member stacking devices, determining whether a target board of the received C2C unicast message exists on the device according to a target GPort of the received C2C unicast message, and if so, uploading the received C2C unicast message to the target board for processing; if not, the received C2C unicast message is continuously forwarded to another interconnected stack member device.
The flow shown in fig. 3 is completed.
Converting the management control broadcast message into a C2C unicast message through the process shown in fig. 3, and storing the converted C2C unicast message into the second message queue, so as to avoid that the first message queue stores a large amount of data messages, so that no redundant space is available for storing the management control broadcast message, and the multicast messages cannot be interactively stacked between the stack member devices, thereby ensuring the stability of the stacking system; and on the other hand, the space resource utilization rate of the second message queue is also improved.
The following describes the flow shown in fig. 3 by using the management control broadcast packet as the LIPC broadcast packet as an example through embodiment 2:
example 2:
referring to fig. 4, fig. 4 is a schematic diagram of implementing networking in embodiment 2 provided by the present application. In fig. 4, if the stack member device 401 is elected Master, the remaining stack member devices 402 to 404 are Slave.
When sending the LIPC broadcast message, the stack member device 401 serving as the Master first traverses the single boards on the Slave, and converts the LIPC broadcast message (the message type is broadcast) into a C2C unicast message (the message type is C2C unicast) corresponding to each traversed single board (marked as a destination single board). The destination GPort of the C2C unicast message is obtained by performing setting operation on the Gchip identifier allocated to the designated forwarding chip on the destination board and the port identifier of the CPU on the destination board. As an embodiment, the setting operation may be a Hash (Hash) operation or a logical operation such as an exclusive or, and the present application is not limited in particular.
Taking the destination board as a board (denoted as a board a2) on the stacking member device 402 as an example:
the stacking member device 401 sends a C2C unicast message (denoted as C2C unicast message 501) to the board a2 on the stacking member device 402, and the destination GPort of the C2C unicast message 501 is obtained by performing setting operation on the Gchip identifier assigned to the designated forwarding chip on the board a2 and the port identifier of the CPU on the board a 2.
The stack member device 401 selects a local left stack Port601 from the local two stack ports according to the shortest path first principle, and sends the C2C unicast message 501 to the stack board where the left stack Port601 is located. It is noted that, as an embodiment, Port601 may be an aggregation Port. Based on this, if the Port601 is an aggregation Port, the local driver MR of the stack member device 401 selects a member Port from the Port601 according to the setting method, and sends the unicast message 501 of C2C to the stack board where the member Port is located. Here, a setting method such as a static Hash (Hash) method or the like is set.
When the stacking board of the stacking member device 401 receives the C2C unicast message 501, the stacking board stores the received C2C unicast message 501 in the second message queue for storing the C2C unicast protocol message.
When the set sending time is up, the stack member device 401 sends the C2C unicast message 501 in the second message queue through a stack Port, such as Port601, on the stack board.
The stacking member device 402 receives the C2C unicast message 501 sent by the stacking member device 401, parses the destination Gport to obtain the destination Gchip, finds that the destination Gchip is the Gchip allocated to the forwarding chip on the board a2 in the device, and sends the C2C unicast message 501 to the board a2 (destination board) according to the destination Gchip.
Taking the destination board as a board (denoted as a board a3) on the stacking member device 303 as an example:
the stacking member device 401 sends a C2C unicast message (denoted as C2C unicast message 502) to the board a3 on the stacking member device 403, and the destination GPort of the C2C unicast message 502 is obtained by performing setting operation on the Gchip identifier assigned to the designated forwarding chip on the board a3 and the port identifier of the CPU on the board a 3.
Stack member device 401 finds equal paths from the local two-sided stack ports to stack member device 403, and stack member device 401 may randomly select one of the stack ports to send C2C unicast message 502, as an example. For example, the stack member device 401 randomly selects the right stack port602 to send the C2C unicast message 502. As another example, the stack member device 401 may select a stack port to send the C2C unicast message 502 according to a set rule. The setting principle here is: and when the equipment identifier of the source equipment for sending the message is smaller than the equipment identifier of the destination equipment, selecting the left side stacking port, otherwise, selecting the right side stacking port. The device id of the stack member device 401 is smaller than the device id of the stack member device 403, and based on the above setting principle, the stack member device 401 selects the left stack Port601 to send the C2C unicast message 502. The present embodiment forwards C2C unicast messages 502 with the stack member device 401 selecting the left stack Port 601.
The stack member device 401 sends the C2C unicast message 502 to the stack board where the left stack Port601 is located.
When the stacking board of the stacking member device 401 receives the C2C unicast message 502, the stacking board stores the received C2C unicast message 502 in the second message queue for storing the C2C unicast protocol message.
When the set sending time is up, the stack member device 401 sends the C2C unicast message 502 in the second message queue through a stack Port, such as Port601, on the stack board.
The stacking member device 402 receives the C2C unicast packet 502 sent by the stacking member device 401, analyzes the destination Gport to obtain the destination Gchip, and forwards the destination Gchip to the next hop if the destination Gchip is found not to be the Gchip allocated to the forwarding chip on the board in the device.
The stacking member device 403 receives the C2C unicast message 502, parses the destination Gport to obtain the destination Gchip, finds that the destination Gchip is a Gchip allocated to the forwarding chip on the board a3 in the device, and sends the C2C unicast message 502 to the board a3 (the destination board) according to the destination Gchip.
Taking the destination board as a board (denoted as a board a4) on the stacking member device 404 as an example:
the stack member device 401 sends a C2C unicast message (denoted as C2C unicast message 503) to the board a4 on the stack member device 404, and the destination GPort of the C2C unicast message 503 is obtained by performing setting operation on the Gchip identifier assigned to the designated forwarding chip on the board a4 and the port identifier of the CPU on the board a 4.
The stack member device 401 selects a local right stack Port602 from the local two-side stack ports according to the shortest path first principle, and sends the C2C unicast message 503 to the stack board where the right stack Port602 is located.
When the stacking board of the stacking member device 401 receives the C2C unicast message 503, the stacking board stores the received C2C unicast message 503 in the second message queue for storing the C2C unicast protocol message.
When the set sending time arrives, the stack member device 401 sends the unicast message 503 of C2C in the second message queue through a stack Port, such as Port602, on the stack board.
The stacking member device 404 receives the C2C unicast message 503 sent by the stacking member device 401, parses the destination Gport to obtain the destination Gchip, finds that the destination Gchip is the Gchip allocated to the forwarding chip on the board a4 in the device, and sends the C2C unicast message 503 to the board a4 (destination board) according to the destination Gchip.
The description of embodiment 2 is completed so far.
In embodiment 2, the message type of the management control broadcast message that should be originally stored in the first message queue is modified into a C2C unicast message, so as to store the modified message into the second message queue, which on one hand avoids that the Master cannot manage the Slave because the first message queue stores a large amount of data messages and no extra space is used to store the management control broadcast message, thereby ensuring stable management control of the stack system, and on the other hand, the space resource utilization rate of the second message queue is also improved.
The method provided by the present application is described above, and the device provided by the present application is described below:
referring to fig. 5, fig. 5 is a diagram illustrating a structure of the apparatus according to the present invention. The device is applied to stacking member equipment and comprises:
the message control unit is used for converting a stack multicast message to be sent through a local stack port into a C2C unicast message, and setting a target global port GPort of the C2C unicast message as a designated GPort; the designated GPort is used for indicating the stacking member device receiving the C2C unicast message to directly send the received C2C unicast message to a CPU of a local main control board and forbid forwarding;
a forwarding unit, configured to record the C2C unicast packet to a specified packet queue for forwarding; the designated message queue is a message queue corresponding to the forwarding chip where the stacking port is located and used for storing the C2C unicast protocol message.
As an embodiment, the specified GPort is determined by a specified global chip Gchip identifier allocated to the device and a port identifier of a CPU of an active main control board on the device.
As an embodiment, the message control unit further receives a C2C unicast message sent by other interconnected stack member devices; when the destination GPort of the received C2C unicast message is used to indicate that the message is sent to the CPU of the local main control board and forwarding is prohibited, the received C2C unicast message is sent to the CPU of the local main control board and forwarding of the received C2C unicast message is prohibited.
As an embodiment, when the device is elected as a Master device, the message control unit further converts, for each destination board of the stack member device serving as the Slave device, a management control broadcast message to be broadcasted into a C2C unicast message of a GPort of which the destination GPort is the destination board;
the forwarding unit further records a C2C unicast message of the GPort of which the destination GPort is the destination single board to the specified message queue for forwarding;
as an embodiment, forwarding the destination GPort as the C2C unicast message of the GPort of the destination board includes: calculating the shortest forwarding path from the equipment to the target single board; if the calculated number of the shortest forwarding paths is 1, forwarding the C2C unicast message of the GPort with the destination GPort as the destination single board according to the calculated shortest forwarding path; if the calculated number of the shortest forwarding paths is greater than 1, selecting one path to forward the C2C unicast message with the destination GPort as the GPort of the destination single board according to a specified rule.
As an embodiment, when the device is used as a Slave, the message control unit further determines whether a destination board of the received C2C unicast message exists on the device according to a destination GPort of the received C2C unicast message, and if so, sends the received C2C unicast message to the destination board for processing; if not, triggering the forwarding unit to continue forwarding the received C2C unicast message to another interconnected stack member device.
As an embodiment, the device uses an energy discarding function, where the energy discarding function is used to discard a message received by the device and sent from the device.
Thus, the description of the structure of the apparatus shown in fig. 5 is completed.
The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the scope of protection of the present application.

Claims (10)

1. A message forwarding method is applied to stacking member equipment and comprises the following steps:
converting a stack multicast message to be sent through a local stack port into a C2C (C2C: CPU to CPU) unicast message, setting a destination global port GPort of the C2C unicast message as a designated GPort, and recording the C2C unicast message to a designated message queue for forwarding; the appointed message queue is a message queue which is corresponding to a forwarding chip where the stacking port is located and used for storing C2C unicast protocol messages;
the designated GPort is used for indicating the stack member device receiving the C2C unicast message to directly send the received C2C unicast message to the CPU of the local main control board and forbid forwarding.
2. The method according to claim 1, wherein the specified GPort is determined by a specified global chip Gchip id assigned to the device and a port id of a CPU of an active main control board on the device.
3. The method of claim 1, further comprising:
receiving C2C unicast messages sent by other interconnected stack member devices;
when the destination GPort of the received C2C unicast message is used to indicate that the message is sent to the CPU of the local main control board and forwarding is prohibited, the received C2C unicast message is sent to the CPU of the local main control board and forwarding of the received C2C unicast message is prohibited.
4. The method of claim 1, wherein when the device is elected to be a Master device Master, the method further comprises:
and for each target board on the stacking member device as the Slave, converting the management control broadcast message to be broadcasted into a C2C unicast message of the GPort of which the target GPort is the target board, and recording the unicast message to the specified message queue for forwarding.
5. The method of claim 4, wherein forwarding the C2C unicast packet of the destination GPort of the destination board comprises:
calculating the shortest forwarding path from the equipment to the target single board;
if the calculated number of the shortest forwarding paths is 1, forwarding the C2C unicast message of the GPort with the destination GPort as the destination single board according to the calculated shortest forwarding path;
if the calculated number of the shortest forwarding paths is greater than 1, selecting one path to forward the C2C unicast message with the destination GPort as the GPort of the destination single board according to a specified rule.
6. The method of claim 1, wherein when the device is a Slave, the method further comprises:
receiving a C2C unicast message sent by a stack member device of the interconnection;
determining whether a destination veneer of the received C2C unicast message exists on the device according to a destination GPort of the received C2C unicast message,
if yes, the received C2C unicast message is sent to the target single board for processing;
if not, the received C2C unicast message is continuously forwarded to another interconnected stack member device.
7. The method of claim 1,
the method comprises the step of enabling an energy source discarding function at the equipment, wherein the energy source discarding function is used for discarding messages received by the equipment and sent by the equipment.
8. A message forwarding device is applied to a stacking member device, and comprises:
a message control unit, configured to convert a stack multicast message to be sent through a local stack port into a C2C (C2C: CPU to CPU) unicast message, and set a destination global port GPort of the C2C unicast message as a designated GPort; the designated GPort is used for indicating the stacking member device receiving the C2C unicast message to directly send the received C2C unicast message to a CPU of a local main control board and forbid forwarding;
a forwarding unit, configured to record the C2C unicast packet to a specified packet queue for forwarding; the designated message queue is a message queue corresponding to the forwarding chip where the stacking port is located and used for storing the C2C unicast protocol message.
9. The apparatus according to claim 8, wherein the message control unit further receives C2C unicast messages sent by other interconnected stack member devices; when the destination GPort of the received C2C unicast message is used to indicate that the message is sent to the CPU of the local main control board and forwarding is prohibited, the received C2C unicast message is sent to the CPU of the local main control board and forwarding of the received C2C unicast message is prohibited.
10. The apparatus according to claim 8, wherein when the device is elected as a Master device, the message control unit further converts, for each destination board that is a stacking member device of the Slave device, a management control broadcast message to be broadcasted into a C2C unicast message of a GPort of which a destination GPort is a destination board;
the forwarding unit further records a C2C unicast message of the GPort of which the destination GPort is the destination single board to the specified message queue for forwarding;
when the device is used as Slave, the message control unit further determines whether a destination board of the received C2C unicast message exists on the device according to a destination GPort of the received C2C unicast message, and if so, sends the received C2C unicast message to the destination board for processing; if not, triggering the forwarding unit to continue forwarding the received C2C unicast message to another interconnected stack member device.
CN201810636682.3A 2018-06-20 2018-06-20 Message forwarding method and device Active CN108924066B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810636682.3A CN108924066B (en) 2018-06-20 2018-06-20 Message forwarding method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810636682.3A CN108924066B (en) 2018-06-20 2018-06-20 Message forwarding method and device

Publications (2)

Publication Number Publication Date
CN108924066A CN108924066A (en) 2018-11-30
CN108924066B true CN108924066B (en) 2020-09-08

Family

ID=64420186

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810636682.3A Active CN108924066B (en) 2018-06-20 2018-06-20 Message forwarding method and device

Country Status (1)

Country Link
CN (1) CN108924066B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115086254B (en) * 2022-06-06 2023-11-28 上海华信长安网络科技有限公司 Method and device for synchronizing MAC (media access control) table entries under multi-switch stacking system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102143035A (en) * 2010-06-04 2011-08-03 华为技术有限公司 Data traffic processing method, network device and network system
CN104283811A (en) * 2013-07-09 2015-01-14 杭州华三通信技术有限公司 Message forwarding method and device
CN105871993A (en) * 2015-12-14 2016-08-17 美的集团股份有限公司 Cloud access system and method based on wireless communication module
WO2017065895A1 (en) * 2015-10-16 2017-04-20 Qualcomm Incorporated System and method for device-to-device communication with evolved machine type communication
WO2017215390A1 (en) * 2016-06-13 2017-12-21 中兴通讯股份有限公司 Method and device for selecting data forwarding port of longitudinal stack system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102143035A (en) * 2010-06-04 2011-08-03 华为技术有限公司 Data traffic processing method, network device and network system
CN104283811A (en) * 2013-07-09 2015-01-14 杭州华三通信技术有限公司 Message forwarding method and device
WO2017065895A1 (en) * 2015-10-16 2017-04-20 Qualcomm Incorporated System and method for device-to-device communication with evolved machine type communication
CN105871993A (en) * 2015-12-14 2016-08-17 美的集团股份有限公司 Cloud access system and method based on wireless communication module
WO2017215390A1 (en) * 2016-06-13 2017-12-21 中兴通讯股份有限公司 Method and device for selecting data forwarding port of longitudinal stack system

Also Published As

Publication number Publication date
CN108924066A (en) 2018-11-30

Similar Documents

Publication Publication Date Title
US10263889B2 (en) Data forwarding method, device, and system in software-defined networking
US10063470B2 (en) Data center network system based on software-defined network and packet forwarding method, address resolution method, routing controller thereof
US8855116B2 (en) Virtual local area network state processing in a layer 2 ethernet switch
US10122623B2 (en) Control device and control method in SDN network
US10469277B2 (en) Multicast group establishment method in fat-tree network, apparatus, and fat-tree network
WO2015074396A1 (en) Automatic configuration method, device and system of software defined network
EP3713161B1 (en) Data transmission method, relevant device and network
CN108028801B (en) SDN-based ARP implementation method and device
CN107864099B (en) Flow control method and system for heterogeneous FC network
US11979283B2 (en) Stacking-port configuration using zero-touch provisioning
US9736066B2 (en) Method, apparatus and system for establishing optical bypass
US11424978B2 (en) Fast forwarding re-convergence of switch fabric multi-destination packets triggered by link failures
US20190238949A1 (en) Multicast service providing method and software defined networking controller
US20150138986A1 (en) Load balancing in a link aggregation
WO2020062268A1 (en) Method and device for load balancing and message reordering in network
US9172653B2 (en) Sending request messages to nodes indicated as unresolved
CN108924066B (en) Message forwarding method and device
EP2712478B1 (en) Internet group management protocol version three for quality of service support
CN106209634B (en) Learning method and device of address mapping relation
US8539113B2 (en) Indicators for streams associated with messages
WO2022012145A1 (en) Load balancing method, apparatus and system
EP3258654B1 (en) Method and system for reducing pim protocol dr change
WO2021082568A1 (en) Service packet forwarding method, device, and computer storage medium
EP3902228A1 (en) Data message transmission method and node
CN118055069A (en) Load control method, device, network equipment and storage medium

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