Chapter 1:Introduction Computer Networking: A Top Down Approach, 4 th edition. Jim Kurose, Keith Ross Advanced Computer Networks
Last Lecture What’s the Internet: “nuts and bolts” view What is a protocol? Packet and Circuit Switching Loss and Delay in packet Switching Networks Throughput
Today’s Lecture Queuing Delay Internet Protocol Stack Layered Architecture Chapter 2 Application Layer What Transport Service does an Application need? Internet Transport Protocols Services
What’s the Internet: “nuts and bolts” view Interconnects millions of computing devices: hosts = end systems running network apps Home network Institutional network Mobile network Global ISP Regional ISP router PC server wireless laptop cellular handheld wired links access points communication links fiber, copper, radio, satellite transmission rate = bandwidth (bits/sec) routers: forward packets (chunks of data)
What’s the Internet: “nuts and bolts” view protocols control sending, receiving of msgs e.g., TCP, IP, HTTP, Skype Internet: “network of networks” public Internet versus private intranet Internet standards IETF: Internet Engineering Task Force RFC: Request For Comments IETF standard Documents More than 5000 RFCs Home network Institutional network Mobile network Global ISP Regional ISP
What’s the Internet: A Service View Communication infrastructure that provides services to applications: Involve multiple end system that exchange data with each other. Web, VoIP, , games, e- commerce, file sharing Applications do not run on the routers Communication services provided to applications: reliable data delivery from source to destination (connection oriented) “best effort” (unreliable) data delivery (connection less)
What’s a protocol? human protocols: “what’s the time?” “I have a question” Interview … specific msgs sent … specific actions taken when msgs received, or other events network protocols: machines rather than humans all communication activity in Internet governed by protocols protocols define format, order of msgs sent and received among network entities, and actions taken on msg transmission, receipt
Network Core: Circuit Switching End-end resources reserved for the duration of the call Three phases Establish, Transfer, Disconnect dedicated resources: no sharing Guaranteed performance Very Reliable Developed for Telephone networks Inefficient Channel capacity dedicated for duration of connection If no data, capacity wasted Set up (connection) takes time
Network Core: Packet Switching Today’s internet is a packet switched network Each end-end data stream divided into packets Each packet contains a portion of user data plus some control info. Each packet has to find its own route to the destination No predetermined path Decision as to which node to hop to in the next step is taken only when a node is reached. Resources used as needed Congestion : packets queue, wait for link use Reliability Less Reliable Store and forward switching Switches receive complete packet before forwarding Question: What is Cut Through Switching?
Throughput The rate (bits/sec) at which bits are transferred between sender/receiver Difference between Bandwidth and Throughput? In computer networks, the throughput is less than the bandwidth for several reasons The channel may be shared by other users Packet loss due to congestion Packet loss due to bit errors Noise in the channel Transmission rates of the link over which the data flows.
Four sources of packet delay 1. Processing Delay: Time required to examine packet header and determine output link Check bit errors High Speed Routers Microseconds or less A B propagation transmission processing queueing 2. Queuing Delay: Time waiting at output link for transmission Depends on congestion level of router If queue empty no delay Microseconds to milliseconds
Delay in packet-switched networks 3. Transmission Delay: R=link bandwidth (bps) L=packet length (bits) Time to push all of packets bits into the link = L/R Microseconds to milliseconds 4. Propagation Delay: Time to propagate from the beginning of the link to the other router (node) Propagation delay = d/s d = length of physical link s = propagation speed in medium (~3x10 8 m/sec) A B propagation transmission nodal processing queueing
Queuing Delay R=Transmission Rate (bps) L=packet length(bits) a=average packet arrival rate(packets/sec) Traffic Intensity = (Average rate at which bits arrive at the queue) =La Transmission Rate R La/R ~ 0: average queuing delay small La/R -> 1: delays become large (queue begins to get larger) La/R > 1: average rate at which bits arrive at the queue exceeds the rate at which the bits can be transmitted from the queue. more “work” arriving than can be serviced Packet Loss will occur When is Queuing Delay large and when it is insignificant? Rate at which traffic arrives at the queue Transmission rate of the link Nature of the arriving traffic
Queuing Delay Consider the case La/R≤1 Nature of arriving traffic impacts queuing delay in such a case In reality the arrival process to a queue is random and arrivals do not follow any pattern.
Protocol Layers Networks are complex! many “pieces”: – hosts – routers – links of various media – applications – protocols – hardware, software Question: Is there any way of organizing network architecture? Answer: Yes possible with a layered architecture
Organization of air travel A series of steps(actions) ticket (purchase) baggage (check) gates (load) runway takeoff airplane routing ticket (complain) baggage (claim) gates (unload) runway landing airplane routing
Layering of Airline Functionality Airline functionality can be divided into layers, providing a frame work in which we can discuss air travel. At the ticketing layer and below – Airline-counter-to-airline-counter transfer of a person. At the gate layer – Departure-gate –to-arrival-gate transfer of a person is accomplished Layers: each layer implements a service – via its own internal-layer actions – Combined with the services directly below it ticket (purchase) baggage (check) gates (load) runway (takeoff) airplane routing departure airport arrival airport intermediate air-traffic control centers airplane routing ticket (complain) baggage (claim gates (unload) runway (land) airplane routing ticket baggage gate takeoff/landing airplane routing
Why layering? Dealing with complex systems: Discuss a well defined, specific part of a large and complex system Modularization eases maintenance, updating of system Change of implementation of layer’s service transparent to rest of system e.g. change in gate procedure doesn’t affect rest of system
Internet Protocol Stack To provide structure to design of network protocols, network designers organize protocols in layers Service – says what a layer does Protocol – says how the service is implemented Advantages Drawbacks When taken together the protocols of various layers are called the Protocol Stack. Internet Protocol Stack consists of Five layers Physical, Link, Network, Transport and Application layers. Organization of Book
Internet Protocol Stack Application Layer: Network applications and their application layer protocols reside. Provides user interfaces and support for services such as e- mail, file transfer etc. Hyper Text Transfer Protocol (HTTP) File Transfer Protocol (FTP) Session Initiation Protocol (SIP) An application layer protocol is distributed over multiple end systems The packets of information at the application layer is called as a message.
Internet Protocol Stack Transport Layer: Transports application-layer messages between application end points. Transport layer packet is called as a segment Breaks long messages into shorter segments There are two Transport Layer Protocols Transmission Control Protocol (TCP) Connection Oriented service Guaranteed delivery of application layer messages Flow control Congestion Control User Datagram Protocol (UDP) Connectionless service No reliability, flow control and congestion control
Internet Protocol Stack Network Layer: Responsible for moving network layer packets known as datagrams from one host to another. Transport layer passes a transport layer segment and a destination address to the network layer. Network layer includes IP Protocol Defines the fields in the datagram as well as how end systems and routers act on these fields Different routing protocols. Determine the route that datagrams take between sources and destinations
Internet Protocol Stack Link Layer: Moves a packet from one node (host or router) to the next node in the route. Divide the stream of bits received from the network layer into manageable data units called frames. Transforms a raw transmission facility to a reliable link. Mechanism to detect and retransmit damaged or lost frames Example of link layer protocols include WiFi, Ethernet etc.
Internet Protocol Stack Physical Layer: The job of this layer is to move the individual bits with in frames from one node to next. Representation of bits Physical Layer data consists of a stream of bits (0 or 1) To be transmitted bits must be encoded into signals. The physical layer defines the type of encoding. The protocol in this layer depend on the actual transmission medium of the link.
Internet Protocol Stack Application: Provides user interfaces and support for services such as , file transfer etc. FTP, HTTP Transport: Transports application-layer messages between application end points. Segmentation and reassembly TCP, UDP Network: Routing of Datagrams from source to destination IP, routing protocols Link: Move a packet from one node (host or router) to the next node in the route. Ethernet, WiFi Physical: Move the individual bits with in frames from one node to next Application Transport Network Link Physical
source application transport network link physical segment datagram destination application transport network link physical router switch Encapsulation message HtHt HnHn M HtHt HtHt HnHn HlHl M HtHt HnHn M HtHt M M network link physical link physical HtHt HnHn HlHl M HtHt HnHn M HtHt HnHn M HtHt HnHn HlHl M M HtHt M HnHn frame
OSI Reference Model In 1970 International Organization for Standardization proposed a seven layered model called Open Systems Interconnection (OSI) model. Presentation Layer: Provide services such as data encryption, compression. Session Layer: Synchronization points (checkpointing) and recovery of data exchange. Internet stack “missing” these layers! these services, if needed, must be implemented in the application by the application developer.
Chapter 1-- Introduction What is Internet? What is a Protocol? Circuit Switching and Packet Switching Loss and Delay in Packet Switching Networks Queuing Delay in Packet Switching Networks Throughput in Packet Switching Networks Internet Protocol Stack—Five Layers
Chapter 2 Application Layer Computer Networking: A Top Down Approach, 4 th edition. Jim Kurose, Keith Ross Addison-Wesley, July 2007.
Chapter 2: Application layer Principles of Network Applications Hyper Text Transfer Protocol (HTTP) File Transfer Protocol (FTP) Electronic Mail ( ) SMTP, POP3, IMAP Domain Name System (DNS)
Some Network Applications Web Instant messaging Remote login P2P file sharing Multi-user network games Streaming stored video clips Voice over IP Real-time video conferencing Many more interesting applications
Creating a Network Application write programs that run on (different) end systems communicate over network e.g., web server software communicates with browser software No need to write software for network-core devices Network-core devices do not run user applications Function at lower layers Basic design is to confine application software to the end systems Facilitate rapid network application development and deployment application transport network data link physical application transport network data link physical application transport network data link physical
Application Architectures Application Architecture is Designed by the application developer Dictates how the application is structured over various end systems Two architectures used in modern day Network Applications: Client-Server Architecture Peer-to-Peer (P2P) Architecture
Client-Server Architecture Server: Always-on host Permanent well defined IP address A single server is incapable of keeping up with all the requests of the clients. A cluster of hosts referred as server farm is often used. Clients: Communicate with server May have dynamic IP addresses Do not communicate directly with each other Client/Server architecture is infrastructure intensive Require service providers to install and maintain servers. Client/Server
P2P Architecture Direct communication between pairs of intermittently connected hosts called peers Peers are not owned by any service provider P2P Peers communicate without passing through any dedicated server e.g. Bit Torrent, eMule, Skype Security issues Highly Distributive Cost Effective peer-peer
Sockets r Process sends/receives messages to/from its socket r Interface between application layer and transport layer within a host. r Socket analogous to door Sending process shoves message out of the door Sending process relies on transport infrastructure on other side of door which brings message to socket at receiving process process TCP with buffers, variables socket host or server process TCP with buffers, variables socket host or server Internet controlled by OS controlled by app developer
What Transport Service does an Application need? Data Loss (Reliability) Loss Tolerant Applications Some apps (e.g., audio, VoIP) can tolerate some loss 2% tolerable for VoIP Other apps (e.g., file transfer, ) require 100% reliable data transfer Timing Tight timing constraints Multiplayer games, VoIP, teleconferencing. In Non-real time lower delays are preferred but no tight constraint on end-to-end delays. Throughput r Bandwidth sensitive applications (e.g., multimedia) require minimum amount of throughput r Other apps (“elastic apps”) make use of whatever throughput they get e.g. , file transfer Security r Encryption, end point authentication
Transport Service Requirements of Common Applications Application file transfer Web documents real-time audio/video stored audio/video interactive games Data loss no loss loss-tolerant Throughput elastic audio: 5kbps-1Mbps video:10kbps-5Mbps same as above few kbps -10kbps Time Sensitive no yes, 100’s msec yes, few secs yes, 100’s msec
Internet Transport Protocols Services TCP Service: connection-oriented: setup required between client and server processes reliable transport between sending and receiving process flow control: sender won’t overwhelm receiver congestion control: throttle sender when network overloaded does not provide: timing, minimum throughput guarantees, security UDP Service: unreliable data transfer between sending and receiving process does not provide: connection setup, reliability, flow control, security Throughput and timing guarantee not provided
Home Assignment Secure Sockets Layer (SSL)