CMPE 344 Computer Networks Spring Foundations. Reading: Peterson and Davie,

Similar documents
CS 428/528 Computer Networks Lecture 01. Yan Wang

L1: Introduction. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

CS455: Introduction to Distributed Systems [Spring 2018] Dept. Of Computer Science, Colorado State University

Introductions. Computer Networking Lecture 01. January 16, HKU SPACE Community College. HKU SPACE CC CN Lecture 01 1/36

Computer Networks. Text Book By Larry L Peterson & Bruce S. Davie

Slides are an edited mashup of two books

Islamic University of Gaza Faculty of Engineering Department of Computer Engineering ECOM 4021: Networks Discussion. Chapter 1.

Module 2 Overview of Computer Networks

Module 2 Overview of. Computer Networks

ECE 650 Systems Programming & Engineering. Spring 2018

CSE3213 Computer Network I

CSCI Computer Networks

A closer look at network structure:

Lecture 2: Internet Structure

Computer Networking. Introduction. Quintin jean-noël Grenoble university

Digital Communication Networks

Chapter I: Introduction

Data Networks. Lecture 1: Introduction. September 4, 2008

Data & Computer Communication

Chapter 1: Conceptual Basis Section 1

Internet Architecture & Performance. What s the Internet: nuts and bolts view

Reti di Calcolatori I

Announcements. CS 5565 Network Architecture and Protocols. Outline for today. The Internet: nuts and bolts view. The Internet: nuts and bolts view

CS3600 SYSTEMS AND NETWORKS

Next Steps Spring 2011 Lecture #18. Multi-hop Networks. Network Reliability. Have: digital point-to-point. Want: many interconnected points

CS321: Computer Networks Introduction to Computer Networks and Internet

Basics of datacommunication

Announcements Computer Networking. What is the Objective of the Internet? Today s Lecture

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet

PLEASE READ CAREFULLY BEFORE YOU START

Introduction to Networks

PLEASE READ CAREFULLY BEFORE YOU START

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Goals and topics. Verkkomedian perusteet Fundamentals of Network Media T Circuit switching networks. Topics. Packet-switching networks

Chapter 1. Computer Networks and the Internet

end systems, access networks, links circuit switching, packet switching, network structure

TCP/IP THE TCP/IP ARCHITECTURE

Data and Computer Communications. Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based Applications

Computer Networks and the Internet. CMPS 4750/6750: Computer Networks

Networks Overview. Dr. Yingwu Zhu

Introduction. General requirements

Computer Communication Networks

Part 1: Introduction. Goal: Review of how the Internet works Overview

EEC-484/584 Computer Networks

L2: Bandwidth and Latency. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

PLEASE READ CAREFULLY BEFORE YOU START

PLEASE READ CAREFULLY BEFORE YOU START

Since enrollment is very small this semester, we have flexibilty. Traditional lecture Assigned reading, and then student(s) present during class time

Read Chapter 1 of Kurose-Ross

Operating Systems. 16. Networking. Paul Krzyzanowski. Rutgers University. Spring /6/ Paul Krzyzanowski

Overview. Performance metrics - Section 1.5 Direct link networks Hardware building blocks - Section 2.1 Encoding - Section 2.2 Framing - Section 2.

Computer Communication & Networks / Data Communication & Computer Networks Week # 03

Welcome to CS 340 Introduction to Computer Networking

Computer Networks. General Course Information. Addressing and Routing. Computer Networks 9/8/2009. Basic Building Blocks for Computer Networks

Announcements. TAs office hours: Mohamed Grissa: Mohamed Alkalbani:

Web Protocols and Practice

ECE 650 Systems Programming & Engineering. Spring 2018

CSC 401 Data and Computer Communications Networks

Introduction to computer networking

2 Network Basics. types of communication service. how communication services are implemented. network performance measures. switching.

Lecture 3 Protocol Stacks and Layering

Introduction. Introduction to Network Communications G64INC. Lectures. Related Modules. Assessment. Objectives

Peer entities. Protocol Layering. Protocols. Example

Networking and Internetworking 1

CS-435 spring semester Network Technology & Programming Laboratory. Stefanos Papadakis & Manolis Spanakis

CS 3516: Computer Networks

Communicating over the Network

precise rules that govern communication between two parties TCP/IP: the basic Internet protocols IP: Internet protocol (bottom level)

end systems, access networks, links 1.3 network core

CS 332: Computer Networks Introduction

CSEN 503 Introduction to Communication Networks

Need For Protocol Architecture

UNIT 2 TRANSPORT LAYER

Need For Protocol Architecture

Defining the Internet

COMPUTER NETWORKS CS CS 55201

Network Management & Monitoring

Just enough TCP/IP. Protocol Overview. Connection Types in TCP/IP. Control Mechanisms. Borrowed from my ITS475/575 class the ITL

COMP 562: Advanced Topics in Networking

ECPE / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition

Chapter 1: Introduction

IT4405 Computer Networks (Compulsory)

Announcements. No book chapter for this topic! Slides are posted online as usual Homework: Will be posted online Due 12/6

Networking Applications

CS348: Computer Networks Introduction to Computer Networks and Internet

Communication Networks

Reference Models. 7.3 A Comparison of the OSI and TCP/IP Reference Models

COMPUTER NETWORKS CS CS 55201

No book chapter for this topic! Slides are posted online as usual Homework: Will be posted online Due 12/6

5105: BHARATHIDASAN ENGINEERING COLLEGE NATTARMPALLI UNIT I FUNDAMENTALS AND LINK LAYER PART A

===================================================================== Exercises =====================================================================

Computer Networks. More on Standards & Protocols Quality of Service. Week 10. College of Information Science and Engineering Ritsumeikan University

CS 421: COMPUTER NETWORKS SPRING FINAL May 16, minutes

Transport Protocols Reading: Sections 2.5, 5.1, and 5.2. Goals for Todayʼs Lecture. Role of Transport Layer

Homework 1. Question 1 - Layering. CSCI 1680 Computer Networks Fonseca

Chapter 1 Introduction

Overview of Networks

Lecture 19. Principles behind data link layer services Framing Multiple access protocols

Computer Networks. Southeast University 东南大学止于至善. Nanjing, Jiangsu China. June 3 rd 23 rd, 2013

Communication Networks - 3 general areas: data communications, networking, protocols

Transcription:

CMPE 344 Computer Networks Spring 2017 Foundations Reading: Peterson and Davie, 1.1-1.5 Sources of slides: Computer networks: A systems Approach by Peterson and Davie, Morgan Kaufmann, 2010 CN5E by Tanenbaum & Wetherall, Pearson Education-Prentice Hall and D. Wetherall, 2011 Computer Networking by Jim Kurose, Keith Ross, Pearson/Addison Wesley, 2016 26/07/2018 1

Goals of CMPE 344 Emphasize on design choices made when building computer networks Understand why networks are designed the way they are Discuss systems approach to understand the big picture Gain insight on architectural implications and interaction of components rather than focusing on rigidly defined layers 2

Network Applications Most people are familiar with network through applications: World Wide Web Email Online social network Streaming audio/video Videoconferencing (e.g. Skype TM ) File sharing Instant messaging and many more 3

Links and nodes A link is a physical medium that connects computers or nodes. A node is a piece of hardware such as a PC, a switch, a router, etc. Key challenge in network design: Scalability A system that is designed to support growth to an arbitrarily large size is said to scale How should we connect all the nodes in the world? 4

Connectivity: Direct links (a) (b) (a) Point-to-point (b) Multiple access (Sharing a single physical link) 5

Connectivity: Switched network Connectivity between two nodes does not necessarily imply a direct physical connection between them Nodes can be indirectly connected: A switched network contains forwarding nodes or switches 6

Types of switched networks Circuit-switched networks Telephone networks A dedicated circuit across a sequence of links is established. Source node sends a stream of bits across this circuit to a destination node Packet-switched networks Computer networks Discrete blocks of data are sent in a (usually) store-and-forward manner 7

Packets Nodes in packet switched networks send discrete blocks of data to each other These blocks correspond to some piece of application data such as a file, a piece of email or an image The blocks are called packets or messages (more on this later) 8

Store-and-forward In packet switched networks, each node first receives complete packet over some link stores the packet in its internal memory and then forwards the complete packet to the next node Primary function of packet switches is to store and forward packets 9

Comparison of types of switching 10

Interconnection of networks An internetwork or an internet A node that connects two or more networks is called a router or gateway The Internet is an example of an internet 11

Addressing and routing Each node in a network must have an identifier called its address (a byte string) When a source node wants the network to deliver a message to a certain destination, it must specify the address of the destination node If the sending and receiving nodes are not directly connected, switches and routers use the address to decide how to forward the message toward the destination The process of determining systematically how to forward messages toward the destination node based on its address is called routing 12

Broadcasting and multicasting Unicast: Source sends a message to a single destination node Broadcast: Source sends a message to all the nodes on the network Multicast: Source sends a message to some subset of the other nodes (but not all of them) Thus, in addition to node-specific addresses, a network may have to support broadcast and multicast addresses as well 13

Cost-effective resource sharing How do hosts share the network and the same link when they all want to use it at the same time? Multiplexing: Sharing a system resource among multiple users L1 R1 L2 Switch 1 Switch 2 R2 L3 R3 Multiplexing/demultiplexing 14

TDM, FDM, CDMA Synchronous time-division multiplexing (STDM) or just time-division multiplexing (TDM) Time is divided into equal-sized quanta and each user is given a chance to send data in a round-robin manner Frequency-division multiplexing (FDM) Each source transmits at a different frequency Code-division multiple access (CDMA) Each source has its own code Suitable for bursty data (see more later) Q: Find out what kind of multiplexing is used in cellular networks and radio/tv broadcasting. 15

TDM vs. FDM FDM Example: 4 users frequency TDM time frequency time 16

Limitations of TDM and FDM If one of the pairs does not have any data to send, its share of physical link (time quantum or frequency) remains idle even if one of the other pairs has data to transmit In computer communications the idle time can be large! (Q: Why?) Also, the maximum number of flows in these schemes is fixed ahead of time. 17

Statistical Multiplexing Not all of the pairs are active at the same time! Like STDM: Link is shared over time Unlike STDM: Data is transmitted from each user on demand rather than in a predetermined slot Statistical multiplexing is efficient! Q: How does one ensure that transmission decisions are made fairly? 18

Asynchronous TDM(or statistical Multiplexing) versus synchronous TDM 19

More on statistical multiplexing A packet switched network fragments a large message into packets (that have a maximum size) so that other flows can have a turn to transmit their own Receiver will have to reassemble the packets back into original message Multiplexing packets onto a shared link 20

More on statistical multiplexing The switch may have to buffer packets in its memory if it receives packets faster than the shared link can handle If switch receives packets faster than it can send them for an extended period of time, resource will be congested Packets will be dropped Packets will be delayed excessively 21

Statistical multiplexing vs. circuit switching Suppose users share a 1 Mbps link and each user alternates between periods of activity (generates data at constant rate 100 kbps) and periods of inactivity Further, each user is active 10% of time With circuit switching (TDM, FDM), 100 kbps must be reserved for each user at all times E.g., TDM: 1-sec. frame is divided into 10 time slots of 100 ms each The link can support only 10 simultaneous users 22

Statistical multiplexing vs. circuit switching With statistical multiplexing, the probability that each user is active is 0.1 (10%) If there are 35 users, the probability that there are 11 or more simultaneously active users is approx. 0.0004 (see next slide) When there are 10 or fewer simultaneously active users (which happens with probability 0.9996), the aggregate arrival rate of data is less than or equal to 1 Mbps (the output rate of the link) When there are more than 10 active users, queue will begin to grow (until aggregate rate falls below 1 Mbps) The probability of having more than 10 simultaneously active users is miniscule, the performance is the same as circuit switching, and 3 times the number of users are allowed 23

Statistical multiplexing vs. circuit Let p=0.1 switching Probability of having n simultaneously active users out of 35 at any given time is 35 n pn (1-p) 35-n Probability that there are 11 or more users transmitting simultaneously is 10 1 35 n n=0 pn 1 p 35 n = 0.0004 24

Support for common services Logical channels Application-to-application communication path or a pipe Processes communicating over an abstract channel Channel must meet the functionality requirements of applications 25

Characterization of networks according to their sizes PAN Personal area network Around an individual SAN Storage area network In a room LAN Local area network ~ 1 km MAN Metropolitan area network ~ 10 km WAN Wide area network Worldwide 26

Challenges to Reliability Network should hide the errors Bits are lost Bit errors (1 to a 0, and vice versa) Burst errors several consecutive errors Packets are lost (Congestion) Uncorrectable bit errors or packet drops at intermediate nodes due to lack of buffer space Links and Node failures Crashed computers, broken links, misconfiguration 27

Other challenges Packets(messages) are delayed Packets are delivered out-of-order Third parties eavesdrop A major requirement of a network is to recover from certain kinds of failures 28

Layering Layer is a part of system that implements (or supports) some type of functionality (in the form of interrelated procedures) Layering is a fundamental design and implementation concept When designing and analyzing complex systems, we usually abstract away the details of components and provide an interface for other components of the system Services provided at higher layers are implemented in terms of services provided by lower layers 29

Concept of a layered system Examples: 30

Some concepts 1. System a data processing system connected to a network (such as a computer) 2. Layer a functional part of a system (see our more full definition). 3. Peer object objects (or entities), which are located in the same layer of two systems (i.e. the objects of the same functionality). System A System B Layer N Peer objects Layer N 4. Protocol a set of operations and messages, which specify the interaction between peer objects(in a network). Layer N System A Peer objects Protocol System B Layer N Interaction between layers in the same system 31

Protocols Protocol defines the interfaces between the layers in the same system and with the layers of peer system Building blocks of a network architecture Each protocol object has two different interfaces service interface: operations on this protocol peer-to-peer interface: messages exchanged with peer Term protocol is overloaded specification of peer-to-peer interface module that implements this interface 32

Interfaces Service and Peer Interfaces 33

Relationship between layers in a system 34

Multi-layered Network Architecture 35

Encapsulation A header (and/or trailer) is attached to a message body or payload Referred to as multiplexing and demultiplexing up and down the protocol graph Headers attached to messages contain an identifier that records the higher level object to which the message belongs Trailers may contain information for error detection/correction 36

Multiplexing and demultiplexing 37

Encapsulation and decapsulation 38

Network architecture The set of rules governing the form and context of a protocol graph is called a network architecture The suite of protocols that make up a network system is represented by a protocol graph International Standards Organization (ISO) and Internet Engineering Task Force (IETF) are examples of standardization bodies for network architectures ISO developed Open System Interconnection(OSI) architecture. IETF developed TCP/IP network architecture. 39

Open Systems Interconnection (OSI) architecture The OSI 7-layer Model OSI Open Systems Interconnection 40

Description of layers Physical Layer Handles the transmission of raw bits over a communication link Data Link Layer Collects a stream of bits into a larger aggregate called a frame Network adaptor along with device driver in OS implement the protocol in this layer (Ethernet, WiFi and Point-to-Point) Frames are actually delivered to hosts Network Layer Handles routing among nodes within a packet-switched network Unit of data exchanged between nodes in this layer is called a packet or datagram The lower three layers are implemented on all network nodes (PC, router, switch) 41

Transport Layer Description of layers Implements a process-to-process channel Unit of data exchanges in this layer is called a message. For TCP it is also called segment and for UDP it is called datagram. Session Layer Provides a name space that is used to tie together the potentially different transport streams that are part of a single application (NFS, SQL, ASP, Telnet...) Presentation Layer Concerned about the format of data exchanged between (TIFF, JPEG, MIDI,MPEG, HTML...) Application Layer Standardize common type of exchanges (HTTP, SMTP, WWW, FTP...) The transport layer and the higher layers typically run only on endhosts and not on the intermediate switches and routers 42

Internet Architecture Internet Protocol Graph Alternative view of the Internet architecture. The Network layer shown here is sometimes referred to as the sub-network or link layer. Evolved out of ARPANET (DARPA/US DoD) 43

Internet Architecture Defined by Internet Engineering Task Force (IETF) Main features Does not imply strict layering. The application is free to bypass the defined transport layers and to directly use IP or other underlying networks An hour-glass shape wide at the top, narrow in the middle and wide at the bottom. IP serves as the focal point for the architecture In order for a new protocol to be officially included in the architecture, there needs to be both a protocol specification and at least one (and preferably two) representative implementations of the specification NET... Ethernet(802.3) or wireless protocols(802.11) 44

Messages, segments, datagrams and frames 45

OSI and TCP/IP reference models Appl. program Appl. program 7 Application FTP, Telnet, DNS, Appl. layer 6 Presentation 5 Session 4 Transport TCP, UDP Transport layer 3 Network IP, ARP, ICMP Internet layer 2 1 Data link Physical Data link + physical (not part of TCP/IP) TCP/IP Any type of network 46

Implementing network software Network protocols are implemented as part of the operating system (OS) OS provides application programming interface (API) to network services Socket interface Socket: Point where a local application process attaches to the network. An interface between an application and the network Socket operations: Creating a socket, attaching the socket to the network, sending/receiving messages, closing the socket 47

Socket Socket Family PF_INET denotes the Internet family PF_UNIX denotes the Unix pipe facility PF_PACKET denotes direct access to the network interface (i.e., it bypasses the TCP/IP protocol stack) Socket Type SOCK_STREAM is used to denote a byte stream SOCK_DGRAM is an alternative that denotes a message oriented service, such as that provided by UDP 48

Network performance Network performance is measured in two fundamental ways Bandwidth (or sometimes throughput): Number of bits that can be transmitted over the network in a certain period of time (e.g., 10 Mbps: i.e. it takes 0.1 µs to transmit each bit) Notation: KB = 2 10 bytes; Mbps = 10 6 bits per second Latency (or delay): Time it takes a message to travel from one end of a network to the other (e.g., 24 ms in transcontinental networks) Round-trip time (RTT): Time it takes to send a message from one end of a network to the other and back 49

Bandwidth Bits transmitted at a particular bandwidth can be regarded as having s (a) bits transmitted at 1Mbps (each bit 1 μs wide); (b) bits transmitted at 2Mbps (each bit 0.5 μs wide). We can talk about the bandwidth of a single physical link or the bandwidth of a logical process-to-process channel 50

Bandwidth vs. throughput In networking, it is customary to refer to bits-per-second (bps) as the bandwidth Depending on the context (communication theory, signal processing), bandwidth also refers to the range of signals that can be accommodated e.g., Voice-grade telephone line, 300-3300 Hz, has a bandwidth of 3000 Hz Relationship between bps and Hz will be established in Chapter 2, Shannon s Theorem Throughput is the bits-per-second (bytes-per-second, packets-per-second, etc.) that we can actually transmit in practice (refers to measured performance) 51

Delay and throughput In general, latency has 3 main components Latency = Propagation + Transmit + Queue Propagation = Distance / SpeedOfLight Transmit = Size (bits) / Bandwidth (bps) One bit transmission => propagation is important Large bytes transmission => bandwidth is important Be careful since delay/latency/rtt are context dependent We will make it explicit whenever necessary Effective end-to-end throughput Throughput = TransferSize (bits) / TransferTime (sec) 52

Bandwidth vs. Latency Relative importance of bandwidth and latency depends on application For large file transfer, bandwidth is critical For small messages (HTTP, NFS, etc.), latency is critical Variance in latency (jitter) can also affect some applications (e.g., audio/video conferencing) (see more later) 53

Delay x Bandwidth product We think the channel between a pair of processes as a hollow pipe Latency (delay) length of the pipe and bandwidth the width of the pipe Volume of the pipe: The maximum number of bits that could be in transit through the pipe at any given interval A channel with a one-way latency of 50 ms and a bandwidth of 45 Mbps is able to hold 50x10-3 seconds x 45x10 6 bits/seconds = 2.25x10 6 bits = 280 KB of data Delay Bandwidth Network as a pipe 54

Sample delay x bandwidth products Link type Bandwidth Distance RTT Delay x BW Dial-up 56 Kbps 10 km 87 µs 5 bits Wireless LAN 54 Mbps 50 m 0.33 µs 18 bits Satellite 45 Mbps 35,000 km 230 ms 10 Mb Crosscountry fiber 10 Gbps 4,000 km 40 ms 400 Mb Here, RTT = 2 * Propagation&processing delay 55

Keeping the pipe full Delay x bandwidth is important to know when constructing high-performance networks because it corresponds to how many bits the sender must transmit before the first bit arrives at the receiver Takes another one-way latency to receive a response from the receiver If the sender is expecting the receiver to somehow signal that bits are starting to arrive the sender can send up to 2 delay x bandwidth (= RTT x bandwidth) worth of data before hearing from the receiver 56

Delay X Bandwidth Infinite bandwidth RTT dominates Throughput = TransferSize / TransferTime TransferTime = RTT + 1/Bandwidth x TransferSize Its all relative 1-MB file to 1-Gbps link looks like a 1-KB packet to 1-Mbps link 57

Relationship between bandwidth and latency Both links have an RTT of 100 ms A 1-MB file would fill the 1-Mbps link 80 times, but only fill the 1-Gbps link 1/12 of one time 58

Time scales and performance Average vs. instantaneous bandwidth: Time interval over which average is computed is important Suppose a video application needs 2 Mbps on average: If it transmits 1 Mb in first second and 3 Mb in the following second, over the 2-second interval average rate is 2 Mbps However, just knowing the average may not be enough. What if the network can support no more than 2 Mb in any one second Generally, one puts an upper bound on how large a burst can be (Burst: Peak rate maintained for some period of time) 59

Delay and jitter Delay requirement: As little delay as possible Jitter requirement: As little variation in delay as possible Smoothing out jitter is important for better performance in video applications Jitter can be smoothed out by delaying the time at which playback starts Interpacket gap Packet source 4 3 2 1 4 3 2 1 Network Packet sink Network induces jitter! 60