Difference between Flow Control and Congestion Control
Traffic management techniques like flow control and congestion control are used in computer networks. Two stations operating at different rates can communicate with one another using the flow control technique. To prevent a fast sender from overwhelming a slow receiver, a series of controls are put in place to limit the quantity of data that a sender delivers.
When a network receives more packets than it can handle, congestion occurs. Traffic overloading can cause network congestion. In a network, controls exist to prevent such congestion situations.
What is Flow Control?
A flow control system makes sure that a sender's transmission rate is inversely correlated with the receiver's capacity for receipt.
- Flow control is a technique used in data communications to manage the flow of packets and data between two nodes, especially when the sending device can deliver data more quickly than the receiving device.
- Networks of any size are made up of a wide variety of connected devices, each with its own settings for data transfer. A router, for instance, is made to control data routing, but a PC receiving the data has much less sending/receiving capacity.
- A conflict could occur if the sender starts sending data more quickly than the receiving node can receive it. To solve this problem, flow control is used. This technique regulates the data flow between nodes by concentrating on the transmitting and receiving capacities of each node.
A flow control protocol called Xon-Xoff synchronises the transmitter and the receiver. A transmit-off signal is sent by the receiver when its buffer is full, and a transmit-on signal is sent when it is ready to retake data. Asynchronous serial connections are used by Xon-Xoff.
Flow control limits how many frames can be sent at the data connection layer before the sender has wait for a response from the recipient.
Types of Flow Control
There are two general categories of flow control:
- Feedback-based Flow Control: After receiving the first frame in feedback-based control, the receiver notifies the sender, enables it to communicate additional information, and notifies the sender of the receiver's condition. The sliding window protocol and the stop-and-wait protocol are the two feedback-based flow control protocols.
- Rate-based Flow Control: In rate-based flow control, if a sender transmits data to a receiver at a quicker rate than the receiver can receive it, the protocol's built-in mechanism will cap the sender's data transmission rate without receiving any feedback from the receiver.
What is Congestion Control?
In a congested network, response time slows as network throughput decreases. Congestion occurs when data traffic exceeds capacity and bandwidth is constrained.
The communication medium chokes due to congestion. The subnet's speed suffers when too many packets are shown in one of its methods. As a result, if packets are travelling the way and experiencing delays mostly due to the path's propagation delay, the communication channel between networks is said to be crowded.
A network is a shared resource that many people use together. A congestive collapse occurs, when the Quality of Service is so poor that it precludes or restricts any usable communication can be brought on by a small number of erroneous or not-trusted network users (data senders).
Modern networks require both congestion control and network congestion avoidance techniques, such as, to prevent congestion collapse.
- Exponential backoff systems use algorithm feedback to lower data packet throughput to reasonable limits.
- Only vital data streams can be transmitted thanks to prioritisation techniques.
- The right distribution of network resources in anticipation of growing demands for data packet throughput.
Congestion Control Algorithms
There are two algorithms for congestion control, which are as follows:
- Leaky Bucket: The leaky bucket method finds applications for shaping or rate-limiting network traffic. The technique enables managing burstiness in the data flow as well as controlling the rate at which a record is injected into a network.
- Token Bucket Algorithm: It is a control algorithm that suggests the best times to send traffic. Based on how many tokens are visible in the bucket, this ranking is generated. Tokens are in the bucket. Each token designates a packet of a specific size. To allow sharing of a packet, tokens in the bucket are erased.