Sol Final BUEnetworks 2012

Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

Final Examination,

2012 / 2013
Module Title Introduction to Computer Networks and Communications

Module Leader Dr. Amal ElNahas Semester


One
Equipment allowed (for example
calculator – dictionaries) Calculators

Instructions to Students

 You should attempt all questions


 The exam paper is 9 pages long, and is in 1 section.
 The approximate allocation of marks is shown in brackets by the
questions.

This examination is ____2_____ hours long.

[Turn over]
Q1 There are two nodes, C and S, on a network,. C is the client and S
is the server. C wants to connect to S and send a file that is 35
kilobytes long. If the processing time at both ends of the
connection is negligible, but the propagation delay between node S
and node C is 5 ms and the link transmission rate is 10 Megabits
per second.
a) Assume that the file is sent as 1 message from C to S, what
will be the total message delay? [3 marks]
Solution:
Total delay = transmission delay + propagation delay
= 35*8/10*10^3 + 0.005 sec
= 0.028+ 0.005 = 0.033 sec

b) Now assume that the file is broken into packets and each
packet can hold up to 2 kilobytes of data and the headers are
negligibly small. Also assume that the client sends the
packets one at a time (client sends one packet and waits to
receive its acknowledgment before sending the next one).
ACks are also of negligible size.
i) At what time will S send an ACK packet in response
to the first data packet sent by C? [3 marks]
Solution:
Number of packets = 35/2 = 18 packets
Time to send first ACK by S = 1st packet transmission
time + propagation delay = 2*8/10*10^3 + 0.005 sec=
0.0066 sec

ii) How many RTTs will be needed for the client to send
the entire message? [4 marks]

Solution:
1 RTT is needed per packet, thus we need 18 RTTs to
send the whole file.

iii) What will be the total delay? [4 marks]

Solution:
Total delay = 18 *(2*propagation delay + packet
transmission delay)
Total delay = 18*(2*0.005 + 0.0016) = 0.2088 sec
[Total 14]
Q2 An engineer is working on a movie file on his local machine. The
movie is composed of a sequence of 30 frames per second. Each
frame is composed of 2000*1000 pixels, 32 bits per pixel and the
clip is 5 minutes long. He needs to send it to his manager over their
local 100 Mbps LAN. Assume negligible propagation, processing
and queuing delay,
a) Calculate how long will it take to transmit the clip.
[6 marks]

Solution:
File size = 5*60*30*2000*1000*32 = 576 Gbits
Transmission delay = L/R = 576000/100 = 5760 sec = 96
minutes.

b) This engineer is tired from his slow network and dreams of


being able to take a 10 minutes break and have the file
transfer completed by the time he gets back from his break.
How fast would the network needs to be to make his dream
come true?

Solution:
Transmission time = 10 minutes = 600 sec
600 = L/R = 576000/R
R= 960 Mbps

[4 marks]

Q3 Consider a user on machine A requesting the web page


http://SomeServer/something.html from the server named
SomeServer that is on a different network. List the sequence of
DNS, HTTP and TCP messages sent/received to serve this request
from the moment the URL is entered to the browser until the file is
completely received (the file doesn’t have any embedded objects).
Indicate the source and destination of each message. Assume
recursive DNS queries.

Solution:
 A-local DNS server: DNS query
 Local DNS-root: DNS query
 Root-Local DNS: DNS reply
 Local DNS-A: DNS reply
 A-SomeServer: TCP SYN
 SomeServer-A: TCP SYN, ACK
 A-SomeServer: TCP ACK + HTTP Get
 SemeServer-A: HTTP reply
 A-SomeServer: TCP FIN
 SomeServer-A: TCP ACK
 SomeServer-A: TCP FIN
 A-SomeServer: TCP ACK
:

[12 marks]

Q4 Consider a TCP implementation that uses an initial slow start


threshold of 8 kB. The maximum segment size shall be set to 1 kB
and the receiver's window is 16 kB. Due to congestion, timeouts
occur after the 8th, the 11th, and the 17th transmission. Sketch the
size of the congestion window and the slow start threshold into the
following diagram. Assume that no fast retransmit and fast
recovery is supported.
[12 marks]
Solution:
Congestion window size: 1,2,4,8,9,10,11,12,1,2,4,1,2, 3,4,5,6,1
Threshold value: 8,8,8,8,8,8,8,8,6,6,6,2,2,2,2,2,2,3

