[go: up one dir, main page]

CN105791155B - Method and device for managing congested traffic - Google Patents

Method and device for managing congested traffic Download PDF

Info

Publication number
CN105791155B
CN105791155B CN201410816492.1A CN201410816492A CN105791155B CN 105791155 B CN105791155 B CN 105791155B CN 201410816492 A CN201410816492 A CN 201410816492A CN 105791155 B CN105791155 B CN 105791155B
Authority
CN
China
Prior art keywords
token
leaky bucket
congestion
congestion level
congested
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
CN201410816492.1A
Other languages
Chinese (zh)
Other versions
CN105791155A (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.)
Sanechips Technology Co Ltd
Original Assignee
Shenzhen ZTE Microelectronics Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen ZTE Microelectronics Technology Co Ltd filed Critical Shenzhen ZTE Microelectronics Technology Co Ltd
Priority to CN201410816492.1A priority Critical patent/CN105791155B/en
Priority to PCT/CN2015/080801 priority patent/WO2016101549A1/en
Publication of CN105791155A publication Critical patent/CN105791155A/en
Application granted granted Critical
Publication of CN105791155B publication Critical patent/CN105791155B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of management methods of congested flow, switching equipment is according to the depth of the congestion leaky bucket in message transmissions path, determine congestion level, according to the corresponding token add value of the congestion level, update the depth of Token Control leaky bucket, when the depth of Token Control leaky bucket reaches a standard token value, the congestion leaky bucket in Xiang Suoshu message transmissions path issues a standard token, and the depth of Token Control leaky bucket is subtracted standard token value;The present invention also discloses a kind of managing devices of congested flow.

Description

一种拥塞流量的管理方法和装置Method and device for managing congested traffic

技术领域technical field

本发明涉及数据通信技术,尤其涉及一种拥塞流量的管理方法和装置。The invention relates to data communication technology, in particular to a management method and device for congested traffic.

背景技术Background technique

随着因特网业务的爆炸性增长,数据链路的流量越来越大,所需的交换设备的处理能力越来越高。目前的各种交换芯片通常面临着处理流量大,升级困难的问题,动则需要整个芯片系统架构进行颠覆性改动;这种架构的变动不仅需要投入大量人力进行重新开发、验证、测试,而且新项目的时间进度以及项目质量都受到非常大的影响。With the explosive growth of Internet services, the traffic of the data link is getting larger and larger, and the processing capability of the required switching equipment is getting higher and higher. The current various switching chips usually face the problems of large processing traffic and difficult upgrades, which require subversive changes to the entire chip system architecture; this architecture change not only requires a lot of manpower for redevelopment, verification, and testing, but also new The time schedule of the project and the quality of the project are greatly affected.

在我们的使用过程中,实际情况为:当一个流量源向交换网开始发流或者多个流量源同时向交换网开始发流,会引起突发,而由于交换网的缓存不大,就不能很好的将突发吸收掉,导致拥塞甚至丢包。另外从停流到发流时,流量会很大或者会发生较大的波动,同样也会产生拥塞甚至丢包。In our use, the actual situation is: when one traffic source starts to send traffic to the switching network or multiple traffic sources start to send traffic to the switching network at the same time, it will cause a burst, and because the buffer of the switching network is not large, it cannot It absorbs bursts very well, causing congestion or even packet loss. In addition, when the flow is stopped to flow, the traffic will be very large or fluctuate greatly, and congestion or even packet loss will also occur.

基于以上问题,如何在现有小缓存的情况下,避免较大的突发,平缓流量,减轻交换网的压力,是亟需解决的问题。Based on the above problems, how to avoid large bursts, smooth traffic, and reduce the pressure on the switching network in the case of the existing small cache is an urgent problem to be solved.

发明内容Contents of the invention

为解决现有存在的技术问题,本发明主要提供一种拥塞流量的管理方法和装置。In order to solve the existing technical problems, the present invention mainly provides a management method and device for congested traffic.

本发明的技术方案是这样实现的:Technical scheme of the present invention is realized like this:

本发明提供一种拥塞流量的管理方法,该方法包括:The present invention provides a management method for congested traffic, the method comprising:

交换设备根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;The switching device determines the congestion level according to the depth of the congestion leaky bucket of the packet transmission path;

