R18: Yes an organization’s mail server and Web server can have the same alias for a host name. The MX record is used to map the mail server’s host name to its IP address. R24: The overlay network in a P2P file sharing system consists of the nodes participating in the file sharing system and the logical links between the nodes. There is a logical link (an “edge” in graph theory terms) from node A to node B if there is a semi-permanent TCP connection between A and B. An overlay network does not include routers. With Gnutella, when a node wants to join the Gnutella network, it first discovers (“out of band”) the IP address of one or more nodes already in the network. It then sends join messages to these nodes. When the node receives confirmations, it becomes a member of the of Gnutella network. Nodes maintain their logical links with periodic refresh messages. R28 With the UDP server, there is no welcoming socket, and all data from different clients enters the server through this one socket. With the TCP server, there is a welcoming socket, and each time a client initiates a connection to the server, a new socket is created. Thus, to support n simultaneous connections, the server would need n+1 sockets. P4. (a) The status code of 200 and the phrase OK indicate that the server was able to locate the document successfully. The reply was provided on Tuesday, 07 Mar 2006 12:39:45GMT. (b) 3874 bytes. (c) The first five bytes of the returned document are : “<!doc” . The server agreed to a persistent connection, as indicated by the Connection: Keep-Alive field. (d) Sat, 10 Dec2005 18:27:46GMT. P7. (a) ∆ = (900,000 bits)/(15,000,000 bits/sec) = 0.06 sec The traffic intensity on the link is (15 requests/sec)(0.06 sec/request) = 0.9 . Thus, the average access delay is (0.06 sec)/(1 – 0.9) = 0.6 sec. The total average response time is therefore 0.6 sec + 2 sec = 2.6 sec. (b) The traffic intensity on the access link is reduced by 40% since the 40% of the requests are satisfied within the institutional network. Thus the average access delay is (0.06 sec)/(1 – 0.9 * 0.6) = 0.13 sec. The response time is approximately zero if the request is satisfied by the cache (which happens with probability 0.4); the average response time is 0.13 sec + 2 sec = 2.13 sec for cache misses (which happens 60% of the time). So the average response time is (0 sec) * 0.4 + (2.13 sec) * 0.6 = 1.278 sec. P8. 2RTT0 + ∑ni=1 RTTi P10. Parallel download would only share the 150 bps bandwidth among the 10 connections (each getting just 15 bps), thus there is no significant advantage here. With persistent HTTP we avoid the SYN and SYNACK exchange but that only requires 2.66 seconds (1.33 seconds to send the 200 bit SYN message over the 150 bps link, and 1.33 second to receive the ACK). Given that each object takes 668 seconds to send request and receive the object, the use of pipelining gives gain less than 1 percent. P16. For calculating the minimum distribution time for client-server distribution, we use the following formula: Similarly, for calculating the minimum distribution time for P2P distribution, we use the following formula: Where, F = 10 Gbits = 10 * 1024 Mbits us = 20 Mbps dmin = di = 1 Mbps Client Server u N 10 100 1000 200Kbps 10240 51200 512000 600Kbps 10240 51200 512000 1Mbps 10240 51200 512000 10 100 1000 Peer-to-Peer u N 200Kbps 10240 25904.3 47559.33 600Kbps 10240 13029.6 16899.64 1Mbps 10240 10240 10240 P22. With the original line, UDPClient does not specify a port number when it creates the socket. In this case, the code lets the underlying operating system choose a port number. With the replacement line, when UDPClient is executed, a UDP socket is created with port number 5432 . UDPServer needs to know the client port number so that it can send packets back to the correct client socket. Glancing at UDPServer, we see that the client port number is not “hard-wired” into the server code; instead, UDPServer determines the client port number by unraveling the datagram it receives from the client (using the .getPort() method). Thus UDP server will work with any client port number, including 5432. UDPServer therefore does not need to be modified. Before: Client socket = x (chosen by OS) Server socket = 9876 After: Client socket = 5432