EKT335 PRINCIPLES OF COMPUTER NETWORK

TEST I - ANSWER

DATE : 17 OCT 2012

1.  a) Draw and compare the 7-layer defined in the ISO OSI Reference Model and 5-layer TCP/IP layer architecture. [3 marks]

Application
Presentation
Session
Transport
Network
Data Link
Physical
Application
Transport
Network
Link
Physical

7-Layer ISO OSI Reference Model 5-Layer TCP/IP Model

The key difference is that the 5-layer Internet model does not have the presentation and session layers found in the OSI model. Otherwise the models are essentially the same.

b)  Which TCP/IP layer is responsible for the following? [3 marks]

i)  Determining the best path to route packet.

Network Layer

ii)  Providing end-to-end communications with reliable service.

Transport Layer

iii)  Providing node-to-node communications with reliable service.

Data Link Layer

c)  Briefly explain the process of encapsulation happening in layered architecture. [4 marks]

-  The Application layer sends message to the Transport layer.

-  The Transport layer converts the Application layer message to segments by appending transport-layer header information to the Application layer message and sends it down to the Network layer.

-  The Network layer converts the segments to packets by adding the Network layer header information to the segments and sends them to the Data Link layer.

-  The Data Link layer converts the packets to frames by adding the Data Link layer header and sends them to the Physical layer.

-  The Physical layer converts the frames to 1's and 0's (electrical signals) and sends them across the network.

2.  The following question is based on Figure 1 below:

Tracing route to webserver.unimap.edu.my [58.27.57.229]

over a maximum of 30 hops:

1 2 ms 1 ms 1 ms 10.208.129.27

2 3 ms 3 ms 3 ms vl162-61 [202.179.118.122]

3 4 ms 3 ms 3 ms 218.100.45.127

4 8 ms 4 ms 3 ms 10.55.64.39

5 9 ms 7 ms 6 ms 210.187.75.23

6 7 ms 6 ms 5 ms mcl-getaway.gw.unimap.edu.my [58.27.57.1]

7 7 ms 9 ms 9 ms www.unimap.edu.my [58.27.57.229]

Trace complete.

Figure 1

‘traceroute’ command is used to determine the path from your home PC to your university’s main web page as shown in Figure 1.

a)  Using the output from traceroute in Figure 1, identify how many different routers are traversed. [2 marks]

6 different networks and service providers. The university getaway router is reached at hop 6.

b)  Briefly explain how this command can be used as a debugging tool by network managers.

[3 marks]

Thetraceroutecommand discovers the routes packets follow when traveling to their destinations. Thetraceroutecommand works by using the error message generated by switch routers when a datagram exceeds its time-to-live (TTL) value. First, probe datagrams are sent with a TTL value of one. This causes the first switch router to discard the probe datagrams and send back "time exceeded" error messages. Thetraceroutecommand then sends several probes, and displays the round-trip time for each. After every third probe, the TTL increases by one.

Each outgoing packet can result in one of two error messages. A "time exceeded" error message indicates that an intermediate switch router has seen and discarded the probe. A "port unreachable" error message indicates that the destination node has received the probe and discarded it because it could not deliver the packet to an application. If the timer goes off before a response comes in, thetraceroutecommand displays an asterisk (*).

3.  Consider a packet of length L which begins at end system A and travels over 3 links to a destination end system B. These 3 links are connected by 2 packet switches. Let di , si , and Ri denote the length, propagation speed, and the transmission rate of link i, for i = 1, 2, 3. The packet switch also delays each packet by dproc.

a)  Assuming no queuing delays, express the total end-to-end delay for the packet in terms of

di , si , Ri , (i = 1, 2, 3), and L. [5 marks]

dend-end = L/R1 + L/R2 + L/R3 + d1/s1 + d2/s2 + d3/s3+ dproc+ dproc

b)  Suppose now the packet is 1,500 bytes, the propagation speed on all 3 links is 2.5 x 108 m/s, the transmission rates for all 3 links are 2 Mbps, the packet switch processing delay is 3 msec, the length of the first link is 5000 km, the length of the second link is 4000 km, and the length of the last link is 1000 km. Calculate the end-to-end delay for this packet to be transmitted from A to B. [5 marks]

dend-end = 6 + 6 + 6 + 20+16 + 4 + 3 + 3 = 64 msec

4.  Suppose two hosts, A and B, are separated by 20,000 kilometers and are connected by a direct link of R = 2 Mbps. Suppose the propagation speed over the link is 2.5 x 108 m/s.

a)  Calculate the propagation delay, dprop. [2 marks]

dprop = d/s = 20000 x 103/(2.5 x 108) = 0.08 s

b)  Calculate the maximum number of bits that can be in the link (i.e the bandwidth-delay product, R x dprop. ). [2 marks]

BDP = R x dprop = (2 x 106) x 0.08 = 160, 000 bits

c)  Consider sending a file of 800,000 bits from Host A to Host B. Suppose the file is sent continuously as one large message. Calculate the total time taken to send the file.

[4 marks]

ttrans = L/R = 800,000 / (2 x 106) = 0.4 s

\Time = tprop + ttrans = 0.08 + 0.4 = 0.48 s

5.  a) Define the usage of a web cache (i.e., what benefits are derived from using a web cache)?

Where can a web cache be located or placed? [3 marks]

A web cache may be used to reduce response time as experienced by a user, reduce load on a link, and/or reduce load on a web server. A web cache may be placed in the user client (e.g., within the browser application), at “my” network edge (we call this a proxy server), and/or at the edge of the network containing the server (we call this a transparent cache).

b) Define what is DNS and what is it used for? Explain what would happen to the Internet if all DNS servers “crashed” (taken offline). [3 marks]

DNS is Domain Name Service and is used to associate host names (as in say, www.yahoo.com or ) with IP addresses. If all DNS servers were to be crashed one would be unable to use hostnames and could only use IP addresses when using Internet services.

c)  Consider what happens when a browser (that is, an HTTP client), running on some user’s host, requests the URL www.somesite.com/index.html. In order for the user’s host to be able to send an HTTP request message to the Web server www.somesite.com, the user’s host must first obtain the IP address of www.somesites.com. Explain the steps through which the IP address for such a hostname is obtained by the client. [4 marks]

Steps:

a)  The browser extract hostname, www.somesites.com, from the URL and passes the hostname to the client side of the DNS application.

b)  The DNS client sends a query containing the hostname to a DNS server.

c)  The DNS client receives a reply, which includes the IP address for the hostname.

d)  Once the browser receives the IP address from DNS, it can initiate a TCP connection to the HTTP server process located at port 80 at the IP address.

d)  For the client-server application over TCP, why must the server program be executed before the client program? For the client-server application over UDP, why may the client program be executed before the server program? [2 marks]

TCP:

Client needs to establish a TCP connection first with the server. If you run client program first, then the client will attempt to make a TCP connection with a non-existent server process. A TCP connection will not be made.

UDP:

No connection establishment is needed prior to communicating. Client may send request even when the server is not ready. UDP client doesn't establish a TCP connection with the server. Thus, everything should work fine if you run UDP client program first.

-oooOooo-

3