根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;According to the token addition value corresponding to the congestion level, update the depth of the token control leaky bucket;

当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。When the depth of the token control leaky bucket reaches a standard token value, a standard token is issued to the congestion leaky bucket of the message transmission path, and the depth of the token control leaky bucket is subtracted from the standard token value.

上述方案中,所述拥塞等级通过拥塞门限划分,N个拥塞门限划分出N+1个拥塞等级,每个拥塞等级对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小。In the above scheme, the congestion level is divided by the congestion threshold, and N congestion thresholds are divided into N+1 congestion levels, and each congestion level is correspondingly set with a token added value, and the higher the congestion level, the higher the corresponding token added value. Small.

上述方案中,该方法还包括:交换设备在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间。In the above solution, the method further includes: after the switching device determines the congestion level of the congested leaky bucket, according to the depth change of the congested leaky bucket, when the congestion level of the congested leaky bucket drops to the next congestion level, waiting for the first time, When the first time is up, the congestion level is updated; wherein, the first time is a random waiting time constructed through a random sequence.

上述方案中,该方法还包括:在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;In the above scheme, the method also includes: within the first time, if the congestion level of the congested leaky bucket rises to the original congestion level again, stop waiting, and clear the counter at the first time;

如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为设置的固定时间。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is the fixed time set.

上述方案中,该方法还包括:交换设备向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目,根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。In the above solution, the method further includes: when the switching device issues a standard token to the congested leaky bucket of the message transmission path, detecting the number of valid links in the message transmission path, and selecting the corresponding token according to the number of valid links Issue rate, issue standard tokens.

本发明提供一种拥塞流量的管理方法,该方法包括:The present invention provides a management method for congested traffic, the method comprising:

交换设备向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目,根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。When the switching device issues a standard token to the congested leaky bucket of the packet transmission path, it detects the number of valid links in the packet transmission path, selects the corresponding token issuance rate according to the number of effective links, and issues the standard token .

上述方案中,当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率。In the above solution, when the number of effective links decreases, a corresponding low token issuing rate is selected, and when the number of effective links increases, a corresponding high token issuing rate is selected.

本发明提供一种拥塞流量的管理装置,该装置包括:等级确定模块、更新深度模块、令牌下发模块;其中,The present invention provides a management device for congested traffic, which includes: a level determination module, an update depth module, and a token issuing module; wherein,

等级确定模块,用于根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;A level determination module, configured to determine the congestion level according to the depth of the congestion leaky bucket of the message transmission path;

更新深度模块,用于根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;An update depth module is used to update the depth of the token control leaky bucket according to the token addition value corresponding to the congestion level;

令牌下发模块,用于当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。A token issuing module, configured to issue a standard token to the congested leaky bucket of the message transmission path when the depth of the token control leaky bucket reaches a standard token value, and send the token control leaky bucket Depth minus standard token value.

上述方案中,所述拥塞等级通过拥塞门限划分,N个拥塞门限划分出N+1个拥塞等级,每个拥塞等级对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小。In the above scheme, the congestion level is divided by the congestion threshold, and N congestion thresholds are divided into N+1 congestion levels, and each congestion level is correspondingly set with a token added value, and the higher the congestion level, the higher the corresponding token added value. Small.

上述方案中,该装置还包括:等级更新模块,用于在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间。In the above solution, the device also includes: a level update module, used for determining the congestion level of the congested leaky bucket, according to the depth change of the congested leaky bucket, when the congestion level of the congested leaky bucket drops to the next congestion level, wait for the first At one time, when the first time is up, the congestion level is updated; wherein, the first time is a random waiting time constructed through a random sequence.

上述方案中,所述等级更新模块,还用于在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;In the above solution, the level update module is also used to stop waiting and clear the counter at the first time if the congestion level of the congested leaky bucket rises to the original congestion level within the first time;

如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为设置的固定时间。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is the fixed time set.

上述方案中,该装置还包括:有效链路数目检测模块、速率选择模块;其中,In the above solution, the device also includes: an effective link number detection module and a rate selection module; wherein,

有效链路数目检测模块,用于在向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;The effective link number detection module is used to detect the effective link number of the message transmission path when issuing a standard token to the congested leaky bucket of the message transmission path;

