109 113


Published on

Published in: Technology
  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

109 113

  1. 1. ISSN: 2277 – 9043 International Journal of Advanced Research in Computer Science and Electronics Engineering Volume 1, Issue 5, July 2012 Performance analysis of networks using RED for congestion control Ms. Banshri Raichana and Mrs. Sangeeta Kulkarni RED monitors the average queue size and marks Abstract— Congestion avoidance techniques packets. If the buffer is almost empty, all incomingmonitor network traffic load in an effort to packets are accepted. As the queue grows, theanticipate and avoid congestion at common probability for dropping an incoming packet growsnetwork bottlenecks. Congestion avoidance is too. When the buffer is full, the probability hasachieved through packet dropping. Among the reached 1 and all incoming packets are dropped. Thusmore commonly used congestion avoidance RED buffer mechanism with constant bit rate trafficmechanisms is Random Early Detection (RED), can be used at an initial stage to understand thewhich is optimum for high-speed transit networks. effect of change of network parameters over systemRandom early detection (RED) is an active queue performance.management algorithm. It not only detects but RED aims to control the average queue size byalso avoids congestion by randomly dropping indicating to the end hosts when they shouldpackets to notify congestion. The main objective of temporarily slow down transmission of packets.this paper is to comprehend the working of RED RED takes advantage of the congestion controlalgorithm and to learn the effects of variation of mechanism of TCP by randomly dropping packetsRED parameters. To improve the performance of prior to periods of high congestion, RED tells thea network in terms of drop count, efficiency, packet source to decrease its transmission rate.throughput and delay we can optimize our choice Assuming the packet source is using TCP, it willof these RED parameters. decrease its transmission rate until all the packets Index Term - Congestion, Delay, Drop count, RED, reach their destination, indicating that the congestionRED parameters, Throughput, is cleared. I. INTRODUCTION The network designing and simulation here is accomplished using NS2 (network simulator versionCongestion occurs when the resource demands 2). NS2 is an event-driven network simulatorexceed the network capacity. At some point of time embedded into the Tool Command Language (Tcl).network buffers go full and packets are dropped. An extensible simulation engine which isDuring congestion, the network throughput drops implemented in C++ and is configured and controlledwhereas end to end delay increases. In order to via a Tcl interface. A network topology is defined,overcome this situation a congestion avoidance traffic sources and sinks are configured, statistics arescheme must be employed. One such method is collected, and then simulation is invoked using theRandom Early Detection (RED). ns command.Random early detection (RED) is an active queue In general, C++ is used for implementing protocolsmanagement algorithm. It is also a congestion and extending the ns-2 library. OTcl is used to createavoidance algorithm. In the conventional tail drop and control the simulation environment and also foralgorithm, a router or other network component selection of output data. Simulation is run at thebuffers as many packets as it can, and simply drops packet level, allowing visualization of detailedthe ones it cannot buffer. If buffers are constantly results.full, the network is congested. Tail drop distributesbuffer space unfairly among traffic flows. Tail drop The network can be designed to implementcan also lead to TCP global synchronization as all bottleneck and packet drop scenario. Using theTCP connections "hold back" simultaneously, and available tools of NS2 we can implement the networkthen "step forward" simultaneously. Networks congestion avoidance algorithm Random Earlybecome under-utilized and flooded by turns. RED Detection (RED), then by varying the REDaddresses these issues. parameters discussed in section II we can observe the effect on network performance. 109 All Rights Reserved © 2012 IJARCSEE
  2. 2. ISSN: 2277 – 9043 International Journal of Advanced Research in Computer Science and Electronics Engineering Volume 1, Issue 5, July 2012 II. DESIGNING THE NETWORK wq the queue weight factor which is used in computing the average queue size. maxp theThere are four basic steps to design and simulate any maximum dropping probability.network. First step is to develop a model(implementation of a protocol); second step is to The RED parameters set in our simulation werecreate a simulation scenario (designing a network minimum threshold to5 maximum threshold to 15topology and traffic scenario); third step is to choose maxp to 0.02 wq to 0.001 and queue size of 35.and collect statistics through simulation, and finallyfourth step is to visualize simulation and analyze III. RANDOM EARLY DETECTION ALGORITHMsimulation results using awk scripting language. The most distinct factor of RED is that it does not As shown in Fig.1, a network with four nodes operate on instantaneous queue size its functioning is(Node0, Node1, Node2, Node3) has been designed. based on average queue size. When a packet arrivesNode 0 and Node1 are sources with FTP aggents at the RED gateway it calculates the average queueattached over TCP. Node 3 is the sink for both the size, using a low-pass filter with an exponentialsource nodes. A link with appropriate link type, link weighted moving average which is given by:capcity, buffer mechanism is to be defined betweenthese nodes. In this network, a bottleneck between avg = avg + wq(q-avg)node2 and node3 is defined with RED as the buffermangement scheme so that we can simulate packet The average queue size is compared to twoloss and measure overall network perfomance, while thresholds, a minimum threshold and a maximumlink between node0 and node2 and between node1 threshold. When the average queue size is less thanand node2 would have be droptail mechnaism. The the minimum threshold, no packets are marked theysimulation time is kept large enough to demonstrate are enqued into the buffer. When the average queuecongestion behaviour. size is greater than the maximum threshold, every arriving packet is marked and discarded. If marked packets are in fact dropped, or if all source nodes are cooperative, this ensures that ensures that the average queue size does not significantly exceed the maximum threshold. When the average queue size is between minimum threshold and maximum threshold, each arriving packet is marked with the probability which is a function of average queue size avg. The initial packet-marking probability pb is given as: pb = C1avg - C2 C1 = maxp maxth-minth C1 = maxp* minth maxth-minth The parameters like minth and maxth are user Fig1. Network simulation window in NS2 defined in the tcl file. While maxp and wq are constants which can be defined in tcl or their default In order to perfectly understand the RED algorithm values are taken from ns-default.tcl. After calculatingwe must be introduced to the basic RED parameters the packet drop probability, the RED gateways use The minimum queue threshold minth below which no randomization in choosing which arriving packets topackets are dropped, maximum queue threshold mark with this method, the probability of marking amaxth above which all incoming packets are dropped,, packet from a particular connection is roughly proportional to that connection’s share of the 110 All Rights Reserved © 2012 IJARCSEE
  3. 3. ISSN: 2277 – 9043 International Journal of Advanced Research in Computer Science and Electronics Engineering Volume 1, Issue 5, July 2012bandwidth through the gateway. In order to do A low minimum threshold achieves high efficiency.analysis awk files for delay and efficiency have been But a very low minimum threshold would result indesigned to calculate the same and verify the drop under utilization of link and buffer so one mustcount to measure the performance of the network. appropriately choose minth IV. RED PARAMETER ANALYSIS Analysis by varying Maximum ThresholdSignficance of maxp and wq If we vary the maximum threshold of the bottleneckPacket marking probability is a linear function of the link buffer from 16 to 30 we see that the efficiencyaverage queue size. RED gateways perform best when increases in steps, while doing so the otherthe packet marking probability changes fairly slowly parameters of RED are kept constant.as the average queue size changes. If maxp is set to1/50 then when average queue size is halfwaybetween minth and maxth the gateway drops on anaverage one out of fifty arriving packets.The weight wq determines the time constant of lowpass filter The calculation of the average queue sizecan be implemented particularly efficiently when wqis a negative power of two.Analysis by varying Minimum ThresholdIn the network link between the nodes 2 and 3 isdesigned with bottleneck and the queuing mechanismis RED and when minimum threshold of this buffer ischanged from 1 to 14 keeping other parametersmentioned in section II constant we observe thatefficiency goes on reducing as the number of droppedpackets goes on increasing. Fig 3 Maximum threshold v/s Efficiecny Thus we observe from the graph above that higher the maximum threshold better is the efficiency so we must choose a very high maximum threshold. But while doing so if we choose a value that approaches instantaneous queue size RED gets much shorter period to notify congestion to sources and congestion can still occur. Thus Minimum threshold should be low but should also maintain link utilization. Max threshold should be sufficiently high but should allow early detection and congestion notification. The optimal values for minth and maxth depend on the desired average queue size. If the typical traffic is fairly bursty, then minth must be correspondingly large to allow the link Fig 2 Minimum threshold v/s Efficiecny utilization to be maintained at an acceptably high 111 All Rights Reserved © 2012 IJARCSEE
  4. 4. ISSN: 2277 – 9043 International Journal of Advanced Research in Computer Science and Electronics Engineering Volume 1, Issue 5, July 2012level. The optimal value for maxth depends on themaximum average delay that can be accepted by thenetwork. Maximum threshold should be at least twicethe minimum threshold. For a queue size of upto 50min and max threshold values opted are 5 and 15.Queue Size VariationFor this set of analysis all the RED parameters werekept constant and queue size was varied. When thequeue size grows it was observed as shown in Fig. 4that the efficiency too grows but at the same time itwas observed as shown in Fig. 5 that the end to enddelay also increases. This increase in average delay isan undesired phenomena thus there should be atradeoff between maximizing throughput andminimizing delay. Fig 5 Queue Size v/s Delay V. CONCLUSION The greatest advantage of RED is instead of using instantaneous queue length RED gateway uses average queue size short term increase in the queue size that result from bursty traffic or from transient congestion do not result in a significant increase in the average queue size. The only maybe drawback of RED would be it completely relies upon a TCP based networks since it expects co-operation from the sources to reduce their transmission rate when congestion occurs which would be possible only through TCPs window mechanism. For RED to function efficiently it is very essential to choose optimum values for maximum threshold and minimum threshold although these depend on average queue size and the accepted level of delay. The gateway marks the packets at fairly evenly spaced intervals, in order to avoid biases and avoid global synchronization, and to mark packets Fig 4 Queue Size v/s Efficiecny sufficiently frequently to control the average queue size.RED gateways can control the average queue sizewhile accommodating transient congestion, RED VI. REFERNCESgateways are well suited to provide high throughputand low average delay in high speed networks with [1] Introduction to Network Simulator NS2,TCP connection that have large window sizes. Springer Science + Business Media, LLC, 2009 [2] The ns Manual (formerly ns Notes and Documentation), The VINIT project, May 2010. 112 All Rights Reserved © 2012 IJARCSEE
  5. 5. ISSN: 2277 – 9043 International Journal of Advanced Research in Computer Science and Electronics Engineering Volume 1, Issue 5, July 2012[3] NS Simulators for beginners, Lecture notes 2003-2004, Etian Altaman.[4] Floyd, S., and Jacobson, V., Random Early Detection gateways for Congestion Avoidance V.1 N.4, August 1993.[5] A study of TCP RED congestion control using RED, Arjit Ganguly, Pasi Lassila, July 2001.[6] Throughput http://en.wikipedia.org/wiki/Throughput[7] Packet and network delay http://en.wikipedia.org/wiki/Network_delay[8] AWK http://en.wikipedia.org/wiki/AWK 113 All Rights Reserved © 2012 IJARCSEE