CN101557342B - Forwarding method of multicast messages and router - Google Patents

Forwarding method of multicast messages and router Download PDF

Info

Publication number
CN101557342B
CN101557342B CN2009100846372A CN200910084637A CN101557342B CN 101557342 B CN101557342 B CN 101557342B CN 2009100846372 A CN2009100846372 A CN 2009100846372A CN 200910084637 A CN200910084637 A CN 200910084637A CN 101557342 B CN101557342 B CN 101557342B
Authority
CN
China
Prior art keywords
interface information
routing table
multicast
software
hardware
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
CN2009100846372A
Other languages
Chinese (zh)
Other versions
CN101557342A (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.)
New 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 CN2009100846372A priority Critical patent/CN101557342B/en
Publication of CN101557342A publication Critical patent/CN101557342A/en
Application granted granted Critical
Publication of CN101557342B publication Critical patent/CN101557342B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a forwarding method of multicast messages and a router, wherein the method is applied in the router comprising a software processing device corresponding to a software wide area network interface and a hardware processing device corresponding to a hardware exchange interface; a connecting channel is arranged between the software processing device and the hardware processingdevice; the method comprises the following steps: any of the software processing device and the hardware processing device receives the multicast messages on a corresponding interface thereof; the mu lticast messages are transmitted to the other one of the software processing device and the hardware processing device by the connecting channel; the other one device receives the multicast messages, determines an outgoing interface forwarding the multicast messages and forwards the received multicast messages according to the self corresponding interface included in the determined outgoing interface. The invention can realize forwarding of multicast messages by utilizing combination of the software wide area network interface and the hardware exchange interface in the same router.

Description