速率选择模块,用于根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。A rate selection module, configured to select a corresponding token issuing rate according to the number of valid links, and issue standard tokens.

本发明提供一种拥塞流量的管理装置,该装置包括:有效链路数目检测模块、速率选择模块;其中,The present invention provides a management device for congested traffic, which includes: an effective link number detection module and a rate selection module; wherein,

有效链路数目检测模块,用于在向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;The effective link number detection module is used to detect the effective link number of the message transmission path when issuing a standard token to the congested leaky bucket of the message transmission path;

速率选择模块,用于根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。A rate selection module, configured to select a corresponding token issuing rate according to the number of valid links, and issue standard tokens.

本发明提供了一种拥塞流量的管理方法和装置,交换设备根据报文传输路径的拥塞漏桶的深度,确定拥塞等级,根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度,当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值;如此,能够在交换网缓存小的情况下,避免较大的流量突发,平缓流量,减轻交换网的压力。The present invention provides a management method and device for congested traffic. The switching device determines the congestion level according to the depth of the congested leaky bucket of the message transmission path, and updates the token control leaky bucket according to the added value of the token corresponding to the congestion level. When the depth of the token control leaky bucket reaches a standard token value, a standard token is issued to the congested leaky bucket of the message transmission path, and the depth of the token control leaky bucket is subtracted from the standard token In this way, when the switching network cache is small, large traffic bursts can be avoided, the traffic will be smoothed, and the pressure on the switching network will be reduced.

附图说明Description of drawings

图1为本发明实施例提供的拥塞流量的管理方法的流程示意图;FIG. 1 is a schematic flowchart of a method for managing congested traffic provided by an embodiment of the present invention;

图2为本发明实施例提供的拥塞门限对应的桶深示意图;FIG. 2 is a schematic diagram of the bucket depth corresponding to the congestion threshold provided by the embodiment of the present invention;

图3为本发明实施例提供的通过控制令牌下发速率进行拥塞流量管理的方法流程示意图;FIG. 3 is a schematic flowchart of a method for managing congestion traffic by controlling the rate at which tokens are issued according to an embodiment of the present invention;

图4为本发明实施例提供的拥塞流量的管理装置的结构示意图;FIG. 4 is a schematic structural diagram of a management device for congested traffic provided by an embodiment of the present invention;

图5为本发明实施例提供的控制令牌下发速率的管理装置的结构示意图。Fig. 5 is a schematic structural diagram of a management device for controlling the rate of issuing tokens according to an embodiment of the present invention.

具体实施方式Detailed ways

本发明实施例中,交换设备根据报文传输路径的拥塞漏桶的深度,确定拥塞等级,根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度,当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。In the embodiment of the present invention, the switching device determines the congestion level according to the depth of the congested leaky bucket of the message transmission path, and updates the depth of the token control leaky bucket according to the token added value corresponding to the congestion level. When the depth of the bucket reaches a standard token value, a standard token is issued to the congestion leaky bucket of the message transmission path, and the depth of the token control leaky bucket is subtracted from the standard token value.

下面通过附图及具体实施例对本发明做进一步的详细说明。The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

本发明实施例实现一种拥塞流量的管理方法,如图1所示,该方法包括以下几个步骤:The embodiment of the present invention implements a management method for congested traffic, as shown in Figure 1, the method includes the following steps:

步骤101:交换设备根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;Step 101: the switching device determines the congestion level according to the depth of the congestion leaky bucket of the message transmission path;

本步骤中,所述拥塞等级通过预先设置的拥塞门限划分,可以通过N个拥塞门限划分出N+1个拥塞等级,拥塞等级可以由控制信号表示,每个拥塞等级预先对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小,如图2所示,通过8个拥塞门限TH0~TH7划分出9个拥塞等级,8个拥塞门限TH0~TH7按照拥塞漏桶的深度从0到最大(MAX)依次增大,9个拥塞等级可以由4比特的控制信号表示,如表1所示:In this step, the congestion level is divided by the preset congestion threshold, and N+1 congestion levels can be divided by N congestion thresholds, the congestion level can be represented by a control signal, and each congestion level is correspondingly set in advance with a token to add Value, the higher the congestion level, the smaller the corresponding token addition value. As shown in Figure 2, 9 congestion levels are divided by 8 congestion thresholds TH0~TH7, and the 8 congestion thresholds TH0~TH7 are based on the depth of the congestion leaky bucket Increasing sequentially from 0 to maximum (MAX), nine congestion levels can be represented by 4-bit control signals, as shown in Table 1:

