计算机网络自顶向下第六版课件

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

TransportLayer3-1Chapter3TransportLayerComputerNetworking:ATopDownApproach6theditionJimKurose,KeithRossAddison-WesleyMarch2012Anoteontheuseofthesepptslides:We’remakingtheseslidesfreelyavailabletoall(faculty,students,readers).They’reinPowerPointformsoyouseetheanimations;andcanadd,modify,anddeleteslides(includingthisone)andslidecontenttosuityourneeds.Theyobviouslyrepresentalotofworkonourpart.Inreturnforuse,weonlyaskthefollowing:Ifyouusetheseslides(e.g.,inaclass)thatyoumentiontheirsource(afterall,we’dlikepeopletouseourbook!)Ifyoupostanyslidesona(orperhapsidenticalto)ourslides,andnoteourcopyrightofthismaterial.Thanksandenjoy!JFK/KWRAllmaterialcopyright1996-2013J.FKuroseandK.W.Ross,AllRightsReservedTransportLayer3-2Chapter3:TransportLayerourgoals:understandprinciplesbehindtransportlayerservices:multiplexing,demultiplexingreliabledatatransferflowcontrolcongestioncontrollearnaboutInternettransportlayerprotocols:UDP:connectionlesstransportTCP:connection-orientedreliabletransportTCPcongestioncontrolTransportLayer3-3Chapter3outline3.1transport-layerservices3.2multiplexinganddemultiplexing3.3connectionlesstransport:UDP3.4principlesofreliabledatatransfer3.5connection-orientedtransport:TCPsegmentstructurereliabledatatransferflowcontrolconnectionmanagement3.6principlesofcongestioncontrol3.7TCPcongestioncontrolTransportLayer3-4Transportservicesandprotocolsprovidelogicalcommunicationbetweenappprocessesrunningondifferenthoststransportprotocolsruninendsystemssendside:breaksappmessagesintosegments,passestonetworklayerrcvside:reassemblessegmentsintomessages,passestoapplayermorethanonetransportprotocolavailabletoappsInternet:TCPandUDPapplicationtransportnetworkdatalinkphysicalapplicationtransportnetworkdatalinkphysicalTransportLayer3-5Transportvs.networklayernetworklayer:logicalcommunicationbetweenhoststransportlayer:logicalcommunicationbetweenprocessesrelieson,enhances,networklayerservices12kidsinAnn’shousesendinglettersto12kidsinBill’shouse:hosts=housesprocesses=kidsappmessages=lettersinenvelopestransportprotocol=AnnandBillwhodemuxtoin-housesiblingsnetwork-layerprotocol=postalservicehouseholdanalogy:TransportLayer3-6Internettransport-layerprotocolsreliable,in-orderdelivery(TCP)congestioncontrolflowcontrolconnectionsetupunreliable,unordereddelivery:UDPno-frillsextensionof“best-effort”IPservicesnotavailable:delayguaranteesbandwidthguaranteesapplicationtransportnetworkdatalinkphysicalapplicationtransportnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalnetworkdatalinkphysicalTransportLayer3-7Chapter3outline3.1transport-layerservices3.2multiplexinganddemultiplexing3.3connectionlesstransport:UDP3.4principlesofreliabledatatransfer3.5connection-orientedtransport:TCPsegmentstructurereliabledatatransferflowcontrolconnectionmanagement3.6principlesofcongestioncontrol3.7TCPcongestioncontrolTransportLayer3-8Multiplexing/demultiplexingprocesssocketuseheaderinfotodeliverreceivedsegmentstocorrectsocketdemultiplexingatreceiver:handledatafrommultiplesockets,addtransportheader(laterusedfordemultiplexing)multiplexingatsender:transportapplicationphysicallinknetworkP2P1transportapplicationphysicallinknetworkP4transportapplicationphysicallinknetworkP3TransportLayer3-9HowdemultiplexingworkshostreceivesIPdatagramseachdatagramhassourceIPaddress,destinationIPaddresseachdatagramcarriesonetransport-layersegmenteachsegmenthassource,destinationportnumberhostusesIPaddresses&portnumberstodirectsegmenttoappropriatesocketsourceport#destport#32bitsapplicationdata(payload)otherheaderfieldsTCP/UDPsegmentformatTransportLayer3-10Connectionlessdemultiplexingrecall:createdsockethashost-localport#:DatagramSocketmySocket1=newDatagramSocket(12534);whenhostreceivesUDPsegment:checksdestinationport#insegmentdirectsUDPsegmenttosocketwiththatport#recall:whencreatingdatagramtosendintoUDPsocket,mustspecifydestinationIPaddressdestinationport#IPdatagramswithsamedest.port#,butdifferentsourceIPaddressesand/orsourceportnumberswillbedirectedtosamesocketatdestTransportLayer3-11Connectionlessdemux:exampleDatagramSocketserverSocket=newDatagramSocket(6428);transportapplicationphysicallinknetworkP3transportapplicationphysicallinknetworkP1transportapplicationphysicallinknetworkP4DatagramSocketmySocket1=newDatagramSocket(5775);DatagramSocketmySocket2=newDatagramSocket(9157);sourceport:9157destport:6428sourceport:6428destport:9157sourceport:?destport:?sourceport:?destport:?TransportLayer3-12Connection-orienteddemuxTCPsocketidentifiedby4-tuple:sourceIPaddresssourceportnumberdestIPaddressdestportnumberdemux:receiverusesallfourvaluestodirectsegmenttoappropriatesocketserverhostmaysupportmanysimultaneousTCPsockets:eachsocketidentifiedbyitsown4-tuplewebservershavedifferentsocketsforeachconnectingclientnon-persistentHTTPwillhavedifferentsocketforeachrequestTransportLayer3-13Connection-

1 / 110
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功