1、得分TCP/IP模型XX大学考试卷(B卷)答案课程:计算机网络(闭卷电信系提高班)题号一(8 分)二(8 分)三(8分)四(8分)五(8分)六(8分)题号七(8分)八(8分)九(8分)十(8分)+ - 8 分)十二(12分)Fundamental conceptions of network architecture.(1) Draw the ISO/OSI reference model and TCP/IP model, state their differences briefly; (2) Select one of the above architectures, what is t
2、he data unit processed in each layer, what kind of equipment can be deployed in each layer?传输层网络层网际接口层两者的区别:a)TCP/IP是事实上的互联网结构,而OSI参考模型只是一个理论上的模型没有得到实际 的应用b)TCP/IP没有严格的分层,而OSI模型分层很严格。假设需要 kRTTs ,因此可得 1 Bx(20 + 2+2不能使用CSMA,因为会遇到Hidden Terminal Problem,导致节点之间的通信发生冲突。 不能使用CSMA/CD,因为目前的无线网卡还没有技术能够实现一边发送
3、信息,一边检 测是否有冲突的发生。因此只能使用CSMA/CA来实现无线局域网的通信。 + .+ 2,-,)4-(Z:-10)x1MB = 10A/B.即 2,o-l + (Jt-lO)xlO24 = l 0240,得至ij k=(10240-2i +1) + 1024 +10 = 19 +1/1024 a 20.因此需要20RTTs才能发送文件。吞吐量为吞吐量为得分当 TCP 达到稳定的拥塞窗口时,传送的有效 1MB/1 RTT= 1 MB/0.2s=5MBps=40Mbps.链路的带宽利用率为40Mbps/lGbps = 4%.12. Wireless NetworkCan we use C
4、SMA in a wireless LAN? Why? (Hits: you may answer the new problems introduced by the range-sensitive carrier sensing)(1) Can we use CSMA/CD in a wireless LAN? Why?c) 在TCP/IP模型中,IP协议是整个网络结构的的关键点。d) TCP/IP模型中,允许有很多不同的网络技术,从以太网到FDDI,到ATM,到单一的 点到点链路。e) TCP/IP强调对所提交协议的实用性。(2)OSI模型:得分中继器网桥/交换机 路由器网关网关物理层:
5、比特, 数据链路层:帧, 网络层:包/数据报 传输层:消息/段 上三层:消息System design in networkingThere are some famous design principles mentioned in our course. Please tell the meaning of following principle in brief. For each principle, give one example following it and one example not following it.(1) Keep it simple and stupidC
6、omplex edge and simple coreKISS原则在设计当中注重简约的原则。符合该原则的例子:以太网不符合该原则的例子:令牌环/ATM/FDDI(2)边界复杂,核心简单使网络中的主机比较复杂拥有许多功能,能解决很多问题,而网络中的节点则比较简单, 将网络中的许多问题留给网络两端的主机来解决。符合该原则的例子:分组交换,DiffServ不符合该原则的例子:电路交换,InteServ得分1. Circuit switching and packet switchingAssume we wish to transfer an n-byte file along the follow
7、ing network. Suppose each link has a propagation delay of 2 ms, bandwidth of 4 Mbps, the switches support both circuit and packet switching.oooooA B C D EIf we use circuit switching, circuil setup requires a 1-KB message to make one round-trip on the path incurring a 1-ms delay at each switch after
8、the message has been completely received. Then we can send the file as one contiguous bit stream. If we use packet switching, we can break thefile up into 1-KB packets, in which 24 bytes of header and 1 ()0() bytes of pay load. The switch takes 1 -ms process delay after receiving the packet, and the
9、n sent it continuously.(1) Take the link from A to C as example; draw the time line based diagram to show the differences between circuit switching and packet switching.(2) For what file size n bytes is the total number of bytes sent across the network less for circuits than for packets?(3) For what
10、 file size n bytes is the total latency incurred before the entire file arrives at the destination less for circuits than for packets (1)时间线图电路交换:CircuitEstablishmentDataTransmissionCircuitTerminationABCTransmission time of packet 1分组交换:(2)电路交换:总共发送的字节:n+1024 bytes分组交换:总共发送的字节n+24*(l+n/1000). x表示不大于
11、x的最大整数。当n+102441000 bit = 5KB时,电路交换发送的字节少于分组交换发送的字节。(2) 电路交换:总时延:(2ms*4+( 1 KB/4Mbps+1 ms)*3)*2+2ms*4+nB/4Mbps,分组交换:总时延:4*2ms+( 1 KB/4Mbps+1 ms)*3+nB/4Mbps*4 可得(2ms*4+( 1 KB/4Mbps+l ms)*3)*2+2ms*4+nB/4Mbps= 3KB时,电路交换的时延小于分组交换的时延。2. Error correctionSuppose we4 + x 3 + I.(1) Use polynomial long divisi
12、on to determine the message that should be transmitted.(2) Suppose the leftmost bit of the message is inverted due to noise on the transmission link.What is the result of the receiver CRC calculation? How does the receiver know that an error has occurred?(1) M (x) = x10 + x8 + x7 + x4 + x3 + x1, C(x
13、) = x4 + x3 +1.可知 k=4.a) M(x)乘上 2* ,得 T(x) = x14 4- x2 4- x11 + x8 4- x7 4- x5 ,用T(x)除以C(x)得余数()000b) 因此应该传输的数据为得分(2) 用接收到的数据除上C(x),得余数收00,即不能被C(x)整除。因此 接收到的数据有错误发生。3. Reliable transmissionSuppose one like has bandwidth of 4kbps, one way propagation delay of 20 ms. One station use stop-and-wait prot
14、ocol to send data to another destination. What size of the frame can reach 30% and 50% link utilization respectively?RTT=2*20ms=40ms.假设一帧的大小为x KB ,可得最大发送速率为 Bits Per Frame 4- Time Per Frame = xKB X 1024 X 8 4- (0.04+x/4kbps).假设链路利用率达到30%,可知x X1024 X 84- (0. 04+x/4kbps) = 30%.得到 x=69 bits.假设链路利用率达到50
15、%,可知x X1024 X 8(0. 04+x/4kbps) = 50%.得到 x=160bits.得分4. The spanning tree algorithmGiven the extended LAN shown in the following Figure , indicate which ports are not selected by the spanning tree algorithm.从图中可以看到,Bl具有最小ID,而B3与B7为指派网桥。由生成树算法可知,B5网桥 的两个端口、B2网桥的左上端口、B6网桥的下端口没有被选择。答案如图:得分5. Distance ve
16、ctor routing algorithmFor the network given in following figure, give global distance-vector tables(1) each node knows only the distances to its immediate neighbors.(2) each node has reported the information it had in the preceding step to its immediate neighbors.(3) step (2) happens a second time.路
17、由表c54011D43102E65120得分6. Link state routing algorithmFor the network given in following figure, give the steps of forward search in Dijkstra algorithm for node A find the shortest path to node EA节点建立路由表的步骤:Step123456789Confirmed(A,0,)(A,0,)(AQ-)(D,2,D)(A,0,-)(D,2,D)(A,0,) (D,2,D) (B,4,D)(A,0,-) (D,2
18、,D) (BAD)(A,0,-)(D,2,D) (B,4,D) (E,6,D)(A,0,-)(D,2,D) (B,4,D) (E,6,D)(A,0,) (D,2,D) (B,4,D) (E,6,D) (C,7,D)Tentative(B,5,B)(D,2,D)(B,5,B)(B,4,D)(E,7,D)(E,7,D)(E,6,D)(C,8,D)(C,8,D)(C,7,D)A-EA-D一 EA-*D-B-EA-D一 B-E我们可以得出从A节点到E节点的最短路径为A-D-B-E.IP address allocation得分There are four departments in one comp
19、any, each department will have 20-30 computers. The company has one C class IP address of 200.1.1.(1) Give the network address and mask for each department, and write down the IP address range for each department.(2) If the four departments have 72, 35, 20, 34 computers respectively. Answer question
20、 (1) again.部门子网号子网掩码IP地址1200.1.1.0 220(). 1.1.64 34(1)(1)(2)由于C类地址不能满足题目要求,因此该公司可以将需要72个IP的部门分为两个子网。部门子网号子网掩码IP地址主机数196264364432TCP protocol得分(1) Draw the time line diagram showing two nodes establish one TCP connection.(2) Suppose we use two hand-shakes in the TCP connection establishment. What wil
21、l happen?Active participant(client)Passive participant(server)5如(2)假设我们在TCP连接建立时只进行两次握手,那么当客户端向服务端发送TCP连接报 文时,由于网络繁忙发生延时。当该报文到达服务端时,客户端已经取消了此次连接的建 立。而服务端则向客户端发送连接建立报文,进行第二次握手。这种情况下,客户端会丢 弃收到的连接建立报文,而服务端则以为连接已经建立,一直等待客户端发送数据过来, 这就导致了服务端空等,浪费了服务端的资源。7. TCP congestion controlAssume that TCP implements
22、an extension that allows window sizes much 得分 larger than 64 KB. Suppose that you are using this extended TCP over a 1-Gbps link with a latency of 100 ms to transfer a 10-MB file, and the TCP receive window is 1 MB. If TCP sends 1-KB packets (assuming no congestion and no lost packets):(1) How many
23、RTTs does it take until slow start opens the send window to 1 MB?(2) How many RTTs does it take to send the file?(c) After TCP reach stable congestion windows. What is the effective throughput for the transfer? What percentage of the link bandwidth is utilized?假设需要nRTTS ,那么可得1KBx2=MB解方程,得2” =1024,得到n=10.因此需要10 RTTs才能使发送窗口达到1MB.