步骤102:交换设备根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;Step 102: The switching device updates the depth of the token control leaky bucket according to the token addition value corresponding to the congestion level;

例如:交换设备根据所述拥塞等级6对应的令牌添加值为VALUE5,将令牌控制漏桶的深度加上VALUE5。For example: according to the token addition value VALUE5 corresponding to the congestion level 6, the switching device adds VALUE5 to the depth of the token control leaky bucket.

步骤103:当令牌控制漏桶的深度达到一个标准令牌价值时,交换设备向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。Step 103: When the depth of the token control leaky bucket reaches a standard token value, the switching device issues a standard token to the congested leaky bucket of the message transmission path, and subtracts the depth of the token control leaky bucket from Standard token value.

上述方法还包括:交换设备在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间,所述随机序列可以是配置mask字段,将mask字段中的某些bit屏蔽,产生16bit的伪随机序列;这样,让每个等级在下降之前先随机等待一段时间,可以达到错开不同流量源的效果,并且伪随机序列的随机性越好,错开的效果越好,理想情况下就是所有流量源等待的时间都不相同,这样就能够完全错开。The above method also includes: after the switching device determines the congestion level of the congested leaky bucket, according to the depth change of the congested leaky bucket, when the congestion level of the congested leaky bucket drops to the next congestion level, wait for the first time, and arrive at the first time When, the congestion level is updated; wherein, the first time is a random waiting time constructed by a random sequence, and the random sequence can be configured with a mask field, and certain bits in the mask field are shielded to generate a 16-bit pseudo-random sequence ; In this way, let each level wait randomly for a period of time before dropping, which can achieve the effect of staggering different traffic sources, and the better the randomness of the pseudo-random sequence, the better the staggering effect. Ideally, it is what all traffic sources wait for The times are different so that they can be completely staggered.

该方法还包括:在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;The method also includes: within the first time, if the congestion level of the congested leaky bucket rises to the original congestion level again, then stop waiting, and clear the counter at the first time;

如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为预先设置的固定时间;这样,能够起到对多等级突发的平滑作用。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is a preset fixed time; in this way, it can play a smoothing effect on multi-level bursts.

该方法还包括:交换设备向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目,根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌;当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率;The method also includes: when the switching device issues a standard token to the congested leaky bucket of the message transmission path, detecting the number of valid links in the message transmission path, and selecting a corresponding token issuing rate according to the number of valid links, Issuance of standard tokens; when the number of effective links decreases, select the token issuance rate with the corresponding low rate; when the number of effective links increases, select the token issuance rate with the corresponding high rate;

这里,需要预先针对不同的有效链路数目设置对应的令牌下发速率,有效链路数目越多,设置的令牌下发速率越低。Here, it is necessary to pre-set the corresponding token issuing rate for different numbers of effective links. The more effective links are, the lower the token issuing rate is set.

本发明实施例还实现一种拥塞流量的管理方法,如图3所示,该方法包括以下几个步骤:The embodiment of the present invention also implements a management method for congested traffic, as shown in FIG. 3 , the method includes the following steps:

步骤301:交换设备向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;Step 301: when the switching device issues a standard token to the congested leaky bucket of the packet transmission path, detect the number of effective links in the packet transmission path;

这里,可以通过统计有效链路的数量来检测报文传输路径的有效链路数目,所述有效链路为当链路连续接收正确报文超过一定数量时,该链路即认定为有效链路。Here, the number of effective links in the message transmission path can be detected by counting the number of effective links. The effective link is that when the link continuously receives correct messages exceeding a certain number, the link is identified as an effective link .

步骤302:根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌;这里,当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率。Step 302: Select the corresponding token issuance rate according to the number of effective links, and issue standard tokens; here, when the number of effective links decreases, select the corresponding token issuance rate with a low rate. When the number of paths increases, select the token issuing rate with the corresponding high rate.

