CN108833291B - Weighted random early detection method applied to exchange circuit - Google Patents

Weighted random early detection method applied to exchange circuit Download PDF

Info

Publication number
CN108833291B
CN108833291B CN201810349208.2A CN201810349208A CN108833291B CN 108833291 B CN108833291 B CN 108833291B CN 201810349208 A CN201810349208 A CN 201810349208A CN 108833291 B CN108833291 B CN 108833291B
Authority
CN
China
Prior art keywords
avgq
probability
max
packet loss
queue length
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
CN201810349208.2A
Other languages
Chinese (zh)
Other versions
CN108833291A (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.)
CETC 32 Research Institute
Original Assignee
CETC 32 Research Institute
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 CETC 32 Research Institute filed Critical CETC 32 Research Institute
Priority to CN201810349208.2A priority Critical patent/CN108833291B/en
Publication of CN108833291A publication Critical patent/CN108833291A/en
Application granted granted Critical
Publication of CN108833291B publication Critical patent/CN108833291B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/12Avoiding congestion; Recovering from congestion
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/12Avoiding congestion; Recovering from congestion
    • H04L47/127Avoiding congestion; Recovering from congestion by using congestion prediction
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/24Traffic characterised by specific attributes, e.g. priority or QoS
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/32Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/32Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames
    • H04L47/326Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames with random discard, e.g. random early discard [RED]

Landscapes

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

Abstract

The invention provides a weighted random early detection method applied to a switching circuit, which avoids the occurrence of link congestion by setting a threshold value to carry out pre-discarding in advance. The invention calculates the segment packet loss probability through the average queue length, the highest drop threshold and the lowest drop threshold, then expands the packet loss probability by 1024 times, compares the packet loss probability with a randomly generated 1024-bit pseudo random number value, and confirms whether the data packet is dropped or not, thus the data packet is dropped to become a random event, the results are different according to the packet size and the current link congestion conditions, the phenomenon of one-time mass packet loss after congestion is avoided, and the utilization rate of the link can be effectively maintained.

Description