Forwarding method and routing equipment of multicast message
Technical Field
The present invention relates to network communication technologies, and in particular, to a forwarding method and routing device for multicast packets.
Background
In network communication technology, the multicast method is widely used because of its many advantages such as reducing network load. In the multicast mode, a multicast packet can be transmitted to a multicast group (multicast group) by using a specific multicast address. Specifically, when an information sender sends a data packet to a group of users (in a multicast mode, the data packet may be referred to as a multicast packet, and hereinafter, the data packet is collectively referred to as a multicast packet), it does not need to send a multicast packet to each user, and only needs to send the multicast packet to a specific multicast, and all users participating in the multicast can receive the multicast packet. Therefore, for the information sender, the multicast message can reach all receiving users by only sending the multicast message once, and the load of the network and the burden of the information sender are greatly reduced.
Referring to fig. 1, fig. 1 is a schematic diagram illustrating forwarding of a multicast packet in the prior art. In fig. 1, a router stores a multicast routing table, where the multicast routing table is composed of multiple multicast routing table entries, and each multicast routing table entry records information such as ingress interface information for receiving multicast packets and egress interface information for forwarding multicast packets. As shown in fig. 1, if an information sender (source) needs to send a multicast message to a user a (user a) and a user C (user C), the information sender carries a multicast source address of the information sender and a multicast address added by the user a and the user C in the multicast message to be sent, and sends the multicast message to a router B. Therefore, when the multicast message reaches the router B, specifically, the CPU on the router B finds the corresponding multicast routing entry according to the multicast source address and the multicast address carried in the received multicast message; and then copying the multicast message to the outlet interface in the searched multicast routing table item, thus finishing the forwarding of the multicast message through the outlet interface. Generally, an interface on the router is a wide area network interface processed by software, which is referred to as a software wide area network interface for short, so that an incoming interface and an outgoing interface corresponding to the multicast message are both software wide area network interfaces, and the software wide area network interface is processed by software, so that the running speed of the software wide area network interface is relatively slow.
In order to solve the problem that the running speed of a software wide area network interface on a router is slow, the prior art provides the method for realizing the forwarding of the multicast message by using a three-layer switch; the interface on the three-layer switch is a switching interface processed by a switching chip, which is referred to as a hardware switching interface for short. Wherein, the running speed of the hardware exchange interface is faster than that of the software wide area network interface on the router; however, since the hardware switching interface on the three-layer switch is an interface processed by hardware, the hardware switching interface on the three-layer switch cannot provide complex services such as fine quality of service (QoS).
It can be seen that, in the forwarding methods for implementing multicast packets provided in the prior art, one is to utilize a router to forward multicast packets on a software wide area network interface, where an input interface and an output interface are both software wide area network interfaces; however, because the software wan interface is processed by software, the speed of forwarding the multicast packet by the software wan interface is reduced; the other method is to forward the multicast message on the hardware switching interface by using the three-layer switch, wherein the input interface and the output interface of the three-layer switch are both hardware switching interfaces, but the hardware switching interface is processed by hardware, so that the hardware switching interface is limited to be incapable of providing complex services such as fine QoS (quality of service), and the like, and therefore, the current requirements cannot be met by simply using a software wide area network interface on a router or simply using the hardware switching interface on the three-layer switch to forward the multicast message; a good method is to make the same route device contain software wide area network interface and hardware exchange interface, and make the software wide area network interface and hardware exchange interface in the route device combine to forward the multicast message. However, there is no method for forwarding multicast packets by using a combination of a software wan interface and a hardware switch interface on the same device in the prior art.
Disclosure of Invention
The invention discloses a method for forwarding multicast messages and routing equipment, which are used for forwarding multicast messages by combining a software wide area network interface and a hardware switching interface in the same routing equipment.
A method for forwarding multicast message is applied to a routing device comprising a software processing device corresponding to a software wide area network interface and a hardware processing device corresponding to a hardware exchange interface, and a connecting channel is arranged between the software processing device and the hardware processing device; the method comprises the following steps:
step A, any one of a software processing device and a hardware processing device receives a multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel;
and step B, the other device receives the multicast message in the step A, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to an interface corresponding to the other device contained in the determined output interface.
A routing device comprising software processing means and hardware processing means; the software processing device corresponds to a software wide area network interface, and the hardware processing device corresponds to a hardware exchange interface; a connection channel is arranged between the software processing device and the hardware processing device;
any one of the software processing device and the hardware processing device receives a multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel;
and the other device receives the multicast message, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to an interface corresponding to the other device contained in the determined output interface.
To sum up, the multicast packet forwarding method and routing device provided in the embodiments of the present invention are applicable to a routing device including a software processing device corresponding to a software wan interface and a hardware processing device corresponding to a hardware switching interface, and a connection channel is set between the software processing device and the hardware processing device; the method comprises the following steps: any one of the software processing device and the hardware processing device receives the multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel; and the other device determines an outgoing interface for forwarding the multicast message and forwards the received multicast message according to the self corresponding interface contained in the determined outgoing interface. For example, if the software processing device receives a multicast packet on a corresponding software wide area network interface, an outgoing interface for forwarding the multicast packet is determined, and if the outgoing interface includes a hardware switching interface corresponding to the hardware processing device, the software processing device sends the multicast packet to the hardware processing device through the connection channel. Therefore, the forwarding of the multicast message is realized by combining the software wide area network interface and the hardware switching interface on the same routing device.
Further, compared with the prior art, when the multicast message is forwarded, the method and the device do not depend on a software wide area network interface or a hardware exchange interface completely, but combine the software wide area network interface and the hardware exchange interface, so that complex services such as fine QoS (quality of service) and the like can be realized, rich wide area network characteristics can be supported, and the running speed of forwarding the message by the interface can be increased.
Drawings
Fig. 1 is a schematic diagram illustrating forwarding of a multicast packet in the prior art;
FIG. 2 is a basic flow diagram provided by an embodiment of the present invention;
FIG. 3 is a detailed flow chart of a method provided by an embodiment of the present invention;
fig. 4 is a first schematic diagram of multicast packet forwarding according to an embodiment of the present invention;
fig. 5 is a second schematic diagram of multicast packet forwarding according to an embodiment of the present invention;
FIG. 6 is another detailed flow chart of a method provided by an embodiment of the present invention;
fig. 7 is a third schematic diagram of multicast packet forwarding according to an embodiment of the present invention;
fig. 8 is a diagram illustrating an apparatus according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in detail with reference to the accompanying drawings and specific embodiments.
In the embodiment of the present invention, because the forwarding of the multicast packet is implemented by using the combination of the software wan interface and the hardware switching interface in the same routing device, two processing devices, i.e., a software processing device and a hardware processing device, need to be arranged in the routing device provided in the embodiment of the present invention; wherein, the software processing device corresponds to a software wide area network interface; the present invention may specifically be a CPU or other software device, and the embodiments of the present invention are not specifically limited; the hardware processing device corresponds to the hardware switching interface, and may be specifically a three-layer switching chip or other hardware devices, which is not specifically limited in the embodiment of the present invention. In addition, in order to ensure message transmission between the software processing device and the hardware processing device, a connection channel needs to be arranged between the software processing device and the hardware processing device. Thus, the flow for forwarding the multicast packet by using the software wan interface and the hardware switching interface in the same routing device provided in the embodiment of the present invention may specifically refer to fig. 2.
Referring to fig. 2, fig. 2 is a basic flow chart provided by the embodiment of the invention. As shown in fig. 2, the process may include the following steps:
in step 201, any one of the software processing device and the hardware processing device receives the multicast packet on its corresponding interface.
Here, step 201 may specifically be: the software processing device receives the multicast message on a corresponding software wide area network interface; or the hardware processing device receives the multicast message on the corresponding hardware exchange interface.
For convenience of description, the embodiment takes the example that the software processing apparatus receives the multicast packet on the corresponding software wan interface.
Step 202, sending the received multicast message to the other device of the software processing device and the hardware processing device through the connection channel.
Here, the connection channel is a connection channel provided between the software processing apparatus and the hardware processing apparatus. If step 201 is: if the software processing apparatus receives the multicast packet on the corresponding software wan interface, step 202 is: the software processing device sends the received multicast message to the hardware processing device through the connecting channel; it should be noted that, before the software processing apparatus sends the received multicast packet to the hardware processing apparatus through the connection channel, the method may further include: the software processing device determines whether an outgoing interface for forwarding the multicast packet includes a hardware switching interface (for how to determine, see fig. 3, it is not described here again), for example, if the outgoing interface for forwarding the multicast packet is a software wan interface and a hardware switching interface, it is determined that the interface includes the hardware switching interface; thus, the software processing device copies the multicast message to each software wide area network interface so as to forward the multicast message through each software wide area network interface; continuously executing the multicast message sent and received by the connection channel to the hardware processing device so as to enable the hardware processing device to forward the multicast message through a hardware exchange interface which corresponds to the hardware processing device and is in the multicast message forwarding outlet interface; otherwise, when the software processing device determines that the output interface for forwarding the multicast packet only includes each software wan interface, the software processing device only copies the multicast packet to each software wan interface, so as to forward the multicast packet through each software wan interface without executing step 202, which is similar to the prior art, and the embodiment of the present invention is not described in detail.
Of course, if step 201 is: if the hardware processing apparatus receives the multicast packet on the corresponding hardware switching interface, step 202 is: the hardware processing device sends the received multicast message to the software processing device through the connection channel, and the processing process is the same as above, which is not described herein again.
Step 203, the another device receives the multicast packet sent in step 202, determines an outgoing interface for forwarding the multicast packet, and forwards the received multicast packet according to the corresponding interface included in the determined outgoing interface.
Here, if step 202 is that the software processing apparatus sends the received multicast packet to the hardware processing apparatus through the connection channel; then step 203 may be: the hardware processing device receives the multicast message, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to a hardware switching interface corresponding to the hardware processing device and contained in the determined output interface; of course, if step 202 is the hardware processing apparatus sending the received multicast packet to the software processing apparatus through the connection channel; then step 203 may be: the software processing device receives the multicast message, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to a software wide area network interface corresponding to the software wide area network interface included in the determined output interface.
Therefore, the forwarding operation of the multicast message is realized by combining the software wide area network interface and the hardware switching interface on the same device.
The method provided by the embodiment of the invention is briefly described above, and the method provided by the embodiment of the invention is described in detail below.
Referring to fig. 3, fig. 3 is a detailed flowchart of a method provided by an embodiment of the present invention. In this embodiment, a software processing device is used as a CPU, which corresponds to a software wan interface and is configured to process a multicast packet on the software wan interface; the hardware processing device is a three-layer switching chip, which corresponds to the hardware switching interface and is used for processing the multicast message on the hardware switching interface as an example; in addition, in order to ensure the transmission of multicast messages between the CPU and the three-layer switching chip, a connecting channel can be arranged between the CPU and the three-layer switching chip; if the software wan interface and the hardware switch interface are disposed on the same board in the routing device, as shown in fig. 3, the process may include the following steps:
and step 301, respectively refreshing the corresponding multicast routing tables to the CPU and the three-layer switching chip.
Here, step 301 is mainly for the CPU and the three-layer switch chip to subsequently process the multicast packet received on its corresponding interface, where, for convenience of description, the multicast routing table that is flushed to the CPU may be referred to as a software multicast routing table for short; the multicast routing table which is brushed to the three-layer switching chip is referred to as a hardware multicast routing table for short. Therefore, after receiving the multicast routing table which is refreshed to the CPU and the three-layer switching chip, the CPU and the three-layer switching chip store the multicast routing table.
Specifically, the operation of step 301 mainly includes:
step 3011, establish a multicast routing table.
Here, step 3011 is specifically to establish a multicast routing table on the control plane according to a multicast routing protocol, and specifically, the operation of establishing the multicast routing table may be similar to that in the prior art, and is not described here again.
Preferably, the multicast routing table established in step 3011 is composed of multiple (S, G) multicast routing table entries, where (S, G) indicates routing information from the multicast source address S to the multicast address G; each multicast routing table entry includes incoming interface information (incoming interface) and outgoing interface information (out-going interface), etc.
Step 3012, according to the multicast routing table established in step 3011, determining a software multicast routing table that needs to be flushed to the CPU and a hardware multicast routing table that needs to be flushed to the three-layer switch chip, respectively.
It should be noted that, in step 3012, the software multicast routing table that needs to be flushed to the CPU is determined to be the complete multicast routing table established in step 3011; in this way, step 3012 is to specifically flush the multicast routing table (software multicast routing table) established in step 3011 to the data plane, so that the CPU stores the received software multicast routing table on the data plane.
The interface information included in the hardware multicast routing table that needs to be flushed to the three-layer switch chip is irrelevant to the software wide area network interface information corresponding to the CPU, and needs to be determined according to the multicast routing table established in step 3011, and specifically may be determined according to the interface information in each multicast routing table entry in the multicast routing table established in step 3011, and includes the following steps:
step a, for each multicast routing table entry (for convenience of description, the multicast routing table entry is referred to as a current multicast routing table entry) in the multicast routing table (simply referred to as a current multicast routing table entry) established in step 3011, determining whether the interface information of the current multicast routing table entry is software wide area network interface information, if so, executing step B; otherwise, when the input interface information is hardware exchange interface information, executing step D.
Here, suppose the form of the current multicast routing entry is:
incoming interface:eth0/1
out-going interface:
|----Pos 1/0
|----vlan 3
-----vlan 4。
wherein eth0/1 and Pos 1/0 are software wide area network interface information; and the vlan 3 and the vlan 4 exchange interface information for hardware, and thus, the interface information in the current multicast routing table entry is determined to be software wide area network interface information, and the step B is executed.
Step B, judging whether the output interface information of the current multicast routing table item contains hardware exchange interface information, if so, executing step C; otherwise, deleting the current multicast routing table item in the current multicast routing table.
Here, since the three-layer switch chip corresponds to the hardware switch interface and is configured to process the multicast packet on the hardware switch interface, the interface information in the stored multicast routing table entry is related to the hardware switch interface information, and therefore, if the ingress interface information and the egress interface information in the current multicast routing table entry are both software wan interface information, the current multicast routing table entry may be deleted in the current multicast routing table.
Here, the specific step of determining that the egress interface information of the current multicast routing table entry includes hardware switching interface information may be: the output interface information of the current multicast routing table item only contains hardware exchange interface information; or the output interface information of the current multicast routing table item comprises software wide area network interface information and hardware exchange interface information. For example, if the current multicast routing entry is as described above, that is, the ingress interface information is eth0/1 information, and the egress interface information is Pos 1/0, vlan 3, and vlan 4, it is determined that the egress interface information of the current multicast routing entry includes hardware switching interface information, and step C is performed.
And step C, updating the interface information in the current multicast routing list item in the current multicast routing list to interface information corresponding to a connecting channel arranged between the CPU and the three layers of switching chips. Thus, the updated multicast routing table entry is determined as the multicast routing table entry included in the hardware multicast routing table that needs to be flushed to the three-layer switch chip.
Here, if the outgoing interface information of the current multicast routing table entry only contains hardware switching interface information, keeping the outgoing interface information in the current multicast routing table entry unchanged; if the outgoing interface information in the current multicast routing table entry further includes software wan interface information, that is, the outgoing interface information in the current multicast routing table entry includes software wan interface information and hardware switching interface information, step C further includes: and deleting the software wide area network interface information contained in the outgoing interface information of the current multicast routing table item in the current multicast routing table. For example, if the ingress interface information is eth0/1 and the egress interface information is Pos 1/0, vlan 3, and vlan 4, the updated expression of the multicast routing entry in this step is:
incomming interface: interface information corresponding to a connecting channel arranged between the CPU and the three layers of exchange chips;
out-going interface:
|----vlan 3
-----vlan 4。
therefore, the updating operation of the current multicast routing table entry is realized.
D, judging whether the output interface information in the current multicast routing list item contains the software wide area network interface information, if so, executing the step E; otherwise, the current multicast routing table item is reserved in the current multicast routing table.
Here, step D determines that the outgoing interface information in the current multicast routing table entry includes software wan interface information, and indicates that the outgoing interface information in the current multicast routing table entry is software wan interface information and hardware switching interface information; or software wide area network interface information. Here, suppose the form of the current multicast routing entry is:
incoming interface:vlan 3
out-going interface:
|----Pos 1/0
|----vlan 4
-----vlan 5。
wherein Pos 1/0 is software wide area network interface information; and if the vlan 3, the vlan 4 and the vlan 5 are hardware exchange interface information, determining that the incoming interface information in the current multicast routing table entry is hardware exchange interface information, and determining that the outgoing interface information comprises software wide area network interface information and hardware exchange interface information. Thus, step E is performed.
If the output interface information in the current multicast routing table entry does not contain the software wide area network interface information, the output interface information in the current multicast routing table entry is indicated to be hardware exchange interface information. If the form of the current multicast routing table entry is:
incoming interface:vlan 3
out-going interface:
|----vlan 4
-----vlan 5。
and if the vlan 3, the vlan 4 and the vlan 5 are hardware exchange interface information, determining that the ingress interface information and the egress interface information in the current multicast routing table entry are both hardware exchange interface information, and retaining the current multicast routing table entry in the current multicast routing table.
And step E, deleting the interface information of the software wide area network contained in the output interface information of the current multicast routing list item, and adding the interface information corresponding to a preset connecting channel between the CPU and the three layers of switching chips into the output interface information in the multicast routing list item.
For example, if the ingress interface information is vlan 3 and the egress interface information is Pos 1/0, vlan 4, and vlan 5, the expression form of the updated multicast routing entry in this step is:
incoming interface:vlan 3;
out-going interface:
|----vlan 4
-----vlan 5
interface information corresponding to a connection channel provided between the CPU and the three-layer switching chip.
Therefore, the updating operation of the current multicast routing table entry is realized. And determining the updated multicast routing table entry as the multicast routing table entry contained in the hardware multicast routing table needing to be flushed to the three layers of switching chips.
And step F, determining the multicast routing table obtained after the current multicast routing table is subjected to the operation processing shown in the steps A to E as a hardware multicast routing table needing to be refreshed to the three layers of switching chips. Thus, the determination operation for the hardware multicast routing table stored in the three-layer switch chip is realized through steps a to F.
And 3013, flushing the determined software multicast routing table to the CPU, and synchronously flushing the determined hardware multicast routing table to the three-layer switch chip.
Therefore, the operation of respectively refreshing the corresponding multicast routing tables to the CPU and the three-layer switching chip is realized through the steps.
Step 302, when a multicast message reaches the software wide area network interface, the CPU determines the multicast routing entry corresponding to the currently received multicast message.
Here, the currently received multicast packet carries multicast source address information and multicast address information, so the CPU can determine a corresponding multicast routing entry in a multicast routing table stored in the CPU according to the multicast source address information and the multicast address information carried in the currently received multicast packet.
Step 303, polling each piece of outbound interface information in the multicast routing table entry determined in step 302, and if the currently polled outbound interface information is software wide area network interface information, executing step 304; if the currently polled outbound interface information is hardware switch interface information, step 305 is executed.
Generally, the information of the ingress interface that actually receives the multicast packet is the same as the information of the ingress interface in the multicast routing table entry corresponding to the multicast packet. In order to further determine whether the information of the ingress interface that actually receives the multicast packet is consistent with the information of the ingress interface in the multicast routing table entry corresponding to the multicast packet, before step 303, it may be further determined whether the ingress interface information in the multicast routing table entry determined in step 302 is information of a software wan interface, and if the determination result is yes, the above step 303 is executed; otherwise, the flow can be ended; or may trigger the CPU to reestablish the routing table entry on the control plane, which is not limited in the embodiment of the present invention.
Here, the outgoing interface information in the multicast routing table entry determined in the polling step 302 may specifically be the outgoing interface information in the multicast routing table entry determined in the polling step 302 sequentially according to a preset order, such as an up-down order.
And step 304, copying the currently received multicast message to the software wide area network interface corresponding to the software wide area network interface information. And ending the process of forwarding the multicast message by the current software wide area network interface.
Step 305, judging whether the currently polled outgoing interface information is the first outgoing interface information containing the hardware switching interface information in the multicast routing table entry determined in step 302, if so, executing step 306; otherwise, the hardware exchange interface information is ignored.
Step 306, sending the currently received multicast message to the three-layer switch chip through the connection channel arranged between the CPU and the three-layer switch chip. Thereafter, step 307 is performed.
Here, in the above step 306, the currently received multicast packet is sent to the three-layer switch chip through the connection channel set between the CPU and the three-layer switch chip, so that the three-layer switch chip forwards the multicast packet through the corresponding hardware switch interface (in which, specifically, how to forward the multicast packet may refer to steps 307 to 308). If the currently polled outgoing interface information is not the first outgoing interface information containing the hardware switching interface information in the multicast routing table entry determined in the step 302, because the CPU polls the outgoing interface information containing the hardware switching interface information for the first time in the multicast routing table entry determined in the step 302, the currently received multicast message is sent to the three-layer switching chip through a connection channel arranged between the CPU and the three-layer switching chip; in order to avoid the repeated forwarding operation of the three-layer switching chip, the hardware switching interface information can be ignored, and the forwarding process is ended.
Step 307, the three-layer switching chip determines the multicast routing table entry corresponding to the currently received multicast packet.
Here, because the currently received multicast packet carries the multicast source address information and the multicast address information, the three-layer switch chip may determine the corresponding multicast routing entry in the multicast routing table stored in itself according to the multicast source address information and the multicast address information carried by the currently received multicast packet.
In step 308, the three-layer switch chip obtains all the egress interface information from the multicast routing table entry determined in step 307.
Here, the third layer switching chip may specifically acquire all the egress interface information from the multicast routing table entry determined in step 307 as hardware switching interface information.
Step 309, copying the currently received multicast message to the interface corresponding to the output interface information obtained in step 308. And ending the process of forwarding the multicast message by the current hardware switching interface.
Therefore, the forwarding operation of the multicast message can be realized through the combination of the software wide area network interface and the hardware exchange interface in the same routing device.
Specifically, to make the description in fig. 3 clearer, reference may be made to the first schematic diagram of multicast packet forwarding shown in fig. 4. Wherein, the software wan interface and the hardware exchange interface are disposed on the same board, as shown in fig. 4, the specific process is as follows: firstly, if a multicast message is received on a software wide area network interface, a CPU determines a multicast routing table item corresponding to the multicast message in a multicast routing table stored by the CPU; secondly, the CPU determines a multicast routing table item corresponding to the multicast message, polls the output interface information contained in the determined multicast routing table item, if the currently polled output interface information contains hardware exchange interface information and software WAN interface information, copies the multicast message, and sends the copied multicast message to the software WAN interface corresponding to the software WAN interface information; judging whether the current polled output interface information is the first output interface information containing hardware exchange interface information in the determined multicast routing list item, if so, executing the step three; otherwise, neglecting the hardware exchange interface information; and thirdly, the CPU sends the currently received multicast message to the three-layer switching chip through a connecting channel arranged between the CPU and the three-layer switching chip, and the three-layer switching chip automatically determines the multicast routing table item corresponding to the currently received multicast message and forwards the currently received multicast message through a hardware switching interface corresponding to the hardware switching interface information in the multicast routing table item.
It should be noted that fig. 3 and fig. 4 are described by taking an example in which all the software wan interfaces and the hardware switch interfaces are disposed on the same board in the routing device. This embodiment may also be applied to a case where all the software wan interfaces and the hardware switching interfaces are not set on the same board in the routing device, referring to fig. 5, where fig. 5 is a second schematic diagram of multicast packet forwarding provided in this embodiment of the present invention, and as shown in fig. 5, a specific flow may include: firstly, when the software wide area network interface corresponding to the board 1 receives the multicast message, the CPU1 on the board 1 determines the multicast routing table entry corresponding to the multicast message; if the determined output interface information contained in the multicast routing table entry is hardware exchange interface information on the board 2, sending the multicast message to a CPU2 on the board 2 through a preset inter-board channel between the board 1 and the board 2; thirdly, the CPU2 determines a multicast routing table entry corresponding to the multicast packet, polls the egress interface information included in the determined multicast routing table entry, if the currently polled egress interface information includes hardware switching interface information, determines whether the currently polled egress interface information is the first egress interface information including the hardware switching interface information in the determined multicast routing table entry, if so, sends the multicast packet to the three-layer switching chip through a connection channel arranged between the CPU2 and the three-layer switching chip, and the three-layer switching chip automatically completes determining the multicast routing table entry corresponding to the currently received multicast packet and forwards the multicast packet through the hardware switching interface corresponding to the hardware switching interface information in the multicast routing table entry.
It should be further noted that fig. 3 is an example in which the routing device first receives the multicast packet on the software wan interface, and the routing device in this embodiment may also be applied to first receive the multicast packet on the hardware switching interface, which may specifically refer to the flow shown in fig. 6.
Referring to fig. 6, fig. 6 is another detailed flowchart of the method according to the embodiment of the present invention. In this embodiment, a software processing device is used as a CPU, which corresponds to a software wan interface and is configured to process a multicast packet on the software wan interface; the hardware processing device is a three-layer switching chip, corresponds to the hardware switching interface and is used for processing the multicast message on the hardware switching interface; in addition, in order to ensure that the multicast message is transmitted between the CPU and the three-layer switching chip, a connecting channel can be arranged between the CPU and the three-layer switching chip; then, as shown in fig. 6, the process may include the following steps:
step 601 is similar to step 301 shown in fig. 3.
Step 602, when a multicast message reaches the hardware switching interface, the three-layer switching chip determines the multicast routing entry corresponding to the currently received multicast message.
Here, the currently received multicast packet carries multicast source address information and multicast address information, so the three-layer switch chip can determine a corresponding multicast routing table entry in a multicast routing table stored in the three-layer switch chip according to the multicast source address information and the multicast address information carried by the currently received multicast packet.
Step 603, all the outgoing interface information is obtained from the multicast routing table entry determined in step 602.
For convenience of description, the present embodiment takes the obtained output interface information as interface information corresponding to a connection channel arranged between the CPU and the three-layer switch chip and more than one piece of hardware switch interface information as an example.
Step 604, copying the currently received multicast packet to the interface corresponding to the outgoing interface information obtained in step 603.
If the interface information obtained in step 603 is interface information corresponding to a connection channel preset between the CPU and the three-layer switch chip and information of more than one hardware switch interface, step 604 may specifically be: copying the currently received multicast message to an interface corresponding to a preset connection channel between the CPU and the three-layer switching chip, and hardware switching interfaces corresponding to the information of each hardware switching interface.
Here, since the multicast packet is copied to the interface corresponding to the connection channel preset between the CPU and the three-layer switch chip, the CPU can receive the multicast packet sent from the three-layer switch chip.
Step 605, the CPU determines the multicast routing entry corresponding to the currently received multicast packet.
Here, the currently received multicast packet carries multicast source address information and multicast address information, so the CPU can determine a corresponding multicast routing entry in a multicast routing table stored in the CPU according to the multicast source address information and the multicast address information carried in the currently received multicast packet.
Step 606, judging whether the interface information in the multicast routing table entry determined in step 605 is the information of the hardware switching interface, if so, executing step 607; otherwise, the flow ends.
Generally, the information of the ingress interface of the multicast packet actually received by the routing device is the same as the information of the ingress interface in the multicast routing table entry corresponding to the multicast packet, and if the information of the ingress interface is different, this embodiment may end the flow, and may also trigger the CPU to reestablish the routing table entry on the control plane, where the specific situation needs to be specifically analyzed, and the embodiment of the present invention is not limited.
In step 607, all the egress interface information is obtained from the multicast routing table entry determined in step 605.
Here, for convenience of description, the present embodiment takes the output interface information as the one or more pieces of software wan interface information and the one or more pieces of hardware exchange interface information as an example.
Step 608, the currently received multicast packet is copied to the software wan interface corresponding to the software wan interface information included in the outbound interface information obtained in step 607. And ending the process of forwarding the multicast message by the current software wide area network interface.
Here, since the ingress interface information of the multicast packet is the hardware switching interface information, and thus the three-layer switching chip has forwarded the received multicast packet on the hardware switching interface corresponding to the multicast packet, in this step 608, the operation that the CPU sends the received multicast packet to the three-layer switching chip through the connection channel provided between the CPU and the three-layer switching chip may be omitted.
Therefore, the forwarding operation of the multicast message can be realized by combining the software wide area network interface and the hardware exchange interface in the same routing device.
Specifically, to make the flow shown in fig. 6 clearer, reference may be made to a third schematic diagram of multicast packet forwarding shown in fig. 7. As shown in fig. 7, the specific process is as follows: firstly, receiving a multicast message on a hardware exchange interface, automatically determining a multicast routing table item corresponding to the currently received multicast message by a three-layer exchange chip, and if output interface information contained in the multicast routing table item is specifically hardware exchange interface information and interface information corresponding to a connection channel arranged between a CPU and the three-layer exchange chip, forwarding the multicast message through interfaces corresponding to the hardware exchange interface information and the interface information corresponding to the connection channel arranged between the CPU and the three-layer exchange chip respectively; secondly, after receiving the multicast message sent by the three-layer switching chip, the CPU determines a multicast routing table item corresponding to the multicast message; if the determined incoming interface information contained in the multicast routing table entry is hardware exchange interface information, the CPU is only responsible for copying the currently received multicast message to the software wide area network interface corresponding to the software wide area network interface information contained in the outgoing interface information in the multicast routing table entry.
It should be noted that, the foregoing implements forwarding of the multicast packet by combining the software wan interface and the hardware switch interface, and this embodiment may also be applied to implement forwarding of the multicast packet only on the software wan interface or the hardware switch interface, and specifically may perform corresponding processing according to the multicast source address information and the multicast address information in the multicast packet, which is not described herein again.
The above is a description of the method provided by the embodiment of the present invention, and the following is a description of the apparatus provided by the embodiment of the present invention.
Referring to fig. 8, fig. 8 is a structural diagram of an apparatus according to an embodiment of the present invention. As shown in fig. 8, the routing device may include: a software processing means 801 and a hardware processing means 802.
Wherein, the software processing device 801 corresponds to a software wan interface; the hardware processing device 802 corresponds to a hardware exchange interface; a connection channel is provided between the software processing apparatus 801 and the hardware processing apparatus 802.
Either one of the software processing apparatus 801 and the hardware processing apparatus 802 receives the multicast packet on its corresponding interface, and sends the multicast packet to the other one of the software processing apparatus and the hardware processing apparatus through the connection channel. And the other device receives the multicast message, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to an interface corresponding to the other device contained in the determined output interface.
Preferably, as shown in fig. 8, the routing device further includes: the routing table flushing unit 803.
Here, the routing table flushing unit 803 may be provided on the software processing apparatus 801 or may be independent of the software processing apparatus 801, and the embodiment of the present invention is not particularly limited. Fig. 8 exemplifies that the routing table flushing unit 803 is independent from the software processing apparatus 801.
The routing table flushing unit 803 is configured to establish a multicast routing table, and determine, according to the multicast routing table, a software multicast routing table that needs to be flushed to a software processing device and a hardware multicast routing table that needs to be flushed to a hardware processing device, respectively; the determined software multicast routing table is flushed to the software processing means 801 and the determined hardware multicast routing table is flushed to the hardware processing means 802.
As shown in fig. 8, the routing table flushing unit 803 may include: a routing table establishment subunit 8031, a software routing table determination subunit 8032, a hardware routing table determination subunit 8033, and a under-routing-table brush unit 8034.
The routing table establishing subunit 8031 is configured to establish a multicast routing table.
The software routing table determining subunit 8032 is configured to determine the multicast routing table established by the routing table establishing subunit 8031 as a software multicast routing table that needs to be flushed to the software processing apparatus 801.
The hardware routing table determining subunit 8033 may include: a first determination module 80331, a second determination module 80332, a third determination module 80333, an update module 80334, and a determination module 80335.
The first determining module 80331 is configured to determine, for each multicast routing table entry in the multicast routing table established by the routing table establishing subunit 8031, whether the access interface information of the multicast routing table entry is software wan interface information;
the second judging module 80332 is configured to, when receiving that the judgment result of the first judging module 80331 is yes, judge whether the egress interface information in the multicast routing table entry includes hardware switching interface information;
the third judging module 80333 is configured to, when receiving that the judgment result of the first judging module 80331 is that the incoming interface information is hardware switching interface information, judge whether the outgoing interface information in the multicast routing table entry includes software wan interface information;
the updating module 80334 is configured to update the interface information in the multicast routing table entry to the interface information corresponding to the connection channel when the determination result received by the second determining module 80332 is yes; when the judgment result of the second judgment module 80332 is received as no, deleting the multicast routing table entry; and when the judgment result received by the third judging module 80333 is yes, deleting the software wan interface information included in the outgoing interface information of the multicast routing table entry, and adding the interface information corresponding to the connection channel to the outgoing interface information of the multicast routing table entry.
The determining module 80335 is configured to determine the routing table obtained after the multicast routing table established by the routing table establishing subunit 8031 is processed by the updating module 80334 as the hardware multicast routing table that needs to be flushed to the hardware processing apparatus 802;
in this way, the under-routing-table brush unit 8034 is configured to send the software multicast routing table determined by the software routing table determining subunit 8032 and the hardware multicast routing table determined by the determining module 80335 to the software processing apparatus 801 and the hardware processing apparatus 802, respectively.
Preferably, as shown in fig. 8, the software processing apparatus 801 may include: a first storage unit 8011, a first retrieving unit 8012 and a first forwarding unit 8013.
The first storage unit 8011 is configured to store a software multicast routing table flushed by the lower brush unit 8034 of the routing table; the software multicast routing table comprises a plurality of multicast routing table entries, and the interface information in each multicast routing table entry is software wide area network interface information; the output interface information is software wide area network interface information and/or hardware exchange interface information.
The first polling unit 8012 is configured to determine, in a software multicast routing table stored in the first storage unit 8011, a multicast routing table entry corresponding to a currently received multicast packet, and poll egress interface information included in the multicast routing table entry.
The first forwarding unit 8013 is configured to forward the current multicast packet according to the outgoing interface information polled by the first polling unit 8012.
As shown in fig. 8, the hardware processing apparatus 802 includes: a second storage unit 8021, a second acquisition unit 8022, and a second forwarding unit 8023.
The second storage unit 8021 is configured to store a hardware multicast routing table that is flushed by the lower brush unit 8034 of the routing table, where the hardware multicast routing table includes multiple multicast routing table entries, and entry interface information in each multicast routing table entry is interface information corresponding to the connection channel or hardware exchange interface information; the output interface information is hardware exchange interface information and/or interface information corresponding to the connection channel.
The second obtaining unit 8022 is configured to determine a multicast routing table entry of the received multicast packet in a hardware multicast routing table stored in the second storage unit 8021; and obtaining the output interface information contained in the multicast routing table entry.
The second forwarding unit 8023 is configured to forward the multicast packet according to the output interface corresponding to the output interface information acquired by the second acquiring unit 8022.
As shown in fig. 8, in this embodiment, if any one device is a software processing device 801 and another device is a hardware processing device 802, then the software processing device 801 receives a multicast packet at a software lan interface, and sends the multicast packet to the hardware processing device 802 through a connection channel. As shown in fig. 8, the software processing apparatus 801 further includes: the first software determination unit 8014.
The first software determining unit 8014 is configured to determine whether the outbound interface information currently polled by the first polling unit 8012 is hardware switching interface information, if so, determine whether the outbound interface information currently polled is the first outbound interface information including the hardware switching interface information in the multicast routing table entry determined by the first polling unit 8012, and if so, send a first forwarding notification to the first forwarding unit 8013; otherwise, the hardware exchange interface information contained in the currently polled outgoing interface information is ignored.
After receiving the first forwarding notification sent by the first software determining unit 8014, the first forwarding unit 8013 sends a multicast packet to the hardware processing apparatus through the connection channel; when the received judgment result of the first software judgment unit 8014 is that the interface information output by the first polling unit 8012 is currently polled is software wan interface information, the multicast packet is copied to each software wan interface corresponding to each software wan interface information, and the multicast packet is forwarded through each software wan interface.
As shown in fig. 8, in this embodiment, if any one device is a hardware processing device, the other device is a software processing device; in this way, the outgoing interface information acquired by the second acquiring unit 8022 includes interface information corresponding to the connection channel; in this way, the second forwarding unit 8023 sends the multicast packet to the software processing apparatus through the connection channel.
Preferably, as shown in fig. 8, the software processing apparatus 801 further includes: a second software determination unit 8015.
The first polling unit 8012 is further configured to obtain ingress interface information from the determined multicast routing table entry; acquiring the output interface information in the determined multicast routing table item;
the second software determining unit 8015 determines whether the interface information acquired by the first polling unit 8012 is hardware exchange interface information; if so, when the interface information acquired by the first polling unit 8012 includes the software wan interface information and the hardware exchange interface information, or includes the software wan interface information, the second forwarding notification is sent to the first forwarding unit 8013.
The first forwarding unit 8013 receives the second forwarding notification, determines an interface corresponding to the software wide area network interface information in the outgoing interface information acquired by the first polling unit 8012 as an outgoing interface for forwarding the multicast packet, and forwards the multicast packet through the determined outgoing interface.
Preferably, the routing device provided in this embodiment may be disposed in a three-layer switch or a router, and this embodiment is not particularly limited.
Preferably, in the present embodiment, the software processing device may be a CPU; the hardware processing device is a three-layer exchange chip.
To sum up, the multicast packet forwarding method and routing device provided in the embodiments of the present invention are applicable to a routing device including a software processing device corresponding to a software wan interface and a hardware processing device corresponding to a hardware switching interface, and a connection channel is set between the software processing device and the hardware processing device; the method comprises the following steps: any one of the software processing device and the hardware processing device receives the multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel; and the other device determines an outgoing interface for forwarding the multicast message and forwards the received multicast message according to the self corresponding interface contained in the determined outgoing interface. Therefore, the multicast message is forwarded by combining the software wide area network interface and the hardware switching interface on the same routing device.
For example, if the software processing device receives a multicast packet on a corresponding software wide area network interface, an outgoing interface for forwarding the multicast packet is determined, and if the outgoing interface includes a hardware switching interface corresponding to the hardware processing device, the software processing device sends the multicast packet to the hardware processing device through the connection channel. Therefore, the forwarding of the multicast message is realized by combining the software wide area network interface and the hardware switching interface on the same routing device.
Further, compared with the prior art, when the multicast message is received and forwarded, the method and the device do not completely depend on the software wide area network interface or the hardware exchange interface, but combine the software wide area network interface and the hardware exchange interface, so that complex services such as fine QoS and the like and rich wide area network characteristics can be met, and the running speed of forwarding the message by the interface can be increased.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (18)