该方法需要预先针对不同的有效链路数目设置对应的令牌下发速率,有效链路数目越多,设置的令牌下发速率越低。This method needs to pre-set the corresponding token issuing rate according to the number of effective links, and the more the number of effective links is, the lower the token issuing rate is set.

为了实现上述方法,本发明还提供一种拥塞流量的管理装置,如图4所示,该装置包括:等级确定模块41、更新深度模块42、令牌下发模块43;其中,In order to implement the above method, the present invention also provides a management device for congested traffic, as shown in Figure 4, the device includes: a level determination module 41, an update depth module 42, and a token issuing module 43; wherein,

等级确定模块41,用于根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;A level determination module 41, configured to determine the level of congestion according to the depth of the congestion leaky bucket of the message transmission path;

更新深度模块42,用于根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;Update depth module 42, for updating the depth of the token control leaky bucket according to the token addition value corresponding to the congestion level;

令牌下发模块43,用于当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值;The token sending module 43 is used for sending a standard token to the congestion leaky bucket of the message transmission path when the depth of the token control leaky bucket reaches a standard token value, and the token control leaky bucket depth minus the standard token value;

所述拥塞等级通过预先设置的拥塞门限划分,可以通过N个拥塞门限划分出N+1个拥塞等级,拥塞等级可以由控制信号表示,每个拥塞等级预先对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小。The congestion level is divided by a preset congestion threshold, and N+1 congestion levels can be divided by N congestion thresholds. The congestion level can be represented by a control signal. Each congestion level corresponds to a token addition value set in advance, and the congestion level The higher the value, the smaller the corresponding token addition value.

该装置还包括:等级更新模块44,用于在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间,所述随机序列可以是配置mask字段,将mask字段中的某些bit屏蔽,产生16bit的伪随机序列;The device also includes: a level updating module 44, which is used to wait for the first time when the congestion level of the congested leaky bucket drops to the next congestion level according to the depth change of the congested leaky bucket after determining the congestion level of the congested leaky bucket, When the first time arrives, the congestion level is updated; wherein, the first time is a random waiting time constructed by a random sequence, and the random sequence can be configured with a mask field, and certain bits in the mask field are shielded to generate 16bit pseudo-random sequence;

所述等级更新模块44,还用于在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;The level update module 44 is also used for the first time, if the congestion level of the congested leaky bucket rises to the original congestion level again, stop waiting, and clear the counter at the first time;

如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为预先设置的固定时间。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is a preset fixed time.

该装置还包括:有效链路数目检测模块45、速率选择模块46;其中,The device also includes: effective link number detection module 45, rate selection module 46; wherein,

有效链路数目检测模块45,用于在向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;The effective link number detection module 45 is used to detect the effective link number of the message transmission path when issuing a standard token to the congested leaky bucket of the message transmission path;

速率选择模块46,用于根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌;当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率;The rate selection module 46 is used to select a corresponding token issuing rate according to the number of effective links, and issue a standard token; when the number of effective links decreases, select a corresponding token issuing rate with a low rate, when When the number of effective links increases, select the corresponding high-speed token issuing rate;

这里,需要预先针对不同的有效链路数目设置对应的令牌下发速率,有效链路数目越多,设置的令牌下发速率越低。Here, it is necessary to pre-set the corresponding token issuing rate for different numbers of effective links. The more effective links are, the lower the token issuing rate is set.

上述各模块均可以由交换设备中的处理器结合存储器和接口实现。Each of the above modules can be implemented by a processor in the switching device in combination with a memory and an interface.

基于上述装置,本发明还提供一种拥塞流量的管理装置,如图5所示,该装置包括:有效链路数目检测模块45、速率选择模块46;其中,Based on the above device, the present invention also provides a management device for congested traffic, as shown in Figure 5, the device includes: a valid link number detection module 45, a rate selection module 46; wherein,

有效链路数目检测模块45,用于在向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;The effective link number detection module 45 is used to detect the effective link number of the message transmission path when issuing a standard token to the congested leaky bucket of the message transmission path;

