计算机网络第五章作业参考答案.docx
- 文档编号:1055339
- 上传时间:2022-10-16
- 格式:DOCX
- 页数:15
- 大小:348.45KB
计算机网络第五章作业参考答案.docx
《计算机网络第五章作业参考答案.docx》由会员分享,可在线阅读,更多相关《计算机网络第五章作业参考答案.docx(15页珍藏版)》请在冰豆网上搜索。
计算机网络第五章作业参考答案
计算机网络第五章作业参考答案
Chapter5
3.
ConsiderthenetworkofFig.5-7,butignoretheweightsonthelines.Supposethatitusesfloodingastheroutingalgorithm.IfapacketsentbyAtoDhasamaximumhopcountof3,listalltheroutesitwilltake.Alsotellhowmanyhopsworthofbandwidthitconsumes.Solution:
Itusesfloodingastheroutingalgorithm,whichmeanstotransmitpacketstoallportsexceptthecomingone.Itwilluse:
A,B,C,D,A,B,C,F,A,B,E,F,A,B,E,G,A,G,E,B,A,G,E,F,A,G,H
D,A,G,H,F.
So,24hopsbandwidthareused.
5.
ConsiderthenetworkofFig.5-12(a).Distancevectorroutingisused,andthefollowingvectorshavejustcomeintorouterC:
fromB:
(5,0,8,12,6,2);fromD:
(16,12,6,0,9,10);andfromE:
(7,6,3,9,0,4).ThecostofthelinksfromCtoB,DandE,are6,3,and5,respectively.WhatisC’snewroutingtable?
Giveboththeoutgoinglinetouseandthecost.
Solution:
IfCtransmitpacketviaB,A,B,C,D,E,F=(5,0,8,12,6,2)+(6,6,6,6,6,6)=(11,6,14,18,12,8)
IfCtransmitpacketgviaD,A,B,C,D,E,F=(16,12,6,0,9,10)+(3,3,3,3,3,3)=(19,15,9,3,12,13)
IfCtransmitpacketviaE,A,B,C,D,E,F=(7,6,3,9,0,4)+(5,5,5,5,5,5)=(12,11,8,14,5,9)
(11,6,0,3,5,8)
So,C’snewroutingtable(fromuptodownisfromCtoA,B,C,D,E)
DestinationCostoutgoingline(nexthop)
A11B
B6B
C0-
D3D
E5E
F8B
9.
LookingatthenetworkofFig.5-6,howmanypacketsaregeneratedbyabroadcastfromB,
using
(a)reversepathforwarding?
(b)thesinktree?
Solution:
(a)Reversepathforwarding:
whenabroadcastpacketarrivesatarouter,theroutercheckstoseeif
thepacketarrivedonthelinkthatisnormallyusedforsendingpacketstowardthesourceofthebroadcast.Thisbeingthecase,therouterforwardcopiesofitontoalllinksexcepttheoneit
arrivedon.
D
F
hop1:
2packets
hop2:
4packets
hop3:
10packets
hop4:
8packets
hop5:
4packets
totalbroadcastpackets=2+4+10+8+4=28packets(b)thesinktree:
Level1:
2packets
Level2:
4packets
Level3:
5packets
Level4:
3packets
Totalbroadcastpackets=2+4+5+3=14packets.
10.
ConsiderthenetworkofFig.5-15(a).Imaginethatonenewlineisadded,betweenFandG,
butthesinktreeofFig.5-15(b)remainsunchanged.WhatchangesoccurtoFig.5-15(c)?
Solution:
(figurecomefrom谭棋)
Thenewtreebuiltbyreversepathforwardingshouldbe:
/
F
15.
DescribetwomajordifferencesbetweentheECNmethodandtheREDmethodofcongestionavoidance.
Solution:
(1)ECN(ExplicitCongestionNotification)
Aroutercantaganypacketitforwardstosignalthatitisexperiencingcongestion.Whenthenetworkdeliversthepacket,thedestinationcannotethatthereiscongestionandinformthesenderwhenitsendsareplypacket.Thesendercanthenthrottleitstransmissions.
(2)RED(RandomEarlyDetection)
Thismethodprefertodealingwithcongestionwhenitfirststartsratherthanletitgumuptheworksandthentrytodealwithit.ThemotivationforthisideaisthatmostInternethostsdonotyetgetcongestionsignalsfromroutersintheformofECN.Instead,theonlyreliableindicationofcongestionthathostsgetfromthenetworkispacketloss.Havingroutersdroppacketsearly,beforethesituationhasbecomehopelesscanhelpreducecongestion.Theaffectedsenderwillnoticethelosswhenthereisnoacknowledgement,andthenthetransportprotocolwillslowdown.(3)Theirdifferences:
a.Applicationenvironment:
REDisusedwhenhostscannotreceiveexplicitsignal.
b.Congestionnotifiedmethod:
ECNdeliversacongestionsignalexplicitlyasachoke
packetwhileREDnoticescongestionthroughpacketloss.
16.
Imagineaflowspecificationthathasamaximumpacketsizeof1000bytes,atokenbucketrateof10millionbytes/sec,atokenbucketsizeof1millionbytes,andamaximum
transmissionrateof50millionbytes/sec.Howlongcanaburstatmaximumspeedlast?
Solution:
TheburstlengthSsec,themaximumoutputrateMbytes/sec,thetokenbucketcapacityBbytes,thetokenarrivalrateRbytes/sec.
B+RS=MS,S=B/(M-R)
Fromthisproblem,B=1MB,M=50MB/s,R=10MB/s
S=B/(M-R)=25ms
20.
SupposethathostAisconnectedtoarouterR1,R1isconnectedtoanotherrouter,R2,andR2isconnectedtohostB.SupposethataTCPmessagethatcontains900bytesofdataand20bytesofTCPheaderispassedtotheIPcodeathostAfordeliverytoB.ShowtheTotallength,Identification,DF,MF,andFragmentoffsetfieldsoftheIPheaderineachpackettransmittedoverthethreelinks.AssumethatlinkA-R1cansupportamaximumframesizeof1024bytesincludinga14-byteframeheader,linkR1-R2cansupportamaximumframesizeof512bytes,includingan8-byteframeheader,andlinkR2-Bcansupportamaximumframesizeof512bytesincludinga12-byteframeheader.
Solution:
WehaveanIP
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 计算机网络 第五 作业 参考答案
![提示](https://static.bdocx.com/images/bang_tan.gif)