1. A method for forwarding multicast messages is characterized in that the method is applied to a routing device comprising a software processing device corresponding to a software wide area network interface and a hardware processing device corresponding to a hardware switching interface, and a connecting channel is arranged between the software processing device and the hardware processing device; the method comprises the following steps:
step A, any one of a software processing device and a hardware processing device receives a multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel;
and step B, the other device receives the multicast message in the step A, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to an interface corresponding to the other device contained in the determined output interface.
2. The forwarding method of claim 1, wherein the method further comprises:
a0, refreshing the corresponding multicast routing table to the software processing device and the hardware processing device for storage;
the step B of determining an outgoing interface for forwarding the multicast packet includes: step B1, determining the multicast routing list item corresponding to the received multicast message in the multicast routing list stored in the step B; step B2, obtaining the interface information from the determined multicast routing list item; step B3, determining the interface corresponding to the obtained outgoing interface information as the outgoing interface for forwarding the multicast message.
3. The forwarding method according to claim 2, wherein the step a0 comprises:
a, establishing a multicast routing table;
b, respectively determining a software multicast routing table which needs to be refreshed to a software processing device and a hardware multicast routing table which needs to be refreshed to a hardware processing device according to the multicast routing table in the step a;
and c, flushing the determined software multicast routing table to a software processing device, and flushing the determined hardware multicast routing table to a hardware processing device.
4. The forwarding method according to claim 3, wherein the software multicast routing table determined in step b and needing to be flushed to the software processing device is the multicast routing table established in step a;
in step b, the operation of determining the hardware multicast routing table that needs to be flushed to the hardware processing device includes:
b1, aiming at each multicast routing list item in the multicast routing list established in the step a, judging whether the interface information of the multicast routing list item is the interface information of the software wide area network, if so, executing the step b 2; otherwise, when the incoming interface information is hardware exchange interface information, executing step b 3;
step b2, judging whether the output interface information in the multicast routing list item contains hardware exchange interface information, if yes, updating the input interface information in the multicast routing list item to the interface information corresponding to the connection channel; otherwise, deleting the multicast routing table entry;
b3, judging whether the output interface information in the multicast routing list item contains software WAN interface information, if yes, deleting the software WAN interface information contained in the output interface information of the multicast routing list item, and adding the interface information corresponding to the connection channel to the output interface information of the multicast routing list item;
step b4, determining the routing table obtained after the multicast routing table established in step a is processed through steps b1 to b3 as the hardware multicast routing table needing to be flushed to the hardware processing device.
5. The forwarding method according to claim 4, wherein if the determination result in step b2 is yes, step b2 further comprises: judging whether the output interface information of the multicast routing table item also contains software wide area network interface information; if yes, deleting the software wide area network interface information contained in the outgoing interface information.
6. The forwarding method according to any one of claims 2 to 5, wherein if any one of the devices in step A is a software processing device, the interface for receiving the multicast packet is a software WAN interface; the other device is a hardware processing device;
the step a of sending the multicast packet to the other of the software processing device and the hardware processing device through the connection channel includes: the software processing device determines a multicast routing table item corresponding to the currently received multicast message in a multicast routing table stored in the software processing device; polling the output interface information in the determined multicast routing list item; and judging whether the current polled output interface information is hardware exchange interface information, if so, sending the multicast message to a hardware processing device through a connecting channel.
7. The forwarding method according to claim 6, wherein when it is determined that the currently polled egress interface information is hardware switch interface information, it is determined whether the currently polled egress interface information is the first egress interface information containing the hardware switch interface information in the determined multicast routing table entry, and if so, an operation of sending the multicast packet to a hardware processing apparatus through a connection channel is performed; otherwise, the hardware exchange interface information contained in the currently polled outgoing interface information is ignored.
8. The forwarding method of claim 7, wherein when it is determined that the currently polled outbound interface information is software wide area network interface information, the method further comprises: and copying the currently received multicast message to a software wide area network interface corresponding to the software wide area network interface information in the currently polled output interface information.
9. The forwarding method according to claims 2 to 5, wherein if any device in step A is a hardware processing device, the interface receiving the multicast packet is a hardware switching interface; the other device in the step B is a software processing device;
the step a of sending the multicast packet to another device through the connection channel includes: the hardware processing device determines a multicast routing table item corresponding to the received multicast message in a multicast routing table stored in the hardware processing device; obtaining the interface information from the determined multicast routing list item; the obtained interface information comprises interface information corresponding to the connection channel; and sending the multicast message to the software processing device through an interface corresponding to the connecting channel.
10. The method of claim 9, wherein said step B2 further comprises: acquiring the input interface information from the multicast routing table entry determined in the step B1; the step B3 includes: and B, judging whether the acquired interface information is hardware exchange interface information, if so, if the interface information acquired in the step B2 contains software wide area network interface information and hardware exchange interface information or only contains the software wide area network interface information, determining a software wide area network interface corresponding to the acquired software wide area network interface information as an output interface for forwarding the multicast message.
11. A routing device, characterized in that it comprises software processing means and hardware processing means; the software processing device corresponds to a software wide area network interface, and the hardware processing device corresponds to a hardware exchange interface; a connection channel is arranged between the software processing device and the hardware processing device;
any one of the software processing device and the hardware processing device receives a multicast message on a corresponding interface thereof, and sends the multicast message to the other device of the software processing device and the hardware processing device through the connecting channel;
and the other device receives the multicast message, determines an output interface for forwarding the multicast message, and forwards the received multicast message according to an interface corresponding to the other device contained in the determined output interface.
12. The routing device of claim 11, wherein the routing device further comprises: a routing table lower brushing unit; wherein,
the routing table lower brushing unit is used for establishing a multicast routing table, and respectively determining a software multicast routing table which needs to be brushed to a software processing device and a hardware multicast routing table which needs to be brushed to a hardware processing device according to the multicast routing table; and flushing the determined software multicast routing table to a software processing device, and flushing the determined hardware multicast routing table to a hardware processing device.
13. The routing device of claim 12, wherein the routing table flushing unit comprises: the device comprises a routing table establishing unit, a software routing table determining subunit, a hardware routing table determining subunit and a routing table lower brush unit; wherein,
the routing table establishing subunit is used for establishing a multicast routing table;
the software routing table determining subunit is used for determining the multicast routing table established by the routing table establishing subunit as a software multicast routing table which needs to be refreshed to the software processing device;
the hardware routing table determination subunit includes:
a first judging module, configured to judge, for each multicast routing table entry in the multicast routing table established by the routing table establishing subunit, whether interface information of the multicast routing table entry is software wan interface information;
a second judging module, configured to, when receiving that the judgment result of the first judging module is yes, judge whether the egress interface information in the multicast routing table entry includes hardware switching interface information;
a third judging module, configured to, when receiving that the judgment result of the first judging module is that the incoming interface information is hardware switching interface information, judge whether the outgoing interface information in the multicast routing table entry includes software wan interface information;
the updating module is used for updating the interface information in the multicast routing table entry into the interface information corresponding to the connection channel when the judgment result received by the second judging module is yes; when the judgment result of the second judgment module is received to be negative, deleting the multicast routing table item; when the judgment result received by the third judgment module is yes, deleting the software wide area network interface information contained in the output interface information of the multicast routing table item, and adding the interface information corresponding to the connection channel to the output interface information of the multicast routing table item;
a determining module, configured to determine a routing table obtained after the multicast routing table established by the routing table establishing subunit is processed by the updating module as a hardware multicast routing table that needs to be flushed to a hardware processing device;
and the lower routing table brush unit is used for respectively sending the software multicast routing table and the hardware multicast routing table determined by the software routing table determining subunit and the determining module to the software processing device and the hardware processing device.
14. The routing device of claim 13, wherein the software processing means comprises: the device comprises a first storage unit, a first polling unit and a first forwarding unit; wherein,
the first storage unit is used for storing the software multicast routing table which is brushed by the brush unit under the routing table; the software multicast routing table comprises a plurality of multicast routing table entries, and the interface information in each multicast routing table entry is software wide area network interface information; the output interface information is software wide area network interface information and/or hardware exchange interface information;
the first polling unit is configured to determine a multicast routing table entry corresponding to a currently received multicast packet in the software multicast routing table stored in the first storage unit, and poll egress interface information included in the multicast routing table entry;
and the first forwarding unit is used for forwarding the multicast message according to the outgoing interface information polled by the first polling unit.
15. The routing device of claim 13, wherein the hardware processing means comprises: the second storage unit, the second acquisition unit and the second forwarding unit; wherein,
the second storage unit is configured to store a hardware multicast routing table that is flushed by the brush unit under the routing table, where the hardware multicast routing table includes multiple multicast routing table entries, and ingress interface information in each multicast routing table entry is interface information corresponding to the connection channel or hardware exchange interface information; the output interface information is hardware exchange interface information and/or interface information corresponding to the connection channel;
the second obtaining unit is configured to determine a multicast routing table entry of the received multicast packet in a hardware multicast routing table stored in the second storage unit; and obtaining the output interface information contained in the multicast routing list item;
the second forwarding unit is configured to forward the multicast packet according to the output interface corresponding to the output interface information acquired by the second acquiring unit.
16. The routing device of claim 14, wherein the hardware processing means comprises: the second storage unit, the second acquisition unit and the second forwarding unit; wherein,
the second storage unit is configured to store a hardware multicast routing table that is flushed by the brush unit under the routing table, where the hardware multicast routing table includes multiple multicast routing table entries, and ingress interface information in each multicast routing table entry is interface information corresponding to the connection channel or hardware exchange interface information; the output interface information is hardware exchange interface information and/or interface information corresponding to the connection channel;
the second obtaining unit is configured to determine a multicast routing table entry of the received multicast packet in a hardware multicast routing table stored in the second storage unit; and obtaining the output interface information contained in the multicast routing list item;
the second forwarding unit is configured to forward the multicast packet according to the output interface corresponding to the output interface information acquired by the second acquiring unit.
17. The routing device according to claim 14, wherein if the any one device is a software processing device and the another device is a hardware processing device, the software processing device further comprises: a first software judgment unit; wherein,
the first software judging unit is used for judging whether the outgoing interface information polled by the first polling unit currently is hardware exchange interface information, if so, judging whether the outgoing interface information polled currently is the first outgoing interface information containing the hardware exchange interface information in the determined multicast routing table entry, and if so, sending a first forwarding notification to the first forwarding unit; otherwise, if the currently polled outgoing interface information is not the first outgoing interface information containing the hardware exchange interface information in the determined multicast routing table entry, ignoring the hardware exchange interface information contained in the currently polled outgoing interface information;
after receiving the first forwarding notification sent by the first software judging unit, the first forwarding unit sends a multicast message to the hardware processing device through a connection channel; when the received judgment result of the first software judgment unit is that the current polled output interface information is the software wide area network interface information, the multicast message is copied to each software wide area network interface corresponding to each software wide area network interface information, and the multicast message is forwarded through each software wide area network interface.
18. The routing device of claim 16, wherein if any one device is a hardware processing device, the other device is a software processing device; the interface information acquired by the second acquiring unit includes interface information corresponding to the connection channel;
the software processing apparatus further includes: a second software judgment unit; wherein,
the first polling unit is also used for acquiring the access interface information in the determined multicast routing table entry; acquiring the output interface information in the determined multicast routing table item;
the second software judging unit judges whether the interface information acquired by the first polling unit is hardware exchange interface information; if yes, when the interface information polled by the first polling unit at present comprises software wide area network interface information and hardware exchange interface information, or only comprises the software wide area network interface information, sending a second forwarding notification to the first forwarding unit;
and the first forwarding unit receives the second forwarding notification, determines an interface corresponding to the software wide area network interface information in the outgoing interface information acquired by the first polling unit as an outgoing interface for forwarding the multicast message, and forwards the multicast message through the determined outgoing interface.
CN2009100846372A 2009-05-18 2009-05-18 Forwarding method of multicast messages and router Active CN101557342B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2009100846372A CN101557342B (en) 2009-05-18 2009-05-18 Forwarding method of multicast messages and router

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2009100846372A CN101557342B (en) 2009-05-18 2009-05-18 Forwarding method of multicast messages and router