速率选择模块46,用于根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌;当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率;The rate selection module 46 is used to select a corresponding token issuing rate according to the number of effective links, and issue a standard token; when the number of effective links decreases, select a corresponding token issuing rate with a low rate, when When the number of effective links increases, select the corresponding high-speed token issuing rate;

这里,需要预先针对不同的有效链路数目设置对应的令牌下发速率,有效链路数目越多,设置的令牌下发速率越低。Here, it is necessary to pre-set the corresponding token issuing rate for different numbers of effective links. The more effective links are, the lower the token issuing rate is set.

综上所述,本发明实施例根据拥塞漏桶的深度对应的拥塞等级,控制标准令牌的下发,能够在交换网缓存小的情况下,避免较大的流量突发,平缓流量,减轻交换网的压力。In summary, the embodiment of the present invention controls the issuance of standard tokens according to the congestion level corresponding to the depth of the congested leaky bucket, which can avoid large traffic bursts, smooth traffic, and reduce Switching network pressure.

以上所述,仅为本发明的较佳实施例而已,并非用于限定本发明的保护范围,凡在本发明的精神和原则之内所作的任何修改、等同替换和改进等,均应包含在本发明的保护范围之内。The above description is only a preferred embodiment of the present invention, and is not used to limit the protection scope of the present invention. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present invention shall be included in the within the protection scope of the present invention.

Claims (11)

