CN101022414A - Message retransmitting method and apparatus - Google Patents
Message retransmitting method and apparatus Download PDFInfo
- Publication number
- CN101022414A CN101022414A CNA2007100734607A CN200710073460A CN101022414A CN 101022414 A CN101022414 A CN 101022414A CN A2007100734607 A CNA2007100734607 A CN A2007100734607A CN 200710073460 A CN200710073460 A CN 200710073460A CN 101022414 A CN101022414 A CN 101022414A
- Authority
- CN
- China
- Prior art keywords
- message
- control plane
- buffer memory
- passage
- empty formation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Landscapes
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本发明实施例涉及一种报文转发的方法和装置,本发明实施例提供的一种报文转发的方法和装置,通过在报文上送给控制平面的通道阻塞时将所述报文缓存,然后在所述通道不阻塞时将所缓存的报文上送给控制平面。这样可以解决攻击报文大量上送导致其他类型的正常上送报文被丢弃的问题。
The embodiment of the present invention relates to a method and device for message forwarding. The method and device for message forwarding provided by the embodiment of the present invention cache the message when the channel sent to the control plane on the message is blocked. , and then send the buffered message to the control plane when the channel is not blocked. This can solve the problem that other types of normally sent packets are discarded due to a large number of attack packets being sent.
Description
Technical field
The present invention relates to the communication technology, relate in particular to the method and apparatus that a kind of message is transmitted.
Background technology
In the distributed forwarding plane of router, mainly comprise control plane (Control Plane; CP) and Forwarding plane.Control plane mainly is responsible for the management, monitoring of whole router device and the collection of protocol massages that Forwarding plane is reported, calculate route, and generates forwarding-table item and be handed down to Forwarding plane; Forwarding plane also claims service plane, mainly is by searching described forwarding-table item the data message to be transmitted.So as can be seen, the needed forwarding-table item of Forwarding plane generates the back by control plane and gives down, and control plane calculates route, issues forwarding-table item and depend on Forwarding plane with the data message received in time, send on accurate.
As shown in Figure 1, Fig. 1 is the distributed forwarding plane schematic diagram of prior art router.Be Forwarding plane in the frame of broken lines among Fig. 1, Forwarding plane and control plane communicate by external bus, and Forwarding plane generally also comprises two elementary cells: quick retransmission unit (Express Forwarding Unit; EFU) and retransmission unit coprocessor (Forwarding Unit-Coprocessor; FU-C).EFU transmits the data message, generally is earlier the message of receiving to be checked, if the non-rule of message abandons; Handle according to forwarding-table item for data message, transmit or give control plane from the interface of appointment and handle; The method of giving the control plane processing on general is: the data message that will need to give control plane is put into first in first out (First In First Out; FIFO) and by giving CP on the FU-C.FU-C is the controller of Forwarding plane, is responsible for finishing configuration, the management of forwarding chip, finishes data flow transmission between EFU and CP, provides EFU interface operable function is used for the CP side.FU-C generally can visit the EFU internal resource by internal bus in addition, as general register.
Below in detail the message of giving control plane on the need is put into first in first out (First In FirstOut; FIFO) and by the process of giving CP on the FU-C describe.When EFU judges need give CP with message up sending the time, described message pointer is put among the FIFO, remove to handle the follow-up message transmitted of needing then.Need to prove, can index described message by described message pointer.FIFO may realize for the hardware in the Forwarding plane chip, also can realize by software.CP reads the message pointer from FIFO, calculate the physical address of message in internal memory then, reads internal memory and obtains the message particular content.When the message of buffer memory among the FIFO reaches a constant volume, such as the message when buffer memory among the FIFO reached its heap(ed) capacity 3/4ths the time, FIFO can provide the back-pressure signal, then EFU is follow-up no longer puts into message in FIFO, but with the packet loss of sending on the follow-up need, up to the back-pressure signal relief of FIFO, EFU just can continue to put into message in FIFO.
Because the message processing capability of current Forwarding plane is much larger than the message processing capability of control plane, send the message of CP that router is attacked on a large amount of need if there is the assailant to construct, the EFU of Forwarding plane finds that attack message send on needing, it will be placed among the FIFO, because the speed of attack message is easy to surpass the processing speed of control plane, FIFO will soon back-pressure give EFU like this, and the message that send on the follow-up like this needs is owing to the back-pressure of FIFO is dropped.Send if having on the attack message always, FIFO can be in full state always, even CP takes out message from FIFO, there is a new message to be put into FIFO again at once by EFU, will cause FIFO that the back-pressure signal is arranged always like this, EFU receives send protocol massages to be lost on normal, cause a period of time after consultation be interrupted, converting flow may occur and interrupt, so network equipment paralysis.
Summary of the invention
In view of this, the main purpose of the embodiment of the invention provides the method and apparatus that a kind of new message is transmitted, and send on a large amount of the literary composition that causes delivering newspaper on other types normal to be dropped the anti-attack ability of enhanced routers thereby solve attack message.
The purpose of the embodiment of the invention is achieved through the following technical solutions:
The method that the embodiment of the invention provides a kind of message to transmit comprises:
When blocking, the passage of giving control plane at message up sending, when described passage does not block, do not give described control plane then with the message up sending of institute's buffer memory with described packet buffer.
The device that the embodiment of the invention also provides a kind of message to transmit comprises as lower module:
On send passage to block the back-pressure module, be used for when message up sending is given the passage obstruction of control plane, sending the back-pressure signal;
Cache module carries out buffer memory with described message when being used to receive described back-pressure signal;
On send passage to block to cancel module, be used for when message up sending does not block to the passage of control plane, cancelling the back-pressure signal;
On send module, be used to receive and describedly give described control plane with described message up sending when cancelling the back-pressure signal.
The technical scheme that is provided by the invention described above embodiment as can be seen, adopt the embodiment of the invention, when blocking by the passage of giving control plane at message up sending with described packet buffer, when not blocking, described passage do not give CP in the message continuation with institute's buffer memory then, solving attack message send on a large amount of the literary composition that causes delivering newspaper on other types normal to be dropped the anti-attack ability of enhanced routers.
Description of drawings
Fig. 1 is the distributed forwarding plane schematic diagram of prior art router;
Fig. 2 be the embodiment of the invention when on deliver newspaper on when sending passage the to block schematic flow sheet of literary composition;
Fig. 3 be the embodiment of the invention when on message is transmitted when sending passage not block schematic flow sheet;
Fig. 4 is the schematic diagram of the apparatus for forwarding message of the embodiment of the invention.
Embodiment
When blocking by the passage of giving control plane at message up sending, the method and apparatus that the embodiment of the invention provides a kind of message to transmit, the embodiment of the invention, when described passage does not block, do not give CP then with the message up sending of institute's buffer memory with described packet buffer.
Express clearlyer for the purpose, technical scheme and the advantage that make the embodiment of the invention, be further described in more detail below in conjunction with drawings and the specific embodiments.
When the specific implementation of the embodiment of the invention, can Forwarding plane on the literary composition of delivering newspaper create empty formation, the parameter of described virtual pair row comprises buffer memory message number in head pointer, tail pointer, empty queue size and the empty formation at least.When message up sending blocks for the passage of control plane with described packet buffer in empty formation, for example when the back-pressure signal is arranged among the FIFO, to need to deliver to the packet buffer of CP in described empty formation by EFU, if message is when going into empty formation, buffer memory message number has reached described empty queue size in the current empty formation, then can will be abandoned above the message behind the described empty queue size.Among the another kind of embodiment, in order to solve the problem that the literary composition of delivering newspaper on other types that a certain kind attack message causes normal is dropped, and E-Packet neatly according to specific demand, we can create an empty formation at the literary composition of delivering newspaper on each, and the parameter of every kind of empty formation comprises buffer memory message number in head pointer, tail pointer, empty queue size and the empty formation at least.And we can be for every kind of message distributes a sign (ID), and when message up sending blocked for the passage of control plane, the empty formation according to the ID of described message indexes correspondence added described empty formation buffer memory with described message.Simultaneously, the tail pointer of described empty formation adds 1, and buffer memory message number adds 1 in the formation.In order to understand above-mentioned flow process better, can be with reference to figure 2, Fig. 2 for the embodiment of the invention when on deliver newspaper on when sending passage the to block schematic flow sheet of literary composition.When not blocking, described passage do not give CP in the message continuation with institute's buffer memory then.For example after the back-pressure signal among the FIFO is cancelled, EFU dispatches described message and comes out to put into FIFO and give CP by FU-C from empty formation.
Because the state of buffer memory message may be different in the different empty formations, so after the back-pressure signal of FIFO is cancelled, need find an empty formation that is cached with message apace, from described empty formation, take out the message pointer, generally we can begin to get the message pointer from empty formation head, and it is put into FIFO by giving CP on the FU-C.For the empty formation of finding one to be cached with message apace, for instance, we can adopt fair algorithm to come empty formation is dispatched.For example after the back-pressure signal among the FIFO is cancelled, we can index pairing empty formation according to the ID of every kind of message, when in the described virtual pair row message being arranged, obtain described message pointer from the head of described empty formation, and described head pointer added 1, described empty formation buffer memory message number subtracts 1.When not having message in the described empty formation, then its pairing empty formation of ID index by another kind of message.Convenient for index, we can be provided with the relation of every kind of message ID value for increasing progressively successively.Like this, if when not having message in the pairing empty formation of certain message ID index, we can directly add 1 with the ID value, thus the message of other kinds of index.Understand above-mentioned flow process for convenience, we can be with reference to figure 3, Fig. 3 be the embodiment of the invention when on message is transmitted when sending passage not block schematic flow sheet.For the empty formation of finding one to be cached with message apace, we can also construct a global data structures, comprise each empty formation in the described global data structures at least and whether it has the corresponding informance of buffer memory message; As shown in table 1, a flag bit can be set, do not contain message in the empty formation of 0 representative; Contain message in the empty formation of 1 representative.
| Empty queuing message | Flag bit |
| Empty formation 1 | 0 |
| Empty formation 2 | 1 |
| Empty formation 3 | 1 |
Table 1
Like this, after the back-pressure signal among the FIFO was cancelled, EFU can find a formation that is cached with message fast by described global data structures.
Under the situation that all has message to exist in a plurality of empty formations, we can adopt fair algorithm to send on the message in each empty formation is carried out successively; Perhaps we can set different priority for different message kinds, consider every kind of priority of messages, the message of priority treatment high priority during scheduling.In addition, can also be that every kind of message is set different weights according to system's needs, for example set the message of high priority transmitted 1000 after, need transmit 1O etc. to the message of low priority.This can change flexibly according to concrete practical application.
In the specific implementation of the embodiment of the invention, if the processing speed of FU-C greater than the CP processing speed, the message of giving CP on has then arrived the CP rear flank and also can have been lost by the CP side.We can also introduce back-pressure mechanism between CP and FU-C, back-pressure is not given FU-C when the CP processing is come, and gives EFU by the FU-C back-pressure again, by the EFU dropping packets.In addition, we also can adjust the processing speed of FU-C, and for example the speed of maintenance and CP keeps basic identical.
In addition, the device that the embodiment of the invention provides a kind of message to transmit can be with reference to figure 4, and Fig. 4 is the schematic diagram of the apparatus for forwarding message of the embodiment of the invention.Comprise as lower module:
On send passage to block the back-pressure module, be used for when message up sending is given the passage obstruction of control plane, sending the back-pressure signal; Cache module carries out buffer memory with described message when being used to receive described back-pressure signal; On send passage to block to cancel module, be used for when message up sending does not block to the passage of control plane, cancelling the back-pressure signal; On send module, be used to receive on described will described message when cancelling the back-pressure signal continuation and give described control plane.
So the method and apparatus that a kind of message that the embodiment of the invention provides is transmitted with described packet buffer, is not given CP in the message continuation with institute's buffer memory when blocking by the passage of giving control plane at message up sending then when described passage does not block.Can solve the problem that attack message send on a large amount of the literary composition that causes delivering newspaper on other types normal to be dropped like this.In addition, the embodiment of the invention is created an empty formation at every kind of message, can abandon at the special packet type, influences the processing of other normal message in a large number to prevent the particular attack message.
The above; only for the preferable embodiment of the present invention, but protection scope of the present invention is not limited thereto, and anyly is familiar with the people of this technology in the disclosed technical scope of the present invention; the variation that can expect easily or replacement all should be encompassed within protection scope of the present invention.
Claims (10)
1, a kind of method of message forwarding is characterized in that, comprising:
When blocking, the passage of giving control plane at message up sending, when described passage does not block, do not give described control plane then with the message up sending of institute's buffer memory with described packet buffer.
2, method according to claim 1, it is characterized in that, described described packet buffer is specifically comprised: described message is gone into empty formation, and described empty formation comprises following four parameters at least: buffer memory message number in head pointer, tail pointer, empty queue size and the empty formation.
3, method according to claim 2 is characterized in that, describedly described message is gone into empty formation specifically comprises:
Obtain the sign of described message;
Search pairing empty formation according to described sign;
Described message is gone into described empty formation, and the tail pointer of described empty formation adds 1, and buffer memory message number adds 1 in the described empty formation.
4, according to claim 2 or 3 described methods, it is characterized in that, describedly described message is gone into empty formation also comprise: when described empty formation buffer memory message number reaches described empty queue size, then with described packet loss.
5, method according to claim 2 is characterized in that, describedly gives described control plane on when described passage does not block the message of institute's buffer memory being continued and specifically comprises:
Identification index according to message arrives pairing empty formation;
Obtain the message up sending of described empty formation institute buffer memory from described empty formation and give described control plane.
6, method according to claim 2 is characterized in that, describedly gives described control plane on when described passage does not block the message of institute's buffer memory being continued and specifically comprises:
Search the empty formation that global data structures obtains the buffer memory message, described global data structures comprises the information whether each empty formation has the buffer memory message at least;
Obtain described message from described empty formation head and continue to give described control plane.
7, according to claim 5 or 6 described methods, it is characterized in that, describedly give described control plane on when described passage does not block, the message of institute's buffer memory being continued and specifically comprise: give described control plane on when described passage does not block, the message of institute's buffer memory being continued according to the priority of described message kind.
8, method according to claim 1 is characterized in that, describedly also comprises after giving described control plane on when described passage does not block the message of institute's buffer memory being continued:
When the processing speed of retransmission unit coprocessor during greater than the processing speed of control plane, described control plane will provide the back-pressure signal to described retransmission unit coprocessor;
Described retransmission unit coprocessor offers quick retransmission unit with described back-pressure signal;
Described quick retransmission unit is with described packet loss.
9, method according to claim 1 is characterized in that, describedly also comprises after giving described control plane on when described passage does not block the message of institute's buffer memory being continued:
When the processing speed of retransmission unit coprocessor during greater than the processing speed of control plane, adjust the processing speed of described retransmission unit coprocessor, the processing speed of itself and described control plane is consistent.
10, a kind of device of message forwarding is characterized in that, comprises as lower module:
On send passage to block the back-pressure module, be used for when message up sending is given the passage obstruction of control plane, sending the back-pressure signal;
Cache module carries out buffer memory with described message when being used to receive described back-pressure signal;
On send passage to block to cancel module, be used for when message up sending does not block to the passage of control plane, cancelling the back-pressure signal;
On send module, be used to receive and describedly give described control plane with described message up sending when cancelling the back-pressure signal.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN2007100734607A CN101022414B (en) | 2007-03-08 | 2007-03-08 | Message retransmitting method and apparatus |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN2007100734607A CN101022414B (en) | 2007-03-08 | 2007-03-08 | Message retransmitting method and apparatus |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN101022414A true CN101022414A (en) | 2007-08-22 |
| CN101022414B CN101022414B (en) | 2010-11-03 |
Family
ID=38710069
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN2007100734607A Expired - Fee Related CN101022414B (en) | 2007-03-08 | 2007-03-08 | Message retransmitting method and apparatus |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN101022414B (en) |
Cited By (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103534704A (en) * | 2012-10-31 | 2014-01-22 | 华为技术有限公司 | A method, network device and processor for processing failure messages |
| WO2014019516A1 (en) * | 2012-08-02 | 2014-02-06 | 华为技术有限公司 | Method and device for forwarding message |
| CN105791140A (en) * | 2014-12-19 | 2016-07-20 | 中兴通讯股份有限公司 | Message sending processing method and apparatus and network equipment |
| CN103701710B (en) * | 2013-12-20 | 2017-01-11 | 杭州华为数字技术有限公司 | Data transmission method, core forwarding equipment and endpoint forwarding equipment |
| CN109640280A (en) * | 2019-01-10 | 2019-04-16 | 深圳市沃特沃德股份有限公司 | Call control method, device, computer equipment and storage medium |
| CN111131089A (en) * | 2019-12-24 | 2020-05-08 | 西安电子科技大学 | A Queue Management Method to Improve HOL Blocking of Multicast Service |
Family Cites Families (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1210922C (en) * | 2002-07-24 | 2005-07-13 | 华为技术有限公司 | Method for processing large tasks in network apparatus |
| CN100454895C (en) * | 2005-06-30 | 2009-01-21 | 华为技术有限公司 | A Method of Improving Network Security Through Packet Processing |
| CN1913486A (en) * | 2005-08-10 | 2007-02-14 | 中兴通讯股份有限公司 | Method and device for strengthening safety of protocol message |
-
2007
- 2007-03-08 CN CN2007100734607A patent/CN101022414B/en not_active Expired - Fee Related
Cited By (9)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2014019516A1 (en) * | 2012-08-02 | 2014-02-06 | 华为技术有限公司 | Method and device for forwarding message |
| CN103534704A (en) * | 2012-10-31 | 2014-01-22 | 华为技术有限公司 | A method, network device and processor for processing failure messages |
| WO2014067099A1 (en) * | 2012-10-31 | 2014-05-08 | 华为技术有限公司 | Method, network device and processor for processing failure message |
| CN103701710B (en) * | 2013-12-20 | 2017-01-11 | 杭州华为数字技术有限公司 | Data transmission method, core forwarding equipment and endpoint forwarding equipment |
| US9967201B2 (en) | 2013-12-20 | 2018-05-08 | Huawei Technologies Co., Ltd. | Data transmission method, core forwarding device, and endpoint forwarding device |
| CN105791140A (en) * | 2014-12-19 | 2016-07-20 | 中兴通讯股份有限公司 | Message sending processing method and apparatus and network equipment |
| CN109640280A (en) * | 2019-01-10 | 2019-04-16 | 深圳市沃特沃德股份有限公司 | Call control method, device, computer equipment and storage medium |
| CN111131089A (en) * | 2019-12-24 | 2020-05-08 | 西安电子科技大学 | A Queue Management Method to Improve HOL Blocking of Multicast Service |
| CN111131089B (en) * | 2019-12-24 | 2021-07-27 | 西安电子科技大学 | A Queue Management Method to Improve HOL Blocking of Multicast Service |
Also Published As
| Publication number | Publication date |
|---|---|
| CN101022414B (en) | 2010-11-03 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP4057579A1 (en) | Data forwarding method, data buffering method, device, and related apparatus | |
| EP2540042B1 (en) | Communication transport optimized for data center environment | |
| US7145914B2 (en) | System and method for controlling data paths of a network processor subsystem | |
| JP4154213B2 (en) | Packet processing device | |
| EP2074756B1 (en) | Method, system, and computer program product for resequencing of data segments received over a bonding channel set | |
| CN101557348B (en) | A message forwarding method and device based on token bucket | |
| CN101022414A (en) | Message retransmitting method and apparatus | |
| US8174987B2 (en) | Method and apparatus for implementing output queue-based flow control | |
| Lu et al. | Memory efficient loss recovery for hardware-based transport in datacenter | |
| CN102035751A (en) | Data transmission method and equipment | |
| US20110087930A1 (en) | Self-cleaning mechanism for error recovery | |
| CN104053076A (en) | A method and system for improving bandwidth allocation efficiency | |
| CN101351781B (en) | Method and system for processing incoming packets in a communication network | |
| CN103617132B (en) | A kind of ethernet terminal based on shared storage sends implementation method and terminal installation | |
| EP2477366A1 (en) | Data transmission method, apparatus and system | |
| US6532503B1 (en) | Method and apparatus to detect lost buffers with a descriptor based queue | |
| CN102299861A (en) | Message traffic control method | |
| CN101702714A (en) | Method, system and apparatus for credit-based flow control in a computer system | |
| JP4293703B2 (en) | Queue control unit | |
| Rezaei et al. | ResQueue: A smarter datacenter flow scheduler | |
| CN101079873B (en) | A firewall device based on ACP framework | |
| CN110765044B (en) | Data packet transmission device and system | |
| EP1661332B1 (en) | Electronic circuit with processing units coupled via a communications network | |
| CN102006224A (en) | Method and device for forwarding supervirtual local area network (SUPERVLAN) messages | |
| CN105306290B (en) | Flow table entry scale prediction method and device |
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 | ||
| CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20101103 |
|
| CF01 | Termination of patent right due to non-payment of annual fee |