Weighted random early detection method applied to exchange circuit
Technical Field
The invention relates to the technical field of digital communication, in particular to a weighted random early detection method applied to a switching circuit, which is mainly used for network nodes to carry out active queue management.
Background
Queue management is a research hotspot of end-to-end congestion control, and can improve congestion control and network quality of service (QoS) by optimizing a queue management algorithm based on a router technology.
The weighted Random Early detection algorithm wred (weighted Random Early detection) can effectively control the queue congestion according to different service priorities at the Early stage of the queue congestion. The algorithm calculates the length of each queue through average statistics, and then based on the average statistics, the queue manager performs packet loss with a certain probability by referring to WRED parameters, so that the problem of queue congestion is solved.
Disclosure of Invention
The technical problem to be solved by the invention is to research a WRED method supporting 1024 bits, and maintain the non-congestion state of a link by detecting the upcoming congestion condition and preemptively discarding data packets. The WRED avoids the phenomenon of one-time massive packet loss after congestion by selectively losing packets in advance rather than losing packets until the buffer is full, and can effectively maintain the utilization rate of the link.
The invention is realized according to the following technical scheme:
a weighted random early detection method applied in a switch circuit, comprising the steps of:
step S1: dividing the descriptors into different drop priorities according to the pre-coloring state of the input descriptors, and providing the data packets with different colors by adopting a plurality of threshold parameters and drop probability parameters, wherein each group of parameters comprises a weight W of an average queue lengthq
Step S2: the average queue length of the buffer queue is calculated, and every 4us of sampling time is set, and the calculation formula is as follows:
avgQnew=(1-Wq)*avgQOld age+q*Wq
Wherein WqAs a weight, Wq=2-weightQ is the current queue length during sampling measurement, avgQ is initially 0, and avgQNew=avgQOld age+ q value avgQ after right shift of weight bit high order without complementing 0Old ageRight shifting the value of the high bit of weight without complementing 0;
step S3, calculating the packet loss probability according to the following formula:
Figure GDA0003501851090000021
avgQ refers to the average queue length; pbTo the probability of packet loss, maxpTo maximum discard probability, minthFor minimum discard queue Length, maxthIs the maximum discard queue length.
Discard rate from minth0% to maxthMax ofpIncrease by 8 uniform steps, will (max) in computationth-minth) Is left shifted by 3 bits to one step delta and then determined (avgQ-min)th) If it is determined which step length of the 8 uniform step lengths the value of (A) is, P is the nth sectionbThe value is maxp*n/8;
Step S4: expanding a discarding probability table according to the set discarding probability, wherein each random discarding time, the system generates a random distribution of pseudo-random numbers u, u e (1, 800), when P isbWhen 800 > u, discarding the packet, otherwise, entering an egress descriptor queue;
considering that a pseudo-random number needs to be generated in the calculation process, a 1024-bit pseudo-random number is generated, and max is used for facilitating comparisonpAmplifying 1024 times for rounding, and performing shift operation according to 2 times during calculation;
step S5: the calculation formula of the probability P of the router to mark the arriving data packet is as follows:
P=Pb/(1-count*Pb)
the count represents the number of packets entering the queue from the last packet loss, the final marking probability P is a function of the average queue length avgQ and the count, and P slowly increases along with the count, so that continuous packet loss is avoided, and the discarded data packets can be uniformly distributed.
Compared with the prior art, the invention has the following beneficial effects:
the method effectively finishes the process of random discarding by generating 1024-bit pseudo-random numbers and comparing the discarded probability of the data packet which is amplified by 1024 times, and the discarded data packet is random rather than fixed, so that the completeness of data transmission is not influenced to a great extent, and the fairness in the process of data packet transmission is also maintained;
the invention carries out active queue management in the network transmission link and carries out random discarding on the data frame by the WRED algorithm before the congestion is generated, thereby solving the problem of link congestion and effectively improving the transmission efficiency.
Drawings
Other features, objects and advantages of the invention will become more apparent upon reading of the detailed description of non-limiting embodiments with reference to the following drawings:
fig. 1 is a schematic diagram of packet loss probability;
FIG. 2 is a flow chart of the WRED method structure of the present invention.
Detailed Description
The present invention will be described in detail with reference to specific examples. The following examples will assist those skilled in the art in further understanding the invention, but are not intended to limit the invention in any way. It should be noted that it would be obvious to those skilled in the art that various changes and modifications can be made without departing from the spirit of the invention. All falling within the scope of the present invention.
The invention relates to a weighted random early detection method applied to a switching circuit, which comprises the following steps:
step S1: dividing the descriptors into different drop priorities according to the pre-coloring state of the input descriptors, and providing the data packets with different colors by adopting a plurality of threshold parameters and drop probability parameters, wherein each group of parameters comprises a weight W of an average queue lengthq
Step S2: the average queue length of the buffer queue is calculated, and every 4us of sampling time is set, and the calculation formula is as follows:
avgQnew=(1-Wq)*avgQOld age+q*Wq
Wherein WqAs a weight, Wq=2-weightQ is the current queue length during sampling measurement, avgQ is initially 0, and avgQNew=avgQOld age+ q value avgQ after right shift of weight bit high order without complementing 0Old ageRight shifting the value of the high bit of weight without complementing 0;
step S3, calculating the packet loss probability according to the following formula as shown in fig. 1:
Figure GDA0003501851090000031
avgQ refers to the average queue length; pbTo the probability of packet loss, maxpTo maximum discard probability, minthFor minimum discard queue Length, maxthIs the maximum discard queue length;
discard rate from minth0% to maxthMax ofpIncrease by 8 uniform steps, will (max) in computationth-minth) Is left shifted by 3 bits to one step delta and then determined (avgQ-min)th) If it is determined which step length of the 8 uniform step lengths the value of (A) is, P is the nth sectionbThe value is maxp*n/8;
Step S4: root of herbaceous plantExpanding a discarding probability table according to the set discarding probability, wherein the system generates a random distribution of pseudo-random numbers u, u e (1, 800) when each random packet is discarded, and when P isbWhen 800 > u, discarding the packet, otherwise, entering an egress descriptor queue;
considering that a pseudo-random number needs to be generated in the calculation process, a 1024-bit pseudo-random number is generated, and max is used for facilitating comparisonpAmplifying 1024 times for rounding, and performing shift operation according to 2 times during calculation;
the specific discard probability table is as follows.
maxpThe amplification is 800 times, and the amplification is divided into eight sections, which are specifically shown in the table I:
table one maxpP after 800 times enlargementb
Figure GDA0003501851090000032
Figure GDA0003501851090000041
maxpExpand 1024 times, divide into eight segments, round off, as shown in table two:
TABLE II maxpP after 1024 times enlargementb
Figure GDA0003501851090000042
Step S5: the calculation formula of the probability P of the router to mark the arriving data packet is as follows:
P=Pb/(1-count*Pb)
the count represents the number of packets entering the queue from the last packet loss, the final marking probability P is a function of the average queue length avgQ and the count, and P slowly increases along with the count, so that continuous packet loss is avoided, and the discarded data packets can be uniformly distributed.
During the design process of the invention, the requirementsGenerating 1024-bit pseudo-random numbers to sum PbIn the algorithm for generating pseudo random numbers, a mode of progressively shifting from a low bit to a high bit is adopted. Firstly, setting a default initial value to be zero, then generating a pseudo random number, carrying out left shift on the digit, and filling the lower digit with the newly generated pseudo random number to ensure that each digit is a randomly generated numerical value.
The descriptor pre-coloring module can be nested in an active queue management module, descriptor pre-coloring is carried out through a color marking process of an enqueue descriptor in the early stage, then the descriptor is transmitted to a WRED module to be randomly discarded, different pre-colored descriptors have different discarding thresholds, and the discarding conditions of the descriptors can be reasonably distinguished. The WRED method structure flow chart of the invention is shown in FIG. 2.
The foregoing description of specific embodiments of the present invention has been presented. It is to be understood that the present invention is not limited to the specific embodiments described above, and that various changes or modifications may be made by one skilled in the art within the scope of the appended claims without departing from the spirit of the invention. The embodiments and features of the embodiments of the present application may be combined with each other arbitrarily without conflict.