1.一种拥塞流量的管理方法,其特征在于,该方法包括:1. A management method for congested traffic, characterized in that the method comprises: 交换设备根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;The switching device determines the congestion level according to the depth of the congestion leaky bucket of the packet transmission path; 根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;According to the token addition value corresponding to the congestion level, update the depth of the token control leaky bucket; 当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。When the depth of the token control leaky bucket reaches a standard token value, a standard token is issued to the congestion leaky bucket of the message transmission path, and the depth of the token control leaky bucket is subtracted from the standard token value. 2.根据权利要求1所述的管理方法,其特征在于,所述拥塞等级通过拥塞门限划分,N个拥塞门限划分出N+1个拥塞等级,每个拥塞等级对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小。2. The management method according to claim 1, wherein the congestion level is divided by a congestion threshold, and N congestion thresholds are divided into N+1 congestion levels, and each congestion level is correspondingly provided with a token added value, The higher the congestion level, the smaller the corresponding token addition value. 3.根据权利要求2所述的管理方法,其特征在于,该方法还包括:交换设备在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间。3. The management method according to claim 2, further comprising: after the switching device determines the congestion level of the congested leaky bucket, according to the depth change of the congested leaky bucket, when the congestion level of the congested leaky bucket drops to When the congestion level is next, wait for the first time, and update the congestion level when the first time is up; wherein, the first time is a random waiting time constructed through a random sequence. 4.根据权利要求3所述的管理方法,其特征在于,该方法还包括:在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;4. The management method according to claim 3, characterized in that the method further comprises: within the first time, if the congestion level of the congested leaky bucket rises to the original congestion level again, then stop waiting, and convert the congestion level of the first time counter clear; 如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为设置的固定时间。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is the fixed time set. 5.根据权利要求1所述的管理方法,其特征在于,该方法还包括:交换设备向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目,根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。5. The management method according to claim 1, further comprising: when the switching device issues a standard token to the congested leaky bucket of the message transmission path, detecting the number of effective links in the message transmission path, Select the corresponding token issuing rate according to the number of valid links, and issue standard tokens. 6.根据权利要求5所述的管理方法,其特征在于,当有效链路数目减少时,选择对应的速率低的令牌下发速率,当有效链路数目增多时,选择对应的速率高的令牌下发速率。6. The management method according to claim 5, characterized in that, when the number of effective links decreases, select the token issuing rate corresponding to a low rate, and select the token issuing rate corresponding to a high rate when the number of effective links increases. Token issuance rate. 7.一种拥塞流量的管理装置,其特征在于,该装置包括:等级确定模块、更新深度模块、令牌下发模块;其中,7. A management device for congested traffic, characterized in that the device comprises: a level determination module, an update depth module, and a token issuing module; wherein, 等级确定模块,用于根据报文传输路径的拥塞漏桶的深度,确定拥塞等级;A level determination module, configured to determine the congestion level according to the depth of the congestion leaky bucket of the message transmission path; 更新深度模块,用于根据所述拥塞等级对应的令牌添加值,更新令牌控制漏桶的深度;An update depth module is used to update the depth of the token control leaky bucket according to the token addition value corresponding to the congestion level; 令牌下发模块,用于当令牌控制漏桶的深度达到一个标准令牌价值时,向所述报文传输路径的拥塞漏桶下发一个标准令牌,并将令牌控制漏桶的深度减去标准令牌价值。A token issuing module, configured to issue a standard token to the congested leaky bucket of the message transmission path when the depth of the token control leaky bucket reaches a standard token value, and send the token control leaky bucket Depth minus standard token value. 8.根据权利要求7所述的管理装置,其特征在于,所述拥塞等级通过拥塞门限划分,N个拥塞门限划分出N+1个拥塞等级,每个拥塞等级对应设置一个令牌添加值,拥塞等级越高,对应的令牌添加值越小。8. The management device according to claim 7, wherein the congestion levels are divided by congestion thresholds, and N congestion thresholds are divided into N+1 congestion levels, and each congestion level is correspondingly provided with a token added value, The higher the congestion level, the smaller the corresponding token addition value. 9.根据权利要求8所述的管理装置,其特征在于,该装置还包括:等级更新模块,用于在确定拥塞漏桶的拥塞等级后,根据拥塞漏桶的深度变化,当拥塞漏桶的拥塞等级下降到下一拥塞等级时,等待第一时间,在第一时间到时,进行拥塞等级更新;其中,所述第一时间为通过随机序列构造的随机等待时间。9. The management device according to claim 8, characterized in that the device further comprises: a level updating module, configured to, after determining the congestion level of the congested leaky bucket, change the depth of the congested leaky bucket when the congested leaky bucket When the congestion level drops to the next congestion level, wait for a first time, and update the congestion level when the first time is up; wherein, the first time is a random waiting time constructed through a random sequence. 10.根据权利要求9所述的管理装置,其特征在于,所述等级更新模块,还用于在第一时间内,如果拥塞漏桶的拥塞等级又升到原拥塞等级,则停止等待,将第一时间的计数器清零;10. The management device according to claim 9, wherein the level update module is further configured to stop waiting if the congestion level of the congested leaky bucket rises to the original congestion level within the first time, The counter at the first time is cleared; 如果拥塞漏桶的拥塞等级又下降了多个等级,则在第一时间到时,按照第二时间为间隔,将拥塞等级一个等级一个等级地下降到拥塞漏桶的当前拥塞等级;所述第二时间为设置的固定时间。If the congestion level of the congested leaky bucket has dropped by multiple levels, when the first time is up, the congestion level will be reduced to the current congestion level of the congested leaky bucket level by level according to the second time interval; The second time is the fixed time set. 11.根据权利要求7所述的管理装置,其特征在于,该装置还包括:有效链路数目检测模块、速率选择模块;其中,11. The management device according to claim 7, further comprising: a valid link number detection module and a rate selection module; wherein, 有效链路数目检测模块,用于在向报文传输路径的拥塞漏桶下发标准令牌时,检测报文传输路径的有效链路数目;The effective link number detection module is used to detect the effective link number of the message transmission path when issuing a standard token to the congested leaky bucket of the message transmission path; 速率选择模块,用于根据所述有效链路数目选择对应的令牌下发速率,下发标准令牌。A rate selection module, configured to select a corresponding token issuing rate according to the number of valid links, and issue standard tokens.
CN201410816492.1A 2014-12-24 2014-12-24 Method and device for managing congested traffic Active CN105791155B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201410816492.1A CN105791155B (en) 2014-12-24 2014-12-24 Method and device for managing congested traffic
PCT/CN2015/080801 WO2016101549A1 (en) 2014-12-24 2015-06-04 Congestion flow management method, device and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410816492.1A CN105791155B (en) 2014-12-24 2014-12-24 Method and device for managing congested traffic

Publications (2)

Publication Number Publication Date
CN105791155A CN105791155A (en) 2016-07-20
CN105791155B true CN105791155B (en) 2019-08-06

Family

ID=56149114

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410816492.1A Active CN105791155B (en) 2014-12-24 2014-12-24 Method and device for managing congested traffic

Country Status (2)

Country Link
CN (1) CN105791155B (en)
WO (1) WO2016101549A1 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110365530A (en) * 2019-07-11 2019-10-22 电子科技大学 A network-independent test token-passing network
CN112737970B (en) * 2019-10-28 2024-06-14 华为技术有限公司 A data transmission method and related equipment
CN112825511A (en) * 2019-11-20 2021-05-21 深圳市中兴微电子技术有限公司 Switching network congestion management method, device, equipment and storage medium
CN112995058B (en) * 2019-12-13 2023-11-24 深圳市中兴微电子技术有限公司 Token adjusting method and device
CN112838991B (en) * 2021-02-09 2023-03-24 芯河半导体科技(无锡)有限公司 Method for adaptively adjusting token value of small-bandwidth scheduler

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1835447A (en) * 2005-03-16 2006-09-20 华为技术有限公司 Realizing method of data stream constraint control
CN101286947A (en) * 2008-05-30 2008-10-15 杭州华三通信技术有限公司 Data output control method and device
CN101360049A (en) * 2008-09-23 2009-02-04 福建星网锐捷网络有限公司 Packet forwarding method and apparatus

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3961000B2 (en) * 2005-05-26 2007-08-15 株式会社日立コミュニケーションテクノロジー Packet transfer apparatus and network system
CN100384156C (en) * 2006-03-24 2008-04-23 华为技术有限公司 Method and network device for multiplexing remaining bandwidth
US7965635B1 (en) * 2007-01-31 2011-06-21 Alcatel Lucent Per-class scheduling with rate limiting
US8000235B2 (en) * 2008-10-05 2011-08-16 Contextream Ltd. Bandwidth allocation method and apparatus
CN102710514B (en) * 2012-05-25 2015-01-21 华为技术有限公司 A packet flow control method and system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1835447A (en) * 2005-03-16 2006-09-20 华为技术有限公司 Realizing method of data stream constraint control
CN101286947A (en) * 2008-05-30 2008-10-15 杭州华三通信技术有限公司 Data output control method and device
CN101360049A (en) * 2008-09-23 2009-02-04 福建星网锐捷网络有限公司 Packet forwarding method and apparatus

Also Published As

Publication number Publication date
WO2016101549A1 (en) 2016-06-30
CN105791155A (en) 2016-07-20

Similar Documents

Publication Publication Date Title
CN105791155B (en) Method and device for managing congested traffic
CN109889547B (en) Abnormal network equipment detection method and device
US9860147B2 (en) Method and device for generating CNM
EP2466824B1 (en) Service scheduling method and device
WO2015149488A1 (en) Method and apparatus for limiting rate by means of token bucket, and computer storage medium
CN101997766A (en) Method and system for limiting speed of token bucket based on priority
CN103701721B (en) Message transmitting method and device
US9298660B2 (en) Super speed USB hub and traffic management method thereof
RU2014148333A (en) METHODS FOR ADAPTIVE CONTROLLED LIGHTING BASED ON TRANSPORT FLOW IN EXTERIOR LIGHTING NETWORKS
US9712580B2 (en) Pipelining for parallel network connections to transmit a digital content stream
CN105207908B (en) A kind of message processing method and system
US12079201B2 (en) Blockchain-based data storage method, related device and storage medium
CN111107016B (en) A network congestion control method, device, chip and storage medium
US9369477B2 (en) Mitigation of path-based convergence attacks
WO2017045229A1 (en) Method for processing traffic data of base station, and base station
US9860122B2 (en) Systems and methods for dynamic adaptive machine
KR20210066432A (en) Method for detecting and mitigating interest flooding attack through collaboration between edge routers in Named Data Networking(NDN)
KR20230156262A (en) System and method for machine learning based malware detection
US11646971B2 (en) Limiting backpressure with bad actors
CN106817364B (en) Brute force cracking detection method and device
CN112995060B (en) Flow control method based on hardware counter
EP3079314A1 (en) Method to manage resources, system and computer-readable medium
US7830873B1 (en) Implementation of distributed traffic rate limiters
RU2568784C1 (en) Method of controlling data streams in distributed information systems
CN105959300B (en) A kind of method and device of ddos attack protection

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant