注:括弧之中红色标注为与课本习题对应的编号 2.1,2.2节后作业:
1. (R2)For a communication session between a pair of processes, which process is the client and
which is the server?
发起通信的进程为客户机,等待联系的进程是服务器。
2. (R3)What is the difference between network architecture and application architecture? 网络体系结构是指以分层的方式来描述通信过程的组织体系。
应用体系结构是由应用程序的研发者设计,并规定应用程序的主要结构。
3. (R4)What information is used by a process running on one host to identify a process running
on another host?
目的主机的 IP 地址和目的套接字的端口号。
4. (R7)Suppose you wanted to do a transaction from a remote client to a server as fast as
possible. Would you use UDP or TCP? Why?
UDP,因为UDP不需要建立连接,速度更快。
5. (R8)List the four broad classes of services that a transport protocol can provide. For each of
the service classes, indicate if either UDP or TCP (or both) provides such a service. Reliable Data Transfer,Throughput,Timing,Security. TCP: Reliable Data Transfer, Security UDP: Security
6. (R9)Why do HTTP, FTP, SMTP, and POP3 run on top of TCP rather than on UDP?
因为与这些协议相联系的应用都要求应用数据能够被无差错的有序的接收。TCP 提供可靠的数据传输服务,而 UDP 提供的是不可靠数据传输。
7. (R11)What is meant by a handshaking protocol?
TCP协议提供可靠的连接服务,采用三次握手建立一个连接。
2.3,2.4节后作业
8. (R15)Suppose Alice, with a Web-based e-mail account (such as Hotmail or gmail), sends a
message to Bob, who accesses his mail from his mail server using POP3. Discuss how the message gets from Alice's host to Bob's host. Be sure to list the series of application-layer protocols that are used to move the message between the two hosts.
信息从 Alice 的主机发送到她的邮件服务器,使用 HTTP 协议。然后邮件从 Alice 的邮件服务器发送到 Bob的邮件服务器,使用 SMTP 协议。最后 Bob 将邮件从他的邮件服务器接收到他的主机,使用 POP3 协议。
9. (R17)From a user's perspective, what is the difference between the download-and-delete
mode and the download-and-keep mode in POP3?
在下载并删除方式下,在用户从 POP 服务器取回他的邮件后,信息就被删除。
在下载并保留方式下,在用户取回邮件后,邮件不会被删除。
10. (R18)Is it possible for an organization's Web server and mail server to have exactly the same
alias for a hostname (for example, foo. com)? What would be the type for the RR that contains the hostname of the mail server? 可以。 MX。
11. (R19)Why is it said that FTP sends control information \"out-of-band\"?
FTP 使用两个并行的TCP 连接,一个连接用来传送控制信息(例如一个传送文件的请 求),另一个连接用于准确地传输文件。因为控制信息不是在文件传输地连接上传送,所以FTP 的控制信息是带外传送的。
2.5,2.6节后作业 12. (P1)True or false?
a. A user requests a Web page that consists of some text and three images. For this page, the client will send one request message and receive four response messages.
b. Two distinct Web pages (for example, www.mit.edu/research.Html and www.mit.edu/students. html) can be sent over the same persistent connection.
c. With nonpersistent connections between browser and origin server, it is possible for a single TCP segment to carry two distinct HTTP request messages.
d. The Date: header in the HTTP response message indicates when the object in the response was last modified. a.F b.T c.F d.F
13. (P7)Suppose within your Web browser you click on a link to obtain a Web page. The IP
address for the associated URL is not cached in your local host, so a DNS lookup is necessary to obtain the IP address. Suppose that n DNS servers are visited before your host receives the
IP address from DNS; the successive visits incur an RTT of RTT1,...,RTTn. Further suppose that the Web page associated with the link contains exactly one object, consisting of a small amount of HTML text. Let RTT0 denote the RTT between the local host and the server containing the object. Assuming zero transmission time of the object, how much time elapses from when the client clicks on the link until the client receives the object? 2RTT0 + RTT1+ RTT2 + Λ + RTTn.
14. (P8)Referring to Problem P7, suppose the HTML file references three very small objects on
the same server. Neglecting transmission times, how much time elapses with a. Non-persistent HTTP with no parallel TCP connections?
b. Non-persistent HTTP with parallel connections? c. Persistent HTTP (with pipelining)?
a. RTT1 +Λ+ RTTn+2RTT0+3×2RTT0=8RTT0+RTT1 +Λ+ RTTn b. RTT1 +Λ+ RTTn+2RTT0+2RTT0=4RTT0+RTT1 +Λ+ RTTn c. RTT1 +Λ+ RTTn+2RTT0+RTT0=3RTT0+RTT1 +Λ+ RTTn
2.7,2.8节后作业
15. (P9)Consider Figure2.12, for which there is an institutional network connected to the Internet.
Suppose that the average object size is 900,000 bits and that the average request rate from the institution’s browsers to the origin servers is 10 requests per second. Also suppose that the amount of time it takes from when the routers on the Internet side of the access link forwards an HTTP request until it receives the response is two seconds on average (see Section 2.2.5). Model the total average response time as the sum of the average access delay (that is, the delay from Internet router to institution router) and the average Internet delay. For the average access delay, use△/(1-△β), where △ is the average time required to send an object over the access link andβis the arrival rate of objects to the access link. a. Find the total average response time.
b. Now suppose a cache is installed in institution LAN. Suppose the hit rate is 0.6. Find the
total response time.
a.通过一个传输速率为 R 的链路传输长度为 L 的对象需要的时间是 L/R。平均时间是对象的平均大小除以 R: Δ=(900,000 bits)/(1,500,000 bits/sec) = 0.6 s 链路的流量强度是:βΔ=(1.5 requests/s)(0.6 s/request) = 0.9. 因此,平均访问时延是:Δ/(1-βΔ)=(0.6 s)/(1 -0 .9) = 6 s.因此,总的平均响应时间是:6 s + 2 s = 8 s.
b. 因为有 40%的请求有机构的网络满足,所以访问链路的流量强度减少了 40%。因此平均访问时延是:(0.6s)/[1 – (0.6)(0.9)] = 1.2 s如果请求由缓存器满足的话,其响应时间近似为 0。当缓存器未命中时,平均响应时间是 1.2 s + 2 s = 3.2 s 因此平均响应时间是:(0.4)(0 s) + (0.6)(3.2 s) = 1.92 s。
16. (P20)In our coverage of an overlay network using query flooding in Section 2.6, we describe
in some detail how a new peer joins the overlay network. In this problem we want to explore
what happens when a peer leaves the overlay network. Suppose every participating peer maintains TCP connections to at least four distinct peers at all times. Suppose Peer X, which has five TCP connections to other peers, wants to leave.
a. First consider the case of a graceful departure, that is, Peer X explicitly close its
application, thereby graceful closing its five TCP connections. What actions would each of the five formerly connected peers take?
b. Now suppose that Peer X abruptly disconnects from the Internet without notifying its
five neighbors that is closing the TCP connections. What would happen?
a. 在这种情况下,这五个客户都立即知道它们少了一个邻居。考虑五个客户中的一个,比如A。假设当 X 离开后,A只有三个邻居。这是A需要同另一个对等点建立 TCP 连接。A要有一个活跃对等点的最新列表;他不断地连接列表中地对等点知道其中一个接收它的 TCP 连接请求。
b. 在这种情况下,Bob 不能立即知道 X 已经离开了。只有当他尝试向 X 发送信息(query 或 ping)时,Bob 才会知道 X 已经离开。当 Bob 尝试发送信息时,Bob 的 TCP 将会产生数个不成功的连接信息。这时 Bob 的 TCP 将会通知 Gnutella 客户机 X 已经离开。然后 Bob 将会尝试与一个新的对等点建立 TCP 连接,以此重建第五个连接.
17. (P21)Consider query flooding, as discussed in Section 2.6. Suppose that each peer is
connected to at most N neighbors in the overlay network. Also suppose that the node-count field is initially set to K. Suppose Alice make s a query. Find an upper bound on the number of query messages that are sent into the overlay network.
Alice 发送她的 query 到至多 N 个邻居。每个邻居又发送这个 query 到至多 M=N-1 个邻居。这些邻居中的每一个又将这个 query 发送到至多 M 个邻居,因此最大的查询报文数为:N + NM + NM2+ … + NM(K-1)= N(1 + M + M2+ … + M(K-1))= N(1-MK)/(1-M)= N[(N-1)K- 1]/(N-2) .
附加选做题
18. 在TCP协议中,为了使通信不致发生混乱,引入了所谓套接字的概念,这里,套接字由
( A )和IP地址两部分组成。
A。端口号 B.域名 C。接口 D。物理地址 19. 面向连接的传输有三个过程:连接建立、( C )和连接释放。 A.连接请求 B。连接应答 C。数据传输 D。数据共享
20. 试述UDP和TCP协议的主要特点及它们的使用场合。(华中科技大学2003年试题)
TCP和UDP协议属于传输层协议。其中TCP提供IP环境下的数据可靠传输,它提供的服务[1]包括数据流传送、可靠性、有效流控、全双工操作和多路复用。通过面向连接、端到端和可靠的数据包发送。通俗说,它是事先为所发送的数据开辟出连接好的通道,然后再进行数据发送;而UDP则不为IP提供可靠性、流控或差错恢复功能。一般来说,TCP对应的是可靠性要求高的应用,而UDP对应的则是可靠性要求低、传输经济的应用。TCP支持的应用协议主要有:Telnet、FTP、SMTP等;UDP支持的应用层协议主要有:NFS(网络文件系统)、SNMP(简单网络管理协议)、DNS(主域名称系统)、TFTP(通用文件传输协议)等。 21. 选择题
1. 将本地计算机的文件传送到远程计算机上的过程称为___B______。 A. 下载 B. 上传 C. 登录 D. 浏览
2. Telnet是指_____A______。 A 远程登录 B 用户网络 C. 网络新闻组 D. 电子公告板
3. 电子邮件地址由用户名、@和______B___组成。 A. 网络服务器名 B 邮件服务器名 C 本地服务器名 D 邮件名
4. ______D_______应用可以实现网上实时交流。 A. 电子邮件 B. 网络新闻组 C FTP D. MSN
5. 在WWW服务器和浏览器之间传输数据所主要遵循的协议是_____A______。 A. HTTP B. TCP C IP D. FTP
7. .以下对Outlook Express邮件功能的叙述正确的是_____D______。 A. 只能是纯文本文件 B. 只能是超文本文件 C 只能发给一个收件人
D 可以同时发给多个收件人
8. 浏览用HTML语言写的页面的方式是_____C______。 A. 使用文本处理软件如WORD等浏览 B. 无需任何其他软件,直接浏览 C 使用浏览器浏览
D 只能用Netscape和因特网 Explorer两种软件浏览 9. WWW的工作模式是_____B______。 A. 客户机/客户机 B. 客户机/服务器 C 服务器/服务器 D 分布式
10. HTML是一种_____A_____。 A. 超文本标记语言 B. 传输协议 C 应用软件
D 以上都是
因篇幅问题不能全部显示,请点此查看更多更全内容