Claims (1)

1. A weighted random early detection method applied in a switch circuit, comprising the steps of:
step S1: dividing the descriptors into different drop priorities according to the pre-coloring state of the input descriptors, and providing the data packets with different colors by adopting a plurality of threshold parameters and drop probability parameters, wherein each group of parameters comprises a weight W of an average queue lengthq
Step S2: the average queue length of the buffer queue is calculated, and every 4us of sampling time is set, and the calculation formula is as follows:
avgQnew=(1-Wq)*avgQOld age+q*Wq
WqAs a weight, Wq=2-weightQ is the current queue length at the time of the sampling measurement, avgQ is initially 0,
avgQnew=avgQOld age+ q right shift wevalue-avgQ after 0 is not complemented for high order bitsOld ageRight shift the value of the high bit of weight without complementing 0,
step S3, calculating the packet loss probability according to the following formula:
Figure FDA0003501851080000011
avgQ refers to the average queue length; pbTo the probability of packet loss, maxpTo maximum discard probability, minthFor minimum discard queue Length, maxthIs the maximum discard queue length;
discard rate from minth0% to maxthMax ofpIncrease by 8 uniform steps, will (max) in computationth-minth) Is left shifted by 3 bits to a uniform step delta and then determined (avgQ-min)th) If it is determined which step length of the 8 uniform step lengths the value of (A) is, P is the nth sectionbThe value is maxp*n/8;
Step S4: expanding a discarding probability table according to the set discarding probability, wherein each random discarding time, the system generates a random distribution of pseudo-random numbers u, u e (1, 800), when P isbWhen 800 > u, discarding the packet, otherwise, entering an egress descriptor queue;
considering that a pseudo-random number needs to be generated in the calculation process, a 1024-bit pseudo-random number is generated, and max is used for facilitating comparisonpAmplifying 1024 times for rounding, and performing shift operation according to 2 times during calculation;
step S5: the calculation formula of the probability P of the router to mark the arriving data packet is as follows:
P=Pb/(1-count*Pb)
the count represents the number of packets entering the queue from the last packet loss, the final marking probability P is a function of the average queue length avgQ and the count, and P slowly increases along with the count, so that continuous packet loss is avoided, and the discarded data packets can be uniformly distributed.
CN201810349208.2A 2018-04-18 2018-04-18 Weighted random early detection method applied to exchange circuit Active CN108833291B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810349208.2A CN108833291B (en) 2018-04-18 2018-04-18 Weighted random early detection method applied to exchange circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810349208.2A CN108833291B (en) 2018-04-18 2018-04-18 Weighted random early detection method applied to exchange circuit

Publications (2)

Publication Number Publication Date
CN108833291A CN108833291A (en) 2018-11-16
CN108833291B true CN108833291B (en) 2022-04-01

Family

ID=64154738

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810349208.2A Active CN108833291B (en) 2018-04-18 2018-04-18 Weighted random early detection method applied to exchange circuit

Country Status (1)

Country Link
CN (1) CN108833291B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101094188A (en) * 2007-07-16 2007-12-26 中兴通讯股份有限公司 Random test device in advance, and hardware implementation method
CN101562566A (en) * 2009-06-04 2009-10-21 吉林大学 Active queue management method based on real-time router cache occupancy rate

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6856596B2 (en) * 2000-12-01 2005-02-15 Marconi Communications, Inc. Approximation of the weighted random early detection buffer admittance algorithm

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101094188A (en) * 2007-07-16 2007-12-26 中兴通讯股份有限公司 Random test device in advance, and hardware implementation method
CN101562566A (en) * 2009-06-04 2009-10-21 吉林大学 Active queue management method based on real-time router cache occupancy rate

Also Published As

Publication number Publication date
CN108833291A (en) 2018-11-16

Similar Documents

Publication Publication Date Title
US8654645B2 (en) Systems and methods for dropping data using a drop profile
US8913541B2 (en) Dequeuing and congestion control systems and methods for single stream multicast
US8072998B2 (en) Systems and methods for congestion control using random early drop at head of buffer
US7885281B2 (en) Systems and methods for determining the bandwidth used by a queue
US8125902B2 (en) Method and system for congestion avoidance in packet switching devices
US20070195820A1 (en) System and Method for Adaptive Frame Size Management in a Wireless Multihop Network
CN103929372B (en) Active queue management method and apparatus
JP5141570B2 (en) Wireless communication device for wireless ad hoc network
Zhai et al. Performance of wireless LANs based on IEEE 802.11 MAC protocols
KR20090107031A (en) Method of congestion management in a wireless mesh network
JP2002223240A (en) Method for approximating weighted random early detection buffer admittance algorithm
CN108833291B (en) Weighted random early detection method applied to exchange circuit
CN107070695B (en) Bus type network load self-adaptive communication method
JPH02170645A (en) System and equipment for packet transmission
Hassan et al. Modified backoff technique in fiber-wireless networks
Jaykumar et al. Packet Transmission in MANET using Dynamic Queue Management Scheme
US8797852B2 (en) Dynamical bandwidth adjustment of a link in a data network
Mokdad et al. On the applicability of SAN in modeling and analyzing a Priority Queue Management based congestion control for WMSNs
Yang et al. Research on delay and packet loss control mechanism in wireless mesh networks
Ghalehnoie et al. Fuzzy rate control in wireless sensor networks for mitigating congestion
Tagami et al. A Study of a Probabilistic Routing Method Based on Packet Transmission Capacity
Halim et al. Performance Analysis of Throughput and Queuing Delay for Multiple Optical Channels for Local Area Network
US20050060424A1 (en) Congestion management in telecommunications networks
CN115622922A (en) Method, system and storage medium for processing large-flow protocol message
Chaitou et al. Modelling multi-channel optical slotted rings with fixed transmitter and fixed receivers

Legal Events

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