Q5 For the TCP segments indicated below, specify the omitted values.
Assume the packets are transmitted over a reliable link with no
packet loss or corruption.
50
400

400
170

[8 marks]

Q6 Consider sending a 1500-byte datagram into a link that has an


MTU of 510 bytes. Suppose the original datagram is stamped with
the identification number 1. Assume that IPv4 is used ( IPv4
header is 20bytes long). Answer the following questions:
a) Where does fragmentation happen? Where are the fragments
reassembled? [4 marks]

Solution:
Fragmentation is done at the sender machine that is
connected to the link with MTU less than the packet size.
Fragments are reassembled at the destination machine

b) How many fragments are generated? [2 marks]

Solution:
Number of fragments generated are 4. Each fragment
contains 488 bytes of data + 20 bytes of header, except the
last one.
c) Identify, for each segment, the values of the fragment offset,
MF flag, DF flag, ID number. [6 marks]

Solution:
Fragment 1: MF=1, DF=0, ID=1, Offset=0
Fragment 2: MF=1, DF=0, ID=1, Offset= 61
Fragment 3: MF=1, DF=0, ID=1, Offset= 122
Fragment 4: MF=0, DF=0, ID=1, Offset= 183

[Total 12]

Q7 An organization has a class C network of address 200.1.1.0 and it


wants to form subnets for 4 departments with the number of hosts
as follows:
 Subnet A: 12 hosts
 Subnet B: 25 hosts
 Subnet C: 20 hosts
 Subnet D: 18 hosts

a) Provide a possible arrangement of the network address space,


together with the respective range of IP addresses for each subnet
and the subnet mask. Explain your work. [8 marks]

Solution:
4 subnets require at least 2 bits for the subnet id, leaving us with 6
bits for the host id. These host bits allow up to 62 valid ip address
per subnet. Thus a possible arrangement would be as follows:
 Subnet 1: 200.1.1.0, mask: 255.255.255.192
 Subnet 2: 200.1.1.64, mask: 255.255.255.192
 Subnet 3: 200.1.1.128, mask: 255.255.255.192
 Subnet 4: 200.1.1.192, mask: 255.255.255.192

b) For each subnet, identify the lowest and highest valid IP address.
[8 marks]
Solution:
Subnet 1: lowest 200.1.1.1, highest: 200.1.1.63
Subnet 2: lowest 200.1.1.65, highest: 200.1.1.126
Subnet 3: lowest 200.1.1.129, highest: 200.1.1.191
Subnet 4: lowest 200.1.1.193, highest: 200.1.1.254

c) Suggest a new arrangement of the same address space if the


organization needs to create the 5th subnet (subnet E) with 10 new
hosts [6 marks]

Solution:
5 subnets would require 3 bits for subnet id, leaving only 5 bits for
host id (30 valid IP address/subnet) but this solution would change
all previous subnets addresses. A possible solution would be to
leave the last 3 subnets as before, the IP address of the 1 st subnet is
further divided among the 1st and the 5th as follows:
 Subnet 1: 200.1.1.0, mask: 255.255.255.224
 Subnet 2: 200.1.1.64, mask: 255.255.255.192
 Subnet 3: 200.1.1.128, mask: 255.255.255.192
 Subnet 4: 200.1.1.192, mask: 255.255.255.192
 Subnet 5: 200.1.1.32, mask: 255.255.255.224

[Total 22]

Q8 Consider the topology graph shown below. Construct the routing


table at node A by applying Dijkstra algorithm. Show your
workout.

3
A C
2
1 4
5 4 F E

B
3 D

[6 marks]
Solution:

N B C D E F
{A} A,5 A,3 A,1 ∞ ∞
{A,D} D,4 A,3 A,1 ∞ ∞
{A,D,C} D,4 A,3 A,1 ∞ C,5
{A,D,C,B} D,4 A,3 A,1 ∞ C,5
{A,D,C,B,F} D,4 A,3 A,1 F.9 C,5
{A,B,C,D,E,F} D,4 A,3 A,1 F,9 C,5

Routing tree: Routing Table

Destination Next Cost


A
3 hop
1 A A 0
B D 4
C D C C 3
2
3 D D 1
E C 9
F B
4
F C 5

You might also like