Publications (2)

Publication Number Publication Date
CN101557342A CN101557342A (en) 2009-10-14
CN101557342B true CN101557342B (en) 2011-03-30

Family

ID=41175292

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2009100846372A Active CN101557342B (en) 2009-05-18 2009-05-18 Forwarding method of multicast messages and router

Country Status (1)

Country Link
CN (1) CN101557342B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102595248B (en) * 2012-01-18 2014-02-26 杭州华三通信技术有限公司 Multicast forwarding table item maintaining method and protocol independent multicast router
CN107707515B (en) 2017-02-15 2018-06-08 贵州白山云科技有限公司 A kind of method and device that Intelligent Hybrid acceleration is carried out to different safety class resource
CN108011828B (en) * 2017-12-07 2020-09-11 北京东土军悦科技有限公司 Multicast switching method, device, core layer switch and storage medium
CN108400939B (en) * 2018-03-02 2020-08-07 赛特斯信息科技股份有限公司 System and method for realizing accelerated multicast replication in NFV (network File System)
CN110398918A (en) * 2019-07-12 2019-11-01 中国电信集团工会上海市委员会 A kind of multicast flow control system of home gateway
CN110855568B (en) * 2019-11-22 2022-02-22 迈普通信技术股份有限公司 Message forwarding method and system
CN113132262B (en) * 2020-01-15 2024-05-03 阿里巴巴集团控股有限公司 Data stream processing and classifying method, device and system

