Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
8 views3 pages

Assignment - 3,4 Combine

Uploaded by

vani27484
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views3 pages

Assignment - 3,4 Combine

Uploaded by

vani27484
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Assignment 3,4 combine

B.Tech. CS VI Semester
Computer Network - I
1. Consider a TCP connection between Host A and Host B. Suppose that the TCP segments
traveling from Host A to Host B have source port number x and destination port number
y. What are the source and destination port numbers for the segments traveling from Host
B to Host A?
2. Describe why an application developer might choose to run an application over UDP
rather than TCP.
3. Suppose a process in Host C has a UDP socket with port number 6789. Suppose both Host
A and Host B each send a UDP segment to Host C with destination port number 6789. Will
both of these segments be directed to the same socket at Host C? If so, how will the process
at Host C know that these two segments originated from two different hosts?
4. Host A and B are communicating over a TCP connection, and Host B has already received
from A all bytes up through byte 126. Suppose Host A then sends two segments to Host B
back-to-back. The first and second segments contain 80 and 40 bytes of data, respectively.
In the first segment, the sequence number is 127, the source port number is 302, and the
destination port number is 80. Host B sends an acknowledgment whenever it receives a
segment from Host A.
1. In the second segment sent from Host A to B, what are the sequence number,
source port number, and destination port number?
2. If the first segment arrives before the second segment, in the acknowledgment of
the first arriving segment, what is the acknowledgment number, the source port
number, and the destination port number?
3. If the second segment arrives before the first segment, in the acknowledgment of
the first arriving segment, what is the acknowledgment number?
4. Suppose the two segments sent by A arrive in order at B. The first acknowledgment
is lost and the second acknowledgment arrives after the first timeout interval. Draw
a timing diagram, showing these segments and all other segments and
acknowledgments sent. (Assume there is no additional packet loss.) For each
segment in your figure, provide the sequence number and the number of bytes of
data; for each acknowledgment that you add, provide the acknowledgment number.
5. Host A and B are directly connected with a 100 Mbps link. There is one TCP connection
between the two hosts, and Host A is sending to Host 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
Mbps but Host B can read out of its TCP receive buffer at a maximum rate of 50 Mbps.
Describe the effect of TCP flow control.
6. Compare GBN, SR, and TCP (no delayed ACK). Assume that the timeout values for all
three protocols are sufficiently long such that 5 consecutive data segments and their
corresponding ACKs can be received (if not lost in the channel) by the receiving host (Host
B) and the sending host (Host A) respectively. Suppose Host A sends 5 data segments to
Host B, and the 2nd segment (sent from A) is lost. In the end, all 5 data segments have
been correctly received by Host B.
1. How many segments has Host A sent in total and how many ACKs has Host B sent
in total? What are their sequence numbers? Answer this question for all three
protocols.
2. If the timeout values for all three protocols are much longer than 5 RTT, then which
protocol successfully delivers all five data segments in shortest time interval?
7. 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.
1. Why does an application have more control of what data is sent in a segment?
2. Why does an application have more control on when the segment is sent?

8. 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 is the transmission rate that the TCP
would like to give to each of the connections?
9. Suppose Host A sends two TCP segments back-to-back to Host B over a TCP connection.
The first segment has sequence 100; the second segment has sequence number 1025.
a. How much data is there in the first segment?
b. Suppose that the first segment is lost but the second segment arrives at B. In the
acknowledgement that Host B send to Host A, what will be the acknowledgement
number?
10. Consider the effect of using slow start on a line with a 10-msec round-trip time and no
congestion. The receive window is 24 KB and the maximum segment size is 2 KB. How
long does it take before the first full window can be sent?

You might also like