计算机网络课件:Chapter2-2.ppt
- 【下载声明】
1. 本站全部试题类文档,若标题没写含答案,则无答案;标题注明含答案的文档,主观题也可能无答案。请谨慎下单,一旦售出,不予退换。
2. 本站全部PPT文档均不含视频和音频,PPT中出现的音频或视频标识(或文字)仅表示流程,实际无音频或视频文件。请谨慎下单,一旦售出,不予退换。
3. 本页资料《计算机网络课件:Chapter2-2.ppt》由用户(罗嗣辉)主动上传,其收益全归该用户。163文库仅提供信息存储空间,仅对该用户上传内容的表现方式做保护处理,对上传内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知163文库(点击联系客服),我们立即给予删除!
4. 请根据预览情况,自愿下载本文。本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
5. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007及以上版本和PDF阅读器,压缩文件请下载最新的WinRAR软件解压。
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 计算机网络 课件 Chapter2
- 资源描述:
-
1、2: Application Layer1Chapter 2: Application LayerOur goals: rconceptual, implementation aspects of network application protocolsvtransport-layer service modelsvclient-server paradigmvpeer-to-peer paradigmrlearn about protocols by examining popular application-level protocolsvHTTPvFTPvSMTP / POP3 / I
2、MAPvDNSrprogramming network applicationsvsocket API2: Application Layer2Some network appsre-mailrwebrinstant messagingrremote loginrP2P file sharingrmulti-user network gamesrstreaming stored video clipsrsocial networksrvoice over IPrreal-time video conferencingrgrid computing2: Application Layer3Cre
3、ating a network appwrite programs thatvrun on (different) end systemsvcommunicate over networkve.g., web server software communicates with browser softwareNo need to write software for network-core devicesvNetwork-core devices do not run user applications vapplications on end systems allows for rapi
4、d app development, propagationapplicationtransportnetworkdata linkphysicalapplicationtransportnetworkdata linkphysicalapplicationtransportnetworkdata linkphysical2: Application Layer4Application architecturesrClient-servervIncluding data centers / cloud computingrPeer-to-peer (P2P)rHybrid of client-
5、server and P2P2: Application Layer5Client-server architectureserver: valways-on hostvpermanent IP addressvserver farms for scalingclients:vcommunicate with servervmay be intermittently connectedvmay have dynamic IP addressesclient/serverGoogle Data CentersrEstimated cost of data center: $600MrGoogle
6、 spent $2.4B in 2007 on new data centersrEach data center uses 50-100 megawatts of power2: Application Layer7Pure P2P architecturerno always-on serverrarbitrary end systems directly communicaterpeers are intermittently connected and change IP addressesHighly scalable but difficult to managepeer-peer
7、2: Application Layer8Hybrid of client-server and P2PSkypevvoice-over-IP P2P applicationvcentralized server: finding address of remote party: vclient-client connection: direct (not through server) Instant messagingvchatting between two users is P2Pvcentralized service: client presence detection/locat
8、ion user registers its IP address with central server when it comes online user contacts central server to find IP addresses of buddies2: Application Layer9Processes communicatingProcess: program running within a host.rwithin same host, two processes communicate using inter-process communication (de
9、fined by OS).rprocesses in different hosts communicate by exchanging messagesClient process: process that initiates communicationServer process: process that waits to be contacted2: Application Layer10Socketsrprocess sends/receives messages to/from its socketrsocket analogous to doorvsending process
10、 shoves message out doorvsending process relies on transport infrastructure on other side of door which brings message to socket at receiving processprocessTCP withbuffers,variablessockethost orserverprocessTCP withbuffers,variablessockethost orserverInternetcontrolledby OScontrolled byapp developer
11、rAPI: (1) choice of transport protocol; (2) ability to fix a few parameters 2: Application Layer11Addressing processesrto receive messages, process must have identifierrhost device has unique 32-bit IP addressrExercise: use ipconfig from command prompt to get your IP address (Windows)rQ: does IP add
12、ress of host on which process runs suffice for identifying the process?vA: No, many processes can be running on samerIdentifier includes both IP address and port numbers associated with process on host.rExample port numbers:vHTTP server: 80vMail server: 252: Application Layer12App-layer protocol def
13、inesrTypes of messages exchanged, ve.g., request, response rMessage syntax:vwhat fields in messages & how fields are delineatedrMessage semantics vmeaning of information in fieldsrRules for when and how processes send & respond to messagesPublic-domain protocols:rdefined in RFCsrallows for interoper
14、abilityre.g., HTTP, SMTP, BitTorrentProprietary protocols:re.g., Skype, ppstream2: Application Layer13What transport service does an app need?Data lossrsome apps (e.g., audio) can tolerate some lossrother apps (e.g., file transfer, telnet) require 100% reliable data transfer Timingrsome apps (e.g.,
15、Internet telephony, interactive games) require low delay to be “effective”Throughputrsome apps (e.g., multimedia) require minimum amount of throughput to be “effective”rAvailable bandwidthrother apps (“elastic apps”) make use of whatever throughput they get SecurityrEncryption, data integrity, 2: Ap
16、plication Layer14Transport service requirements of common appsApplicationfile transfere-mailWeb documentsreal-time audio/videostored audio/videointeractive gamesinstant messagingData lossno lossno lossno lossloss-tolerantloss-tolerantloss-tolerantno lossThroughputelasticelasticelasticaudio: 5kbps-1M
17、bpsvideo:10kbps-5Mbpssame as above few kbps upelasticTime Sensitivenononoyes, 100s msecyes, few secsyes, 100s msecyes and no2: Application Layer15Internet transport protocols servicesTCP service:rconnection-oriented: setup required between client and server processesrreliable transport between sendi
18、ng and receiving processrflow control: sender wont overwhelm receiver rcongestion control: throttle sender when network overloadedrdoes not provide: timing, minimum throughput guarantees, securityUDP service:runreliable data transfer between sending and receiving processrdoes not provide: connection
19、 setup, reliability, flow control, congestion control, timing, throughput guarantee, or security Q: why bother? Why is there a UDP?2: Application Layer16Internet apps: application, transport protocolsApplicatione-mailremote terminal accessWeb file transferstreaming multimediaInternet telephonyApplic
20、ationlayer protocolSMTP RFC 2821Telnet RFC 854HTTP RFC 2616FTP RFC 959HTTP (eg Youtube), RTP RFC 1889SIP, RTP, proprietary(e.g., Skype)Underlyingtransport protocolTCPTCPTCPTCPTCP or UDPtypically UDP2: Application Layer17Web and HTTPFirst some jargonrWeb page consists of objectsvObject can be HTML fi
21、le, JPEG image, Java applet, audio file,vHomepage rWeb page consists of base HTML-file which includes several referenced objectsvHypertext markup languagerEach object is addressable by a URL,Example URL:www.someschool.edu/someDept/pic.gifhost namepath name2: Application Layer18HTTP overviewHTTP: hyp
22、ertext transfer protocolrWebs application layer protocolvUsed for communication rclient/server modelvclient: browser that requests, receives, “displays” Web objectsvserver: Web server sends objects in response to requestsPC runningExplorerServer runningApache WebserverMac runningNavigatorHTTP reques
23、tHTTP requestHTTP responseHTTP response2: Application Layer19HTTP overview (continued)Uses TCP:rclient initiates TCP connection (creates socket) to server, port 80rserver accepts TCP connection from clientrHTTP messages (application-layer protocol messages) exchanged between browser (HTTP client) an
24、d Web server (HTTP server)rTCP connection closedHTTP is “stateless”rserver maintains no information about past client requestsProtocols that maintain “state” are complex!rpast history (state) must be maintainedrif server/client crashes, their views of “state” may be inconsistent, must be reconcileda
25、side2: Application Layer20HTTP connectionsNonpersistent HTTPrAt most one object is sent over a TCP connection.Persistent HTTPrMultiple objects can be sent over single TCP connection between client and server.2: Application Layer21Nonpersistent HTTPSuppose user enters URL www.someSchool.edu/someDepar
展开阅读全文