Also Published As

Publication number Publication date
CN101557342A (en) 2009-10-14

Similar Documents

Publication Publication Date Title
CN101557342B (en) Forwarding method of multicast messages and router
US9774563B2 (en) Packet transmission method, apparatus, and system in multicast domain name system
US9100323B1 (en) Deadlock-resistant fabric tree replication in a network device
US10284384B2 (en) Standby method, intelligent home device, and standby system
TW201001989A (en) Route selection in wireless networks
JP2005505158A5 (en)
JP2007157085A (en) Sip server shared module, sip message relay system and program
JP5852232B2 (en) Multipath overlay network and multipath management protocol thereof
JP2015502113A5 (en)
RU2007102692A (en) VIRTUAL BROADCAST NETWORK FOR INTERDISTRIBUTION
WO2014023003A1 (en) Method, apparatus, and system for controlling data transmission
JP2006238341A (en) Network switch apparatus and method, wireless access apparatus, and wireless network
JP2003188903A (en) Outer, terminal unit, communication system, and routing method
CN103560962A (en) Method for automatically updating host routing table entries of Ethernet switch and switch
US9166884B2 (en) Network location service
KR100884184B1 (en) Method for setting up or releasing a multicast tree between two CE on MPLS VPN and method for providing multicasting service
WO2012068854A1 (en) Method and apparatus for updating media access control (mac) address
JP5941887B2 (en) Edge router switching method and system, edge router and redundancy management device
JP3782305B2 (en) Telecommunications apparatus and method for packet transmission using individual collision domains
EP2197169A1 (en) VoIP registration with multiple call servers
JP2012529190A (en) Methods and devices for requesting multicasting, processing multicasting requests, and assisting the process
RU2592408C2 (en) Method and apparatus for configuring medium access control space in service virtual private local area network
JP2017017678A (en) Intelligent routing for information-centric networking
US10142126B2 (en) Scalable dynamic overlay tunnel management
JP5369284B2 (en) Multicast processing method in wide area Ethernet

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: 310052 Binjiang District Changhe Road, Zhejiang, China, No. 466, No.

Patentee after: Xinhua three Technology Co., Ltd.

Address before: 310053 Hangzhou hi tech Industrial Development Zone, Zhejiang province science and Technology Industrial Park, No. 310 and No. six road, HUAWEI, Hangzhou production base

Patentee before: Huasan Communication Technology Co., Ltd.