Switching Strategies • Circuit switching – set up a dedicated route ( “ circuit ” ) first – carry all bits of a “ conversation ” on one circuit • original telephone network • Analogy: railroads and trains/subways • Packet switching – divide information into small chunks ( “ packets ” ) – each packet delivered independently – “ store-and-forward ” packets Internet • (also Postal Service, but they don ’ t tear your mail into pieces first!) • Analogy: highways and cars • Pros and Cons? - think taking subways vs. driving cars, during off-peak vs. rush hours! CSci4211: Introduction 27
Analogy: railroad and train 28 CSci4211: Introduction
Analogy: Highway and cars 29 CSci4211: Introduction
Circuit Switching network resources dividing link bandwidth (e.g., bandwidth) into “pieces” divided into “pieces” frequency division • pieces allocated to calls time division • resource piece idle if code division not used by owning call (no sharing) Trivia Q: You must have heard of the term “CDMA” (think the company Qualcom, for which it is most associated with), what does “CD” in CDMA stands for? 30 CSci4211: Introduction
Circuit Switching: FDM and TDM Example: FDM 4 users frequency time TDM frequency time 31 CSci4211: Introduction
Numerical example • How long does it take to send a file of 640,000 bits from host A to host B over a circuit-switched network? – All links are 1.536 Mbps – Each link uses TDM with 24 slots/sec – 500 msec to establish end-to-end circuit Let’s work it out! 10.5 seconds CSci4211: Introduction 32
Networks with Circuit Switching e.g., conventional (fixed-line) telephone networks End-end resources reserved for “call” • link bandwidth, switch capacity • dedicated resources: no sharing • circuit-like (guaranteed) performance • call setup required CSci4211: Introduction 33
Circuit Switched Networks • All resources (e.g. communication links) needed by a call dedicated to that call for its duration – Example: telephone network – Call blocking when all resources are used CSci4211: Introduction 34
Packet Switching Each end- end “data stream” resource contention: divided into packets aggregate resource • users A, B packets share demand can exceed network resources amount available • each packet uses full link congestion: packets bandwidth queue, wait for link use • resources used as needed store and forward: packets move one hop at a time Bandwidth division into “pieces” Node receives complete packet before forwarding Dedicated allocation Packets may suffer delay or Resource reservation losses! CSci4211: Introduction 35
Statistical Multiplexing • Time division, but on demand rather than fixed • Reschedule link on a per-packet basis • Packets from different sources interleaved on the link • Buffer packets that are contending for the link • Buffer buildup is called congestion • This is packet switching, used in computer networks CSci4211: Introduction 36
Packet Switching: Statistical Multiplexing 100 Mb/s C A Ethernet statistical multiplexing 1.5 Mb/s B queue of packets waiting for output link D E Sequence of A & B packets does not have fixed pattern, shared on demand statistical multiplexing . TDM: each host gets same slot in revolving TDM frame. CSci4211: Introduction 37
Packet-switching: store-and-forward L R R R • Takes L/R seconds to Example: transmit (push out) • L = 7.5 Mbits packet of L bits on to link or R bps • R = 1.5 Mbps 15 sec • Entire packet must • delay = ? arrive at router before it can be transmitted on next link: store and forward • delay = 3L/R (assuming zero propagation delay) more on delay later … 38 CSci4211: Introduction
Packet switching versus circuit switching Packet switching allows more users to use network! • 1 Mb/s link • each user: – 100 kb/s when “active” N users – active 10% of time 1 Mbps link • circuit-switching: – 10 users Q: how did we get value 0.0004? • packet switching: – with 35 users, probability > 10 active M M M n n p 1 p less than .0004 n n N 1 39 CSci4211: Introduction
Circuit Switching vs Packet Switching Item Circuit-switched Packet-switched Dedicated “ copper ” path Yes No Bandwidth available Fixed Dynamic Potentially wasted bandwidth Yes No (not really!) Store-and-forward transmission No Yes Each packet/bit always follows Yes Not necessarily the same route Call setup Required Not Needed When can congestion occur At setup time On every packet Effect of congestion Call blocking Queuing delay CSci4211: Introduction 40
Packet switching vs. circuit switching Is packet switching a “slam dunk winner?” • Great for bursty data – resource sharing – simpler, no call setup • Excessive congestion: packet delay and loss – protocols needed for reliable data transfer, congestion control • Q: How to provide circuit-like behavior? – bandwidth guarantees needed for audio/video apps – still an unsolved problem (chapter 7) Q: human analogies of reserved resources (circuit switching) versus on-demand allocation (packet-switching)? 41 CSci4211: Introduction
What’s so special about the Internet? Internet is based on the notion of “ packet switching ” • – enables statistical multiplexing – better utilization of network resources for transfer of “ bursty ” data traffic Internet’s key organizational/architectural principle: • “smart” end systems + “dumb” networks – architecture: functional division & function placement – hourglass Internet architecture: enables diverse applications and accommodates evolving technologies – “dumb” network (core) : simple packet-switched, store- forward, connectionless “datagram” service, with core functions: global addressing, routing & forwarding – “smart” end systems/edges : servers, PCs, mobile devices, …; diverse and ever-emerging new applications! CSci4211: Introduction 42
Internet Hourglass Architecture enabling diverse applications & new types of end devices p2p file sharing, skype, YouTube, Netflix, Cloud Computing bitTorrent, DHT, SIP, DASH, …. network edge/end hosts accommodating evolving & new technologies network core WiFi, Bluetooth, Docsis, gMPLS, DWDM/fiber, …, 3G/4G cellular, …. CSci4211: Introduction 43
“Dumb” Networks & “Smart” End Systems • Five Layer Architecture: – Lower three layers are implemented everywhere – Top two layers are implemented only at hosts Host A Host B Application Application Transport Transport Router Network Network Network Datalink Datalink Datalink Physical Physical Physical Physical medium 44 CSci4211: Introduction
An Overview of Network Structure: a “horizontal view” • network edge: applications and hosts • network core: – routers – network of networks • access networks, physical media: communication links 45 CSci4211: Introduction
What’s the Internet: “nuts and bolts” view • millions of connected router workstation computing devices: hosts server = end systems mobile • running network apps local ISP • communication links – fiber, copper, radio, satellite regional ISP – transmission rate = bandwidth • routers: forward packets (chunks of data) company network 46 CSci4211: Introduction
The network edge: • end systems (hosts): – run application programs – e.g. Web, email – at “edge of network” • client/server model – client host requests, receives service from always-on server – e.g. Web browser/server; email client/server • peer-peer model: – minimal (or no) use of dedicated servers – e.g. Skype, BitTorrent, KaZaA 47 CSci4211: Introduction
The network edge: • end systems (hosts): – run application programs – e.g. Web, email – at “edge of network” • client/server model – client host requests, receives service from always-on server – e.g. Web browser/server; email client/server – Cloud & Mobile Computing • peer-peer model: – minimal (or no) use of dedicated servers – e.g. Skype, BitTorrent, KaZaA cloud computing 48 CSci4211: Introduction
Network edge: connection-oriented service Goal: data transfer TCP service [RFC 793] between end systems • reliable, in-order byte- • handshaking: setup stream data transfer (prepare for) data – loss: acknowledgements transfer ahead of time and retransmissions – Hello, hello back human • flow control: protocol – sender won’t overwhelm – set up “state” in two receiver communicating hosts • congestion control: • TCP - Transmission Control Protocol – senders “slow down sending rate” when network – Internet’s connection - congested oriented service CSci4211: Introduction 49
Network edge: connectionless service Goal: data transfer App’s using TCP: between end systems • HTTP (Web), FTP (file – same as before! transfer), Telnet • UDP - User Datagram (remote login), SMTP Protocol [RFC 768]: (email), Flash videos, – connectionless DASH stream videos – unreliable data transfer App’s using UDP: – no flow control • streaming media, – no congestion control teleconferencing, DNS, Internet telephony CSci4211: Introduction 50
The Network Core • mesh of interconnected routers shared by many users • the fundamental questions: – how network is shared – how to find the other party (person, website, …) you want – how is data transferred through net? 51 CSci4211: Introduction
On the Internet Edge … • Large # of (mobile & stationary) users • Large # of “dumb” or social networks music smart devices & games video streaming web streaming appliances & IPTV • Some “always - on,” high - others speed connection Internet smart pads & • Others intermittent home users e-readers connectivity with varying bandwidth sensors & smart home • Diverse applications surveillance and services VoIP banking & & security e-commerce • Heterogeneous dumb & technologies smart phones POTS 52 CSci4211: Introduction
Within the Internet “Cloud” Network Core: • big ISPs (& cellular providers) with large geographical span • As well as medium & smaller ISPs And the “other end/edge”: • big content providers with huge data centers High bandwidth, dense and rich topology Enormous computing & storage capacities to support cloud, mobile computing/services 53 CSci4211: Introduction
Well, Internet is too complex for me to learn. How can they even build it? And what’s a protocol & why do we need protocols? Motivating Questions 3-5 54 CSci4211: Introduction
Network Architecture (or organizational principles) Networks are complex! Question: • many “pieces”: Is there any hope of – hosts organizing structure or – routers principle of network? – links of various media – hardware, software Or at least our discussion of – applications networks? – protocols – ….. Network architecture: “blue prints” (or principles) regarding functional division and function placement 55 CSci4211: Introduction
Organization of air travel ticket (purchase) ticket (complain) baggage (check) baggage (claim) gates (load) gates (unload) runway takeoff runway landing airplane routing airplane routing airplane routing • a series of steps 56 CSci4211: Introduction
Layering of airline functionality ticket (purchase) ticket (complain) ticket baggage (check) baggage (claim baggage gates (load) gates (unload) gate runway (takeoff) runway (land) takeoff/landing airplane routing airplane routing airplane routing airplane routing airplane routing departure intermediate air-traffic arrival airport control centers airport Layers: each layer implements a service – via its own internal-layer actions – relying on services provided by layer below 57 CSci4211: Introduction
Why Layering? Dealing with complex systems: • explicit structure allows identification, relationship of complex system’s pieces – layered reference model for discussion • 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 58 CSci4211: Introduction
Internet Protocol Stack • application: supporting network applications – FTP, SMTP, HTTP, DASH, … application • transport: process-process data transfer transport – TCP, UDP • network: routing of datagrams from network source to destination link – IP, routing protocols • link: data transfer between physical neighboring network elements – PPP, Ethernet • physical: bits “on the wire” 59 CSci4211: Introduction
Layered Architecture • Layering simplifies the architecture of complex system • Layer N relies on services from layer N-1 to provide a service to layer N+1 • Interfaces define the services offered • Service required from a lower layer is independent of its implementation – Layer N change doesn ’ t affect other layers – Information/complexity hiding – Similar to object oriented methodology CSci4211: Introduction 60
Protocols and Services • Protocols are used to implement services – Peering entities in layer N provide service by communicating with each other using the service provided by layer N-1 • Logical vs physical communication CSci4211: Introduction 61
What’s a protocol? human protocols: network protocols: • “what’s the time?” • machines rather than • “I have a question” humans • introductions • all communication activity in Internet governed by protocols (why this concept is so important!!!) 62 CSci4211: Introduction
Human protocol Alice • protocols define: Bob – Format. Hi – Order of msgs sent and received among network Hi entities (two or more) Got the – Actions taken on msg time? transmission, receipt 2:00pm Q: What are the purposes of first hi-hi exchange 2 Bob can understand English 1. Make sure Bob is awake 3 4 Bob can speak English Bob is willing to talk 63 CSci4211: Introduction
What’s a protocol? a human protocol and a computer network protocol: Hi TCP connection request Hi TCP connection Got the response time? Get http://www.cnn.com 2:00 <file> time Q: Other human protocols? (e.g., in-class interaction) CSci4211: Introduction 64
Protocols • Protocol : rules by which network elements communicate • Protocols define the agreement between peering entities – The format and the meaning of messages exchanged • Protocols in everyday life – Examples: traffic control, open round-table discussion etc CSci4211: Introduction 65
Protocol Packets • Protocol data units (PDUs): – packets exchanged between peer entities • Service data units (SDUs): – packets handed to a layer by an upper layer • Data at one layer is encapsulated in packet at a lower layer – Envelope within envelope: PDU = SDU + (optional) header or trailer CSci4211: Introduction 66
Encapsulation source message application M segment transport H t H t M network datagram H n H n H t M link frame H l H n H t M physical link physical switch destination network H n H t M link H l H n H t M application H n H t M M physical transport H t M network H n H t M router link H l H n H t M physical CSci4211: Introduction 67
Internet and ISO/OSI Reference Models CSci4211: Introduction 68
ISO/OSI Reference Model • Application layer • Examples: smtp, http, ftp, dash, etc – process-to-process communication – all layers exist to support this layer • Presentation layer (OSI only) – conversion of data to common format • Example: “little endian” vs. “big endian” byte orders – multimedia streaming presentation (e.g., mpeg-dash) • Session layer (OSI only) – session setup (and authentication) – recovery from failure (broken session) • Internet applications perform presentation/session layer functions , e.g., “little” & “big” endian conversions CSci4211: Introduction 69
ISO/OSI Reference Model (cont ’ d) • Transport layer: end-to-end data delivery, e.g., – connection-oriented (TCP) or connection-less (UDP) services – error control, flow/congestion control, … • Network layer: examples: IP, X.25 – (global) naming and addressing, routing (build routing tables) – forwarding packets hop-by-hop across networks – avoidance of congested/failed links, traffic engineering, … • Data link layer: data transfer between “neighboring” elements – Examples: Ethernet, 802.11 WiFi, PPP – framing and error/flow control – media access control • Physical layer (EE stuff) – encoding/decoding information (bits) into physical media – modulating & transmitting raw bits (0/1) over wire CSci4211: Introduction 70
Comments on Layering • Layering simplifies the architecture of complex system • Advantages – modularization eases maintenance and updating – hide lower layer complexity/implementation details from higher layers • Layering considered harmful? – Q: which layer should implement what functionality? • e.g., reliability, hop-by-hop basis or end-to-end basis? • Possible Drawbacks? – possible duplication of functionality between layers • error recovery at link layer and transport layer – Other possible drawbacks? CSci4211: Introduction 71
Internet Protocol “ Zoo ” ….. ….. Flash DASH RealVideo RealAudio SOAP IPTV NFS/RPC DNS applicatio HTTP VoIP FTP, SCP P2P n telnet, ssh SMTP ICMP, OSPF, RIP, BGP, … MPLS/gMPLS PPP 2.5G/3G/4G 802.11 WiFi (GPRS,UMTS, DWDM WiMAX, LTE, DSL or …) Cellular DOCSIS Radio Networks CSci4211: Introduction 72
What real Internet looks like now? CSci4211: Introduction 73
Internet Structure Internet: “ networks of networks ” ! International lines IXPs or private peering National or Internet National or tier-1 ISP eXcange tier-1 ISP Regional Points ISPs Regional or company university local ISP local ISPs company LANs Home users access via WiFi Home users hotspots CSci4211: Introduction 74
Internet structure: network of networks • Roughly hierarchical • At center: “tier - 1” ISPs (e.g., Verizon, Sprint, AT&T, L3, Cable and Wireless), national/international coverage – treat each other as equals Tier-1 providers also interconnect Tier-1 Tier 1 ISP at Internet providers Exchange Point IXP interconnect (peer) privately Tier 1 ISP Tier 1 ISP CSci4211: Introduction 75
Tier-1 ISP: e.g., Sprint POP: point-of-presence to/from backbone peering … … . … … … to/from customers CSci4211: Introduction 76
Internet structure: network of networks • “Tier - 2” ISPs: smaller (often regional) ISPs – Connect to one or more tier-1 ISPs, possibly other tier-2 ISPs Tier-2 ISPs also peer Tier-2 ISP pays Tier-2 ISP Tier-2 ISP privately with tier-1 ISP for Tier 1 ISP each other, connectivity to interconnect IXP rest of Internet at IXP tier-2 ISP is c ustomer of Tier 1 ISP Tier 1 ISP tier-1 provider Tier-2 ISP Tier-2 ISP Tier-2 ISP CSci4211: Introduction 77
Internet structure: network of networks • “Tier - 3” ISPs and local ISPs – last hop (“access”) network (closest to end systems) local local Tier 3 ISP local local ISP ISP ISP ISP Local and tier- Tier-2 ISP Tier-2 ISP 3 ISPs are Tier 1 ISP customers of higher tier IXP ISPs connecting them to rest Tier 1 ISP Tier 1 ISP Tier-2 ISP of Internet local Tier-2 ISP Tier-2 ISP ISP local local local ISP ISP ISP 78 CSci4211: Introduction
Internet structure: network of networks • a packet passes through many networks! traceroute www.cnn.com A local local Tier 3 ISP local local ISP ISP ISP ISP Routing & Tier-2 ISP Tier-2 ISP forwarding: Tier 1 ISP how do IXP packets go from A to B? Tier 1 ISP Tier 1 ISP Tier-2 ISP local Tier-2 ISP Tier-2 ISP B ISP local local local ISP ISP ISP 79 CSci4211: Introduction
Map of Internet
Why it takes so long to download my friends’ pictures from web? Or why $#@! can’t I access the Internet now? Motivating Question 6 CSci4211: Introduction 81
Fundamental Problems in Networking … Or what can go wrong? • Bit-level errors: due to electrical interferences • “Frame - level” errors: media access delay or frame collision due to contention/collision/interference • Packet-level errors: packet delay or loss due to network congestion/buffer overflow • Out of order delivery: packets may takes different paths • Link/node failures: cable is cut or system crash CSci4211: Introduction 82
Four sources of packet delay 1. nodal processing: 2. queueing • check bit errors time waiting at output link • for transmission • determine output link depends on congestion level • of router transmission A propagation B nodal queueing processing 83 CSci4211: Introduction
Delay in packet-switched networks 4. Propagation delay: 3. Transmission delay: • d = length of physical link • R=link bandwidth (bps) • s = propagation speed in • L=packet length (bits) medium (~2x10 8 m/sec) • time to send bits into • propagation delay = d/s link = L/R transmission A propagation B Note: s and R are very nodal queueing processing different quantitites! CSci4211: Introduction 84
Nodal delay d d d d d nodal proc queue trans prop • d proc = processing delay – typically a few microsecs or less • d queue = queuing delay – depends on congestion • d trans = transmission delay – = L/R, significant for low-speed links • d prop = propagation delay – a few microsecs to hundreds of msecs 85 CSci4211: Introduction
Statistical Multiplexing and Queueing 10 Mbs C A Ethernet statistical multiplexing 1.5 Mbs B queue of packets 45 Mbs waiting for output link D E CSci4211: Introduction 86
Queueing delay (revisited) • R=link bandwidth (bps) • L=packet length (bits) • a=average packet arrival rate traffic intensity = La/R • La/R ~ 0: average queueing delay small • La/R -> 1: delays become large • La/R > 1: more “ work ” arriving than can be serviced, average delay infinite! CSci4211: Introduction 87
Queueing delay and Packet loss • Queue (aka buffer) preceding link in buffer has finite capacity • When packet arrives to full queue, packet is dropped (aka lost) • lost packet may be retransmitted by previous node, by source end system, or not retransmitted at all 88 CSci4211: Introduction
“Real” Internet delays and routes • What do “real” Internet delay & loss look like? • Traceroute program: provides delay measurement from source to router along end-end Internet path towards destination. For all i: – sends three packets that will reach router i on path towards destination – router i will return packets to sender – sender times interval between transmission and reply. 3 probes 3 probes 3 probes 89 CSci4211: Introduction
“Real” Internet delays and routes Let’s Traceroute to www.bbc.com 90 CSci4211: Introduction
Throughput • throughput: rate (bits/time unit) at which bits transferred between sender/receiver – instantaneous: rate at given point in time – average: rate over longer period of time link capacity link capacity server, with pipe that can carry pipe that can carry server sends bits R s bits/sec R c bits/sec file of F bits fluid at rate fluid at rate (fluid) into pipe to send to client R s bits/sec) R c bits/sec) CSci4211: Introduction 91
Throughput (cont’d) • R s < R c What is average end-end throughput? R s bits/sec R c bits/sec R s > R c What is average end-end throughput? R s bits/sec R c bits/sec bottleneck link link on end-end path that constrains end-end throughput 92 CSci4211: Introduction
Throughput: Internet scenario R s • per-connection R s R s end-end throughput: R min(R c ,R s ,R/10) • in practice: R c or R c R c R s is often R c bottleneck 10 connections (fairly) share backbone bottleneck link R bits/sec CSci4211: Introduction 93
What’s the Internet: Recap • protocols control sending, router receiving of messages workstation server – e.g., TCP, IP, HTTP, FTP, PPP mobile • Internet: “network of local ISP networks” – loosely hierarchical – public Internet versus regional ISP private intranet • Internet standards – RFC: Request for comments – IETF: Internet Engineering Task Force company – IEEE network CSci4211: Introduction 94
Fundamental Issues in Networking Network is a shared resource – Provide services for many people at same time – Carry bits/information for many people at same time • Switching and Multiplexing – How to share resources among multiple users, and transfer data from one node to another node • Naming and Addressing – How to find name/address of the party (or parties) you would like to communicate with – Address: byte-string that identifies a node • unicast, multicast and broadcast addresses • Routing and Switching/Forwarding: – process of determining how to send packets towards the destination based on its address: finding out neighbors, building routing tables – transferring data from source to destination CSci4211: Introduction 95
Fundamental Problems in Networking … Or what can go wrong? • Bit-level errors: due to electrical interferences • “Frame - level” errors: media access delay or frame collision due to contention/collision/interference • Packet-level errors: packet delay or loss due to network congestion/buffer overflow • Out of order delivery: packets may takes different paths • Link/node failures: cable is cut or system crash CSci4211: Introduction 96
Fundamental Problems in Networking What can be done? • Add redundancy to detect and correct erroneous packets • Acknowledge received packets and retransmit lost packets • Assign sequence numbers and reorder packets at the receiver • Sense link/node failures and route around failed links/nodes Goal: to fill the gap between what applications expect and what underlying technology provides CSci4211: Introduction 97
The Internet Network layer Transport layer: TCP, UDP IP protocol Routing protocols • addressing conventions • path selection • packet handling conventions • RIP, OSPF, BGP Network layer routing ICMP protocol table • error reporting • router “ signaling ” Data Link layer (Ethernet, WiFi, PPP, …) Physical Layer (fiber optics, radio, …) CSci4211: Introduction 98
Introduction: Summary You now have: Answers to 6 motivating questions • context, overview, • What is internet? What so “feel” of special about it? networking • What internet looks like now? • more depth, detail • How I deal with the complexity? to follow! • What’s a protocol? • How I build a network? • Why do I suffer delays? 99 CSci4211: Introduction
Internet Summary • Computer networks/Internet use packet switching • Layered architecture for handling complexity & attaining maintainability – Key notions: protocols, services and interfaces • Internet is based on TCP/IP protocol suite – Networks of networks! – Shared, distributed and complex system in global scale – No centralized authority • Fundamental issues in networking – addressing/naming – routing/forwarding – error/flow/congestion control, media access control CSci4211: Introduction 100
Recommend
More recommend