Problem 17
Consider two network entities, \(\mathrm{A}\) and \(\mathrm{B}\), which are connected by a perfect bidirectional channel (i.e., any message sent will be received correctly; the channel will not corrupt, lose, or re-order packets). A and B are to deliver data messages to each other in an alternating manner: First, A must deliver a message to \(\mathrm{B}\), then \(\mathrm{B}\) must deliver a message to \(\mathrm{A}\), then \(\mathrm{A}\) must deliver a message to \(\mathrm{B}\) and so on. If an entity is in a state where it should not attempt to deliver a message to the other side, and there is an event like rdt_send (data) call from above that attempts to pass data down for transmission to the other side, this call from above can simply be ignored with a call to rdt_unable_to_send (data), which informs the higher layer that it is currently not able to send data. [Note: This simplifying assumption is made so you don't have to worry about buffering data.] Draw a FSM specification for this protocol (one FSM for A, and one FSM for B!). Note that you do not have to worry about a reliability mechanism here; the main point of this question is to create a FSM specification that reflects the synchronized behavior of the two entities. You should use the following events and actions that have the same meaning as protocol rdt \(1.0\) in Figure 3.9: rdt_send(data), packet = make_pkt(data), udt_send (packet), rdt_rcv (packet), extract (packet, data), deliver_data (data). Make sure your protocol reflects the strict alternation of sending between \(\mathrm{A}\) and \(\mathrm{B}\). Also, make sure to indicate the initial states for A and B in your FSM descriptions.
Problem 17
Suppose two TCP connections are present over some bottleneck link of rate \(R\) bps. Both connections have a huge file to send (in the same direction over the bottleneck link). The transmissions of the files start at the same time. What transmission rate would TCP like to give to each of the connections?
Problem 18
True or false? Consider congestion control in TCP. When the timer expires at the sender, the value of ssthresh is set to one half of its previous value.
Problem 21
Consider the GBN protocol with a sender window size of 4 and a sequence number range of 1,024 . Suppose that at time \(t\), the next in-order packet that the receiver is expecting has a sequence number of \(k\). Assume that the medium does not reorder messages. Answer the following questions: a. What are the possible sets of sequence numbers inside the sender's window at time \(t\) ? Justify your answer. b. What are all possible values of the \(\mathrm{ACK}\) field in all possible messages cur rently propagating back to the sender at time \(t ?\) Justify your answer.
Problem 22
Consider the GBN protocol with a sender window size of 4 and a sequence number range of 1,024 . Suppose that at time \(t\), the next in-order packet that the receiver is expecting has a sequence number of \(k\). Assume that the medium does not reorder messages. Answer the following questions: a. What are the possible sets of sequence numbers inside the sender's window at time \(t\) ? Justify your answer. b. What are all possible values of the ACK field in all possible messages currently propagating back to the sender at time \(t\) ? Justify your answer.
Problem 25
We have said that an application may choose UDP for a transport protocol because UDP offers finer application control (than TCP) of what data is sent in a segment and when. a. Why does an application have more control of what data is sent in a segment? b. Why does an application have more control on when the segment is sent?
Problem 26
Consider transferring an enormous file of \(L\) bytes from Host A to Host B. Assume an MSS of 536 bytes. a. What is the maximum value of \(L\) such that TCP sequence numbers are not exhausted? Recall that the TCP sequence number field has 4 bytes. b. For the \(L\) you obtain in (a), find how long it takes to transmit the file. Assume that a total of 66 bytes of transport, network, and data-link header are added to each segment before the resulting packet is sent out over a \(155 \mathrm{Mbps}\) link. Ignore flow control and congestion control so A can pump
Problem 28
Host \(\mathrm{A}\) and \(\mathrm{B}\) are directly connected with a \(100 \mathrm{Mbps}\) link. There is one TCP connection between the two hosts, and Host \(\mathrm{A}\) is sending to Host \(\mathrm{B}\) an enormous file over this connection. Host A can send its application data into its TCP socket at a rate as high as \(120 \mathrm{Mbps}\) but Host B can read out of its TCP receive buffer at a maximum rate of \(50 \mathrm{Mbps}\). Describe the effect of TCP flow control.
Problem 32
Consider the TCP procedure for estimating RTT. Suppose that \(\alpha=0.1\). Let SampleRTT \(_{1}\) be the most recent sample RTT, let SampleRTT \(_{2}\) be the next most recent sample RTT, and so on. a. For a given TCP connection, suppose four acknowledgments have been returned with corresponding sample RTTs: SampleRTT \(_{4}\), SampleRTT \(_{3}\), SampleRTT \(_{2}\), and SampleRTT \(_{1}\). Express EstimatedRTT in terms of the four sample RTTs. b. Generalize your formula for \(n\) sample RTTs. c. For the formula in part (b) let \(n\) approach infinity. Comment on why this averaging procedure is called an exponential moving average.
Problem 36
In Section 3.5.4, we saw that TCP waits until it has received three duplicate ACKs before performing a fast retransmit. Why do you think the TCP designers chose not to perform a fast retransmit after the first duplicate ACK for a segment is received?