Hello Friends, In this blog post(Stop and wait protocol Used In Data Link Layer) we are going to let you know What is meant by the ‘stop and wait’ protocol? What is the main disadvantage of the stop and wait protocol? What is flow control explain simple stop and wait and stop and wait for ARQ protocol? What is the window size of the stop and protocol?
What is meant by stop and wait for protocol?|Stop and wait protocol Used In Data Link Layer?
Using this protocol stop and wait, we wait for a while after sending the data packet and ensure the delivery of data packets to the end device in the correct order.
Once the sender gets the acknowledgment for the data then the sender again sends the data packet|Stop and wait protocol Used In Data Link Layer|
What is the main disadvantage of the stop and wait protocol?
The main disadvantage of this protocol is that it is slow up to a certain extent and can have time taken process during the data transmission.
For example in the case of acknowledgment loss receiver can not tell the sender whether they need retransmission of the previous packet or they want a new packet. This takes a lot of time.
What is the window size of the stop and protocol?
The window size in the stop and wait protocol is 1, where it keeps a frame to transmit. Once the sender transmits the frame then the sender waits until they receive the acknowledgment for the sent packet.
Once they get the acknowledgment then only the sender transmits a new frame.
In the stop and wait protocol for flow control, the sender waits for an acknowledgment after every frame it sends. The next frame is sent only after receiving the acknowledgment of the previous frame.
This process of alternately sending and waiting for repeats until the sender transmits an end of the transmission frame.
The advantage of stop and wait is the simplicity, each frame is checked and acknowledged before the next frame is sent.
The disadvantage is inefficiency; stop and wait are slow. Only a single frame uses the entire link from the time it is sent to its acknowledgment is received.
Thus if the distance between the sender and the receiver is long, the time spent waiting for ACKs between each frame can be a significant portion of the total transmission time.
Stop and wait for flow control is the simplest form of flow control which works as follows-
A-Frame is transmitted by a source entity. After the destination entity receives the frame, it shows its desire to accept another frame by sending back an acknowledgment to the frame just received.
Before sending the next frame, the Source must wait until it receives the acknowledgment.
Therefore, by withholding acknowledgment, the destination can stop the flow of data.
This procedure performs fine and, in fact, can hardly be improved upon when a message is sent in a few large frames.
It is, however, often the case when a source will break up a large block of data into smaller blocks and sends the data in many frames. This is done due to the following reasons:
The receiver buffer size may be limited.
In the longer transmission, more likely there will be an error, necessitating retransmission of the complete frame.
In a shared medium, like a LAN, it is usually desirable not to allow one station to occupy the medium for an extended period, Therefore causing long delays at the other sending stations.
The stop and wait protocol or procedure may be inadequate with the use of multiple frames for a single message. Serious inefficiencies result in a situation where the bit length of the link is greater than the frame length.
This is shown in fig1, in this fig the transmission time is normalized to one, and propagation delay is expressed as the variable a.
Therefore if a<1, the propagation time is less than the transmission time. In this case, the frame is long enough that the first bits of the frame has reached the destination before the complete transmission of the frame by the source.
If a >1, then the propagation time is greater than the transmission time.
In this case, the sender completes the transmission of the whole frame before the leading bits of the frame reach the receiver.
This can be said in another way that larger values of a are consistent with higher data rates and/or long distances between stations.
Both figures in fig 2 have a sequence of snapshots of the transmission process over time.
In both cases, the first four snapshots represent the process of transmitting a frame containing data and the last snapshot represents the return of a small acknowledgment frame.
It should be noted that for a > 1, the line is always underutilized and even for a<1, the line is inefficiently utilized.
In the case of very high data rates and very long distances between the sender and receiver, stop-and-wait flow control gives inefficient line utilization.
Link utilization efficiency:
The sequence of events and the associated time instants of their occurrence is shown in fig3. If the frame size is N bits and the data rate is R, device X will complete transmission of one frame in time Tf is given by
If Tp is the propagation time, the frame is completely received by device Y after time Tf+Tp. To calculate the best possible utilization of the link, it is assumed that
Y sends back acknowledgment immediately on receipt of a data frame.
The size of the acknowledgment frame is very small.
X will get the acknowledgment after time Tf+Tp+Tp and can send the next data frame immediately thereafter. From time Tf+2Tp, X has utilized the link only for time Tf, Therefore, link utilization efficiency U is as follows :
U = Tf/(Tf+2Tp) = 1/(1+2X) Where X = Tp/Tf
You can also go through a few more amazing blog links below related to computer networks:
What is meant by piggybacking what are its advantages and disadvantages…
What is meant by flow control…
What is sliding window protocol for example…
Stop and wait protocol Used In Data Link Layer…
Difference Between Error Control and Flow Control…
What Is Data Link Protocol…
ARQ Technique: Error Control Techniques In the Data link layer…
Error Control Using Data Link Layer In Computer Network…
Flow Control Using Data Link Layer In Computer Network…
HDLC Protocol In Hindi…
Using this blog post(Stop and wait protocol Used In Data Link Layer) we have learned about What is meant by stop and wait for protocol, What is the main disadvantage of stop and wait protocol, What is flow control explains simple stop and wait and stop and wait for ARQ protocol, What is the window size of stop and protocol. In stop and wait, the protocol sender waits until he receives the acknowledgment for the sent packet.
In the case of any queries, you can write to us at firstname.lastname@example.org we will get back to you ASAP.
Hope! you would have enjoyed this post about Stop and wait protocol Used In Data Link Layer.
Please feel free to give your important feedback in the comment section below.
Have a great time! Sayonara!