Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Suppose a TCP connection, with window size 1, loses every other packet. Those that do arrive have RTT \(=1\) second. What happens? What happens to TimeOut? Do this for two cases: (a) After a packet is eventually received, we pick up where we left off, resuming with EstimatedRTT initialized to its pretimeout value and TimeOut double that. (b) After a packet is eventually received, we resume with TimeOut initialized to the last exponentially backed-off value used for the timeout interval. In the following four exercises, the calculations involved are straightforward with a spreadsheet.

Short Answer

Expert verified
Case (a): TimeOut doubles after loss and returns to EstimatedRTT, Case (b): TimeOut retains the double value after loss and doesn't reset.

Step by step solution

01

Title - Understand the Problem

Identify the problem context: A TCP connection with window size 1 where every other packet is lost. Given RTT is 1 second. We need to analyze the situations for two cases: resuming with either estimatedRTT or the backed-off TimeOut value.
02

Title - Case (a): Calculating EstimatedRTT and TimeOut

In case (a), after a packet is eventually received, the connection resumes with the EstimatedRTT set to its pre-timeout value and TimeOut doubled each time a packet is lost. For each cycle of loss and receipt, plot the TimeOut values. Initially, EstimatedRTT = 1 second. If a packet is lost, TimeOut doubles: 2 seconds, then 4 seconds, then 8 seconds, etc. When a packet is eventually received, EstimatedRTT stays at 1 second and TimeOut doubles.
03

Title - Case (b): Track Exponential Back-Off

In case (b), after a packet is eventually received, the resumption occurs with the TimeOut value initialized to the last exponentially backed-off value. This means to track the current TimeOut value which continues doubling until a packet is received. Post reception, TimeOut remains doubled and carries forward. For each cycle of loss and receipt, the TimeOut values will: 2 seconds, 4 seconds, 8 seconds, etc., and then continue to stay at that last value post packet receipt.
04

Title - Analyzing TimeOut and RTT

For both cases, calculate the patterns of TimeOut and RTT: For case (a) after each reception, TimeOut resets to the EstimatedRTT and gets doubled only if there's a subsequent loss. In case (b), TimeOut doubles but does not reset on reception and maintains the backed-off value.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

Key Concepts

These are the key concepts you need to understand to accurately answer the question.

TCP window size
In a TCP connection, the window size determines how many packets can be sent before waiting for an acknowledgment. Think of it as a buffer space for unacknowledged packets. In our exercise, the window size is 1, which means only one packet is sent at a time and the sender waits for its acknowledgment before sending the next packet.
A small window size, like 1, can slow down the transmission rate since the sender must wait for the acknowledgment after every single packet. This is especially impactful if there are delays, as seen in our scenario where packets are lost every other transmission.
Packet loss
Packet loss occurs when data packets traveling across a network fail to reach their destination. Packet loss can cause transmission delays because lost packets need to be resent. In our exercise, every other packet is lost, causing significant disruption.
The impact of packet loss is pronounced with a small TCP window size. Since only one packet is sent at a time, losing every other packet means frequent resending and waiting, which can drastically reduce effective throughput and increase the overall transmission time.
RTT calculation
Round-Trip Time (RTT) is the time it takes for a signal to go from the sender to the receiver and back again. In our problem, the RTT is given as 1 second. This means, under ideal conditions without packet loss, each packet acknowledgment should return within 1 second.
In the context of our scenario, lost packets will increase the effective RTT as the packets need to be resent, and each subsequent retry causes a delay.
Timeout calculation
Timeout is the duration a sender waits for an acknowledgment before assuming a packet is lost and resending it. Determining the timeout value is crucial and is usually based on RTT and its variations.
In case (a), after a packet is eventually received, the timeout doubles each time a packet is lost, which follows an exponential pattern: 2 seconds, 4 seconds, 8 seconds, and so forth. When a packet is finally received, the timeout resets, but still considers the EstimatedRTT.
In case (b), after a packet is received, the timeout resumes from the last exponentially backed-off value. This means it continuously doubles with each packet loss and carries this timeout value forward post-reception.
Exponential backoff
Exponential backoff is a strategy employed to manage network congestion by exponentially increasing the waiting time between subsequent attempts following packet loss. This is crucial to prevent overwhelming the network with retries.
In case (a), the exponential backoff is demonstrated through doubling the timeout period after each packet loss. Additionally, the EstimatedRTT is recalibrated to its pre-timeout value upon successful reception.
In case (b), the exponential backoff continues without resetting. This means if the timeout period was 8 seconds after a series of losses and then a packet was successfully received, the timeout retains the 8 seconds and continues to double if packet loss persists.

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Suppose party A connects to the Internet via a dial-up IP server (e.g., using SLIP or PPP), has several open Telnet connections (using TCP), and is cut off. Party B then dials in and is assigned the same IP address that A had. Assuming B was able to guess to what host(s) A had been connected, describe a sequence of probes that could enable B to obtain sufficient state information to continue with A's connections.

If a UDP datagram is sent from host \(\mathrm{A}\), port \(\mathrm{P}\) to host \(\mathrm{B}\), port \(\mathrm{Q}\), but at host \(\mathrm{B}\) there is no process listening to port \(Q\), then \(B\) is to send back an ICMP Port Unreachable message to A. Like all ICMP messages, this is addressed to A as a whole, not to port \(\mathrm{P}\) on \(\mathrm{A}\). (a) Give an example of when an application might want to receive such ICMP messages. (b) Find out what an application has to do, on the operating system of your choice, to receive such messages. (c) Why might it not be a good idea to send such messages directly back to the originating port \(\mathrm{P}\) on \(\mathrm{A}\) ?

TCP's simultaneous open feature is seldom used. (a) Propose a change to TCP in which this is disallowed. Indicate what changes would be made in the state diagram (and if necessary in the undiagrammed event responses). (b) Could TCP reasonably disallow simultaneous close? (c) Propose a change to TCP in which simultaneous SYNs exchanged by two hosts lead to two separate connections. Indicate what state diagram changes this entails, and also what header changes become necessary. Note that this now means that more than one connection can exist over a given pair of \langlehost, port)s. (You might also look up the first "Discussion" item on page 87 of Request for Comments \(1122 .\) )

Suppose that, when a TCP segment is sent more than once, we take SampleRTT to be the time between the original transmission and the ACK, as in Figure \(5.10(\mathrm{a}) .\) Show that if a connection with a 1-packet window loses every other packet (i.e., each packet is transmitted twice), then EstimatedRTT increases to infinity. Assume TimeOut = EstimatedRTT; both algorithms presented in the text always set TimeOut even larger. Hint: EstimatedRTT \(=\) EstimatedRTT \(+\beta \times(\) SampleRT \(-\) EstimatedRTT).

Suppose a host wants to establish the reliability of a link by sending packets and measuring the percentage that are received; routers, for example, do this. Explain the difficulty of doing this over a TCP connection.

See all solutions

Recommended explanations on Computer Science Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free