CN Unit-2 Congestion, SCTP, Qos

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 40

CONGESTION CONTROL

• Congestion in a network may occur if the load on the network (number of


packets sent to the network) is greater than the capacity of the network
(number of packets a network can handle).
• Congestion control refers to the mechanisms and techniques to control
the congestion and keep the load below the capacity.
CONGESTION CONTROL
Techniques and mechanisms that can either prevent congestion before it
happens or remove congestion after it has happened.
Congestion control mechanisms into two broad categories:
•Open-loop congestion control (Prevention)
•Closed-loop congestion control (Removal)
Open-Loop Congestion Control

• Congestion Control policies are applied to prevent congestion


before it happens. In these mechanisms, congestion control is
handled by either the source or the destination.
Policies that can prevent congestion:
• Retransmission Policy
• Window Policy
• Acknowledgment Policy
• Discarding Policy
• Admission Policy
Policies that can prevent congestion
•Retransmission Policy If the sender feels that a sent packet is lost or corrupted, the
packet needs to be retransmitted.
•Window Policy The type of window at the sender may also affect congestion. The
Selective Repeat window is better than the Go-Back-N window for congestion
control.
•Acknowledgment Policy he acknowledgment policy imposed by the receiver may
also affect congestion. If the receiver does not acknowledge every packet it
receives, it may slow down the sender and help prevent congestion
•Discarding Policy A good discarding policy by the routers may prevent
congestion and at the same time may not harm the integrity of the transmission
•Admission Policy An admission policy can prevent congestion in virtual-circuit
networks. A router can deny establishing a virtual-circuit connection if there is
congestion in the network or if there is a possibility of future congestion.
Closed-Loop Congestion Control

• Closed-loop congestion control mechanisms try to remove the


congestion after it happens.
List of policies that can avoid congestion are
• Backpressure
• Choke Packet
• Implicit Signaling
• Explicit Signaling
Closed-Loop Congestion Control

Backpressure
•Backpressure is a node to-node congestion control that starts with a node and
propagates, in the opposite direction of data flow, to the source
•It is a congestion control mechanism in which a congested node stops receiving
data from the immediate upstream node or nodes. This may cause the upstream
node or nodes to become congested, and they, in turn, reject data from their
upstream node or nodes, and so on.

Figure Backpressure method for alleviating congestion


Closed-Loop Congestion Control
Choke packet
• A choke packet is a packet sent by a congested node to source to inform
congestion.
• In backpressure, the warning is from one node to its upstream node, although the
warning may eventually reach the source station.
• In the choke-packet method, the warning is from the router, which has encountered
congestion, directly to the source station. The intermediate nodes through which
the packet has traveled are not warned.

24.7
Closed-Loop Congestion Control
• Implicit Signaling
In this, there is no communication between congested node or nodes and the
source. The source guesses that there is congestion somewhere in the
network from other symptoms.
• Explicit Signaling
The node that experiences congestion can explicitly send a signal to the
source or destination. Explicit signaling can occur in either the forward or
the backward direction.
Explicit-signaling method is different from the choke-packet method.
 In choke-packet, a separate packet is used for this purpose
 In explicit-signaling method, signal is included in packets that carry data.
Congestion Avoidance

Frame Relay Protocol uses two bits in the frame to explicity warn the
source and destination of the presence of congestion
•BECN – Backward Explicit Congestion Notification
•FECN - Forward Explicit Congestion Notification
BECN bit warns the sender of congestion in the network.
FECN bit is used to warn the receiver of congestion in the network.
BECN – Backward Explicit Congestion Notification

FECN – Forward Explicit Congestion Notification


Four cases of congestion
Slow start, exponential increase

In the slow-start algorithm, the size of the congestion


window increases exponentially until it reaches a threshold.
Congestion avoidance, additive increase

In the congestion avoidance algorithm, the size of the


congestion window increases additively until
congestion is detected.
CONGESTION AVOIDANCE - DECBIT TECHNIQUE

 DECbit means Destination Experiencing Congestion Bit


 DECbit is Congestion avoidance Technique Developed for the
Digital Network Architecture
 DECbit is a TCP congestion control technique implemented in
routers to avoid congestion
 In DECbit scheme, each router is programmed to monitor its own
queue length, and when it detects congestion, it notify the source to
adjust its congestion window.
 Decbit explicitly sending a congestion notification message to the
source
Congestion avoidance - DECbit Technique

 Each router monitors its load and explicitly notifies the end nodes when
congestion is about to occur. This notification is implemented by setting
a binary congestion bit in the packets that flow through the router, hence
the name DECbit.
 Destination host then copies this congestion bit into ACK it sends back to
source. Finally, source adjusts its sending rate to avoid congestion.
 A single congestion bit is added to the packet header. A router sets this
bit in a packet if its average queue length is greater than or equal to 1 at
the time the packet arrives.
Congestion avoidance - DECbit Technique

The average queue length is measured over a time interval that


spans the last busy+idle cycle, plus the current busy cycle.

Figure shows the queue length at a router as a function of time.


CONGESTION AVOIDANCE-RANDOM EARLY DETECTION (RED)

 RED called Random Early Detection (RED)


 RED is similar to the DECbit scheme in that each router is programmed to
monitor its own queue length, and when it detects that congestion, it notify
the source to adjust its congestion window.
 RED implicitly notifies the source of congestion by dropping one of its
packets. The source is, therefore, effectively notified by the subsequent
timeout or duplicate ACK
 RED decides when to drop a packet and what packet it decides to drop
 RED algorithm defines the details of how to monitor the queue length and
when to drop a packet.
Congestion avoidance - Random Early Detection (RED)

RED differs from the DECbit scheme in two major ways.


 The first is that rather than explicitly sending a congestion
notification message to the source, RED is most commonly
implemented such that it implicitly notifies the source of
congestion by dropping one of its packets. The source is, therefore,
effectively notified by the subsequent timeout or duplicate AC
 The second difference between RED and DECbit is in the details
of how RED decides when to drop a packet and what packet it
decides to drop.
Congestion avoidance - Random Early Detection (RED)

 RED differs from the DECbit scheme: DECbit scheme explicitly


sending a congestion notification message to the source, RED
implicitly notifies the source of congestion by dropping one of its
packets. The source is notified by the subsequent timeout or duplicate
ACK. Therefore, RED detects congestion by means of timeouts
SCTP - STREAM CONTROL TRANSMISSION PROTOCOL

Stream Control Transmission Protocol is a new reliable, message-


oriented transport layer protocol. SCTP provides a more sophisticated
service than TCP can provide.
SCTP Services and Features
• Message-oriented transport layer protocol
• Better protocol for multimedia communication
• Process to Process Communication & Full-Duplex Communication
• Multihoming service
• SCTP is a connection-oriented protocol - a connection is called an association.
• Reliable Service - SCTP is a reliable transport protocol. It uses an
acknowledgment mechanism to check the safe and sound arrival of data
SCTP is a message-oriented, reliable protocol that combines the best
features of UDP and TCP.
Multiple-stream

A connection in SCTP is called an association.


An association in SCTP can involve multiple streams.
Multihoming

An SCTP association supports multihoming service. The sending and receiving

host can define multiple IP addresses in each end for an association

SCTP association allows multiple IP addresses for


each end.
Features of SCTP

In SCTP, a data chunk is numbered using Transmission


Sequence Number (TSN)

Transmission Sequence Number (TSN) is used to distinguish


between different streams

Stream Sequence Number (SSN) is used to distinguish between


different data chunks belonging to same stream

TCP has segments; SCTP has packets


Comparison between a TCP segment and an SCTP packet

In SCTP, control information and data information are


carried in separate chunks.
Packet, data chunks, and streams

Data chunks are identified by three items:


TSN, SI, and SSN.
TSN is a cumulative number identifying the association;
SI defines the stream;
SSN defines the chunk in a stream.

Acknowledgment numbers are used to acknowledge only data chunks


SCTP packet format

SCTP packet has a mandatory general header and a set of blocks called
chunks. There are two types of chunks:
•control chunks - A control chunk controls and maintains association
•data chunks - A data chunk carries user data

In an SCTP packet, control chunks come before data chunks


SCTP Packet header

There are four fields in the general header.


•Source and Destination port numbers
•Verification tag is a 32-bit field that matches a packet to an association. This
prevents a packet from a previous association from being mistaken as a packet
in this association.
•Checksum- Checksum size is increased from 16 bits (UDP,TCP,IP) to 32 bits
Table: Types of Chunks
Four-way handshaking

In SCTP, only DATA chunks consume TSNs;


DATA chunks are the only chunks that are acknowledged.
Simple data transfer

Acknowledgment
in SCTP defines
the cumulative
TSN, the TSN of
the last data
chunk received in
order.
Association termination
QUALITY OF SERVICE
 Quality of service (QoS) is an internetworking issue,
 Quality of service (QoS) is defined as a flow seeks to attain

Flow Characteristics
Delay - Source-to-destination delay

Reliability - Lack of reliability means losing a packet or acknowledgment

Jitter - Jitter is the variation in delay for packets belonging to same flow.

Bandwidth - maximum possible amount of data transfer between two points of

a network in a specific time


TECHNIQUES TO IMPROVE QoS

Techniques that can be used to improve the quality of


service:
•Scheduling,
•Traffic Shaping,
•Admission Control and
•Resource Reservation.
TECHNIQUES TO IMPROVE QoS

Scheduling
A good scheduling technique treats the different flows in a fair and
appropriate manner. Several scheduling techniques are designed to
improve the quality of service. :
•FIFO queuing,
•Priority Queuing and
•Weighted Fair Queuing
FIFO queue

In first-in, first-out (FIFO) queuing, packets wait in a buffer (queue)


until the node (router or switch) is ready to process them
Priority queuing

In priority queuing, packets are first assigned to a priority


class. Each priority class has its own queue. The packets in the
highest-priority queue are processed first. Packets in the lowest-
priority queue are processed last.
Weighted fair queuing

The queues are weighted based on the priority of the queues;


higher priority means a higher weight.
Traffic Shaping

Traffic shaping is a mechanism to control the amount and the rate of


the traffic sent to the network. Two techniques can shape traffic:
•Leaky Bucket and
•Token Bucket.
Leaky bucket implementation

A leaky bucket algorithm shapes bursty traffic into fixed-rate traffic by


averaging the data rate. It may drop the packets if the bucket is full.
Token bucket
The token bucket can easily be implemented with a counter. The token is initialized to
zero. Each time a token is added, the counter is incremented by 1. Each time a unit of
data is sent, the counter is decremented by 1. When the counter is zero, the host cannot
send data

You might also like