1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network...

72
1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance
  • date post

    19-Dec-2015
  • Category

    Documents

  • view

    212
  • download

    0

Transcript of 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network...

Page 1: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

1

Introduction

1.1 Applications1.2 Requirements1.3 Network Architecture1.4 Implementing Network Software1.5 Performance

Page 2: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

2

1.1 Applications

Most people know the Internet through its applications World Wide Web, email, chat rooms, etc The Web presents an intuitively simple interface.

Users view pages full of textual and graphical objects, click on objects that they want to learn about, and a corresponding new page appears.

Each selectable object is bound to an identifier for the next page to be viewed.

Page 3: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

3

URL

The identifier is called Uniform Resource Locator (URL)

http://www.cs.princeton.edu/~llp/index.html http indicates that the HyperText Transfer Protocol

should be used to download the page www.cs.princeton.edu is the name of the machine

serving the page /~llp/index.html uniquely identifies the page at this

site

Page 4: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

4

By clicking on just one such URL, as many as 17 messages may be exchanged over the Internet 6 messages to translate the server name into its

Internet address 3 messages to set up a TCP connection between

your browser and this server 4 messages for your browser to send the HTTP

“get” request and the server to respond with the requested page

4 message to tear down the TCP connection

Page 5: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

5

Another widespread application of the Internet is the delivery of “streaming” audio and video While an entire video file could first be fetched

from a remote machine and then played on the local machine

Stream video implies that the sender and the receiver are respectively the source and the sink for the video stream

Page 6: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

6

Difference classes of video applications

Video-on-demand Reads a preexisting movie from disk and transmits

it over the network

Videoconferencing More challenging case

It has very tight timing constraints (just as using a telephone). Too much delay makes the system unusable.

Video is flowing in both directions (interactive video)

Page 7: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

7

VideoConferencing

Page 8: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

8

VideoConferencing

Page 9: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

9

1.2 Requirements

Building blocks Switched networks Addressing and routing Multiplexing Inter-process communication

Page 10: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

10

The expectations of a network from different perspective: An application programmer: a guarantee that each

message the application sends will be delivered without error within a certain amount of time

A network designer: cost-effective design A network provider: a system that is easy to

administer and manage

Page 11: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

11

Building Blocks

A network must provide connectivity among a set of computers

Nodes: PC, special-purpose hardware… hosts switches

Links: coax cable, optical fiber… point-to-point

multiple access

(a)

(b)

Page 12: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Indirect connectivity Terms

node a computer or a more specialized piece of hardware

network switch a small hardware device that joins multiple

computers together within one local area network (LAN)

technically, network switches operate at layer two (data link layer) of the OSI model

12

Page 13: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

link physical medium

point-to-point two nodes share a single physical link

multiple-access more than two nodes share a single physical link

13

Page 14: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

14

Switched Networks

two or more nodes connected by a link, or

two or more networks connected by two or more nodes

A network can be defined recursively as...

Switched network Interconnection of networks

Page 15: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

15

Strategies

Circuit switching original telephone network carry bit streams

Page 16: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Packet switching store-and-forward messages

each node first receives a complete packet over some link

stores the packet in its internal memory forwards the complete packet to the next node

multiplex multiple flows of data over a single physical link

example: Internet

16

Page 17: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

17

Addressing and Routing Address

a set of hosts directly or indirectly connected to each other does not mean that host-to-host connectivity is provided successful.

byte-string that identifies a node usually unique (IP address, MAC address)

Page 18: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

18

Addressing and Routing Switches, Router and Gateways

Used if the sending and receiving nodes are not directly connected

Routing process of how to forward messages to the destination node

based on its address

Page 19: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Types of address unicast: node-specific broadcast: all nodes on the network multicast: some subset of nodes on the network

19

Page 20: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

IP address (Internet Protocol address) a unique address that certain electronic devices use in

order to identify and communicate with each other on a computer network utilizing the Internet Protocol standard (IP)—in simpler terms, a computer address

any participating network device—including routers, computers, servers, printers, Internet fax machines, and some telephones—can have their own unique address

example: 140.119.164.54

20

Page 21: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

MAC address (Media Access Control address) a MAC address or EHA (Ethernet Hardware Address) or

hardware address or adapter address is a quasi-unique identifier attached to most network adapters (NICs)

a number that acts like a name for a particular network adapter, so, e.g., the network cards (or built-in network adapters) in two different computers will have different names, or MAC addresses

8:0:2b:e4:b1:2 8:0:20:xx:xx:xx (AMD)

21

Page 22: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

22

Multiplexing

How do several hosts share the same link when they all want to use it at the same time

Multiplexing: a system resource is shared among multiple users: ex, CPU

Page 23: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

23

three flows of data (L1 to R1 and so on) multiplexed onto a single physical link by switch 1 demultiplexed back into separate flows by switch 2

L2

L3

R2

R3

L1 R1

Switch 1 Switch 2

Multiplexing multiple logical flows over a single physical link

Page 24: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

24

Synchronous Time-Division Multiplexing (STDM) divide time into equal-sized quanta, and in a round-

robin fashion, give each flow a chance to send its data over the physical link

Page 25: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Frequency-Division Multiplexing (FDM) transmit each flow over the physical link at a

different frequency e.g. signals for different TV stations are transmitted

at a different frequency on a physical cable TV link

25

Page 26: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

26

Drawbacks

if one of the flows (host pairs) does not have any data to send, its share of the physical link (ie, time quantum or frequency) remains idle

both STDM and FDM are limited to situations in which the maximum number of flows is fixed and known ahead of time.

Page 27: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Statistical Multiplexing

Time-division & interleaved the physical link is shared over time (time-division) -

first data from one flow is transmitted over the physical link, then data from another flow is transmitted, and so on (interleaved)

27

Page 28: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

On-demand data is transmitted from each flow on demand rather

than during a predetermined time slot if only one flow has data to send, it gets to transmit that

data without waiting for its quantum to come around and thus without having to watch the quanta assigned to the other flows go by unused

this avoidance of idle time gives packet switching its efficiency

28

Page 29: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Schedule link on a per-packet basis once a flow begins sending data, we need some way to

limit the transmission, so that the other flows can have a turn

an upper bound on the size of the block of data (packet) is defined that each flow is permitted to transmit at a given time

the source may need to fragment the message into several packets, with the receiver reassembling the packets back into the original message

29

Page 30: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

each flow sends a sequence of packets over the physical link, with a decision made on a packet-by-packet basis as to which flow’s packet to send next

if only one flow has data to send, then it can send a sequence of packets back-to-back

should more than one of the flows have data to send, then their packets are interleaved on the link

30

Page 31: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Scheduling methods FIFO (First-In-First-Out)

a fair scheduling method RR (Round-Robin)

transmit the packets from each of the different flows that are currently sending data

ensure that certain flows receive a particular share of the link bandwidth or that they never have their packets delayed in the switch for more than a certain length of time

31

Page 32: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

QoS (Quality of Service) a network that attempts to allocate bandwidth to

particular flows according service priorities a topic in Ch. 6

32

Page 33: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Congested in the following figure, the switch has to multiplex three

incoming packet streams onto one outgoing link it is possible that the switch will receive packets faster

than the shared link can accommodate in this case, the switch is forced to buffer these packets

in its memory should a switch receive packets faster than it can send

them for an extended period of time, then the switch will eventually run out of buffer space, and some packets will have to be dropped

33

■ ■ ■

Page 34: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

34

when a switch is operating in this state, it is said to be congested

■ ■ ■

A switch multiplexing packets from multiple sources onto one shared link

Page 35: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

35

Inter-Process Communication Turn host-to-host connectivity into process-to-

process communication Fill gap between what applications expect and what

the underlying technology provides Host

HostHost

Channel

Application

Host

Application

Host

Processes communicating over an abstract channel

Page 36: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Figure cloud: abstractly represent connectivity among a set of

computers channel: connect one process to another view the network as providing logical channels over

which application-level processes can communicate with each other, each channel provides the set of services required by that application

36

Host

HostHost

Channel

Application

Host

Application

Host

Page 37: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

37

Challenge

what functionality the channels should provide to application programs does the application require a guarantee that messages

sent over the channel are delivered is it necessary that messages arrive at the recipient

process in the same order does the network need to ensure that no third parties are

able to eavesdrop on the channel

a network provides a variety of different types of channels, with each application selecting the type that best meets its needs

Page 38: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

38

Types of Communication Channels

Request/reply channel applications

file transfer digital library

delivery guarantee every message sent by one side is received

by the other side and that only one copy of each message is delivered

Page 39: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

privacy and integrity might protect the privacy and integrity of the data

that flows over it unauthorized parties cannot read or modify the data

being exchanged between the client and server processes

39

Page 40: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Message stream channel applications

video-on-demand videoconferencing

delivery might not need to guarantee that all messages are

delivered, since a video application can operate adequately even if some video frames are not received

40

Page 41: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

sequence need to ensure the messages are delivered arrive in

the same order in which they were sent, to avoid displaying frames out of sequence

privacy and integrity might want to ensure the privacy aid integrity of the

video data might need to support multicast, so that multiple

parties can participate in the teleconference or view the video

41

Page 42: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

42

Reliability Reliable message delivery is one of the most

important functions that a network can provide The computer networks do not exist in a perfect

world Machines cash, fibers cut, packets lost, …etc

a major requirement of a network is to recover from certain kinds of failures so that application programs don’t have to deal with them, or even be aware of them

there are three general classes of failure that network designers have to worry about

Page 43: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

43

Bit-level errors as a packet is transmitted over a physical link, a “1” is

turned into a “0” or vice versa bit errors

single bit is corrupted burst errors

consecutive bits are corrupted causes (outside forces of electrical interference)

lightning strikes, power surges, and microwave ovens, etc. interfere with the transmission of data

Page 44: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

bit error rate one out of every 106 to 107 bits on a typical copper-

based cable one out of every 1012 to 1014 bits on a typical optical

fiber there are techniques that detect these bit errors with high

probability sometimes it is possible to correct for such errors sometimes it is necessary to discard the entire packet (when

damage is too bad)

44

Page 45: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Packet-level errors the failure is at the packet level, rather than the bit level a complete packet is lost by the network the packet contains an uncorrectable bit error and

therefore has to be discarded

45

Page 46: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

causes one of the nodes that has to handle the packet, e.g., a

switch that is forwarding it from one link to another, is so overloaded that it has no place to store the packet, and therefore is forced to drop it (congestion)

the software running on one of the nodes that handles the packet makes a mistake (ie., incorrectly forward a packet)

main difficulty distinguish between a packet lost and late arriving

46

Page 47: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Node and Link level failures a physical link is cut or the computer it is connected to

crashes causes

software crashes, power failure, misconfiguration of a network device

sometimes route around a failed node or link is possible difficulty

distinguish between a failed computer and one that is merely slow

47

Page 48: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Others messages are delayed messages are deliver out-of-order third parties eavesdrop

48

Page 49: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

49

1.3 Network Architecture

a computer network must provide general, cost effective, and robust connectivity among a large number of computers

network designers have developed general blueprints—network architectures—that guide the design and implementation of networks

Page 50: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Layering

When a system gets complex, the system designer introduces another level of abstraction

Abstraction defines a unifying model that can capture some important aspect of the system encapsulate this model in an object that provides an

interface that can be manipulated by other components of the system

hide the details of how the object is implemented from the users of the object

50

Page 51: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

we will use abstractions to hide complexity of the network from application writers

Abstractions naturally lead to layering start with the services offered by the underlying

hardware add a sequence of layers, each providing a higher

(more abstract) level of service the services provided at the high layers are

implemented in terms of the services provided by the low layers

51

Page 52: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

imagine a simple network as having two layers of abstraction Host-to-host connectivity

abstracting away the fact that there may be an arbitrarily complex network topology between any two hosts

process-to-process channels builds on the available host-to-host communication service abstracting away the fact that the network

occasionally loses messages

52

Application programs

Process-to-process channels

Host-to-host connectivity

Hardware

Example of a layer network system

Page 53: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

53

layering provides two nice features it decompose the problem of building a network

into more manageable components can implement several layers and each of which solves

one part of the problem it provides more modular design

when we want to add some new service need only to modify the functionality at one layer reusing the functions provided at all the other layers

Page 54: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Many times there are multiple abstractions provided at any given level of the system

Each provides a different service to the higher layers but builds on the same low-lever abstractions One provides a request/reply service and one supports a

message stream service at the same process-to-process channel

54

Hardware

Host-to-host connectivity

Request/replychannel

Message streamchannel

Application programs

Layered system with alternative abstractions available at a given layer

Page 55: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Protocols

Protocol the abstract objects that make up the layers of a

network system used to provide a communication service that

higher-level objects (e.g. application processes, higher-level protocols) use to exchange messages e.g. request/reply protocol, message stream

protocol building blocks of a network architecture

55

Page 56: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

56

Each protocol object defines two different interfaces service interface

defines a service interface to the other objects on the same computer that want to use its communication services

defines the operations that local objects can perform on this protocol

Host 1 Host 2

Serviceinterface

Peer-to-peerinterface

High-levelobject

High-levelobject

Protocol Protocol

Page 57: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

examples a request/reply protocol would support

operations by which an application can send and receive messages

an implementation of the HTTP protocol could support an operation to fetch a page of hypertext from a remote server

an application such as a web browser would invoke such an operation whenever the browser needs to obtain a new page

57

Host 1 Host 2

Serviceinterface

Peer-to-peerinterface

High-levelobject

High-levelobject

Protocol Protocol

Page 58: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

peer-to-peer interface defines a peer interface to its counterpart (peer)

on another machine defines the form and meaning of messages

exchanged between protocol peers

58

Host 1 Host 2

Serviceinterface

Peer-to-peerinterface

High-levelobject

High-levelobject

Protocol Protocol

Page 59: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

examples, in the case of HTTP, the protocol specification defines in detail how a "GET" command is formatted what arguments can be used with the

command how a web server should respond when it

receives such a command

59

Page 60: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

summary: a protocol defines a communication service that it exports locally

(the service interface) a set of rules governing the messages that the

protocol exchanges with its peer(s) to implement this service (the peer interface)

60

Host 1 Host 2

Serviceinterface

Peer-to-peerinterface

High-levelobject

High-levelobject

Protocol Protocol

Page 61: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

61

Host 1 Host 2

Serviceinterface

Peer-to-peerinterface

High-levelobject

High-levelobject

Protocol Protocol

Service and peer interfaces

Page 62: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Protocol Machinery Peer-to-peer is direct only at hardware level Most peer-to-peer communication is indirect

each protocol communicates with its peer by passing messages to some lower-level protocol, which in turn delivers the message to its peer

Protocol graph there are potentially multiple protocols at any given

level, each providing a different communication service

protocol graph represents the suite of protocols that make up a network system

62

Page 63: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

63

Example of a protocol graph

Host 1 Host 2

Fileapplication

Digitallibrary

application

Videoapplication

Fileapplication

Digitallibrary

application

Videoapplication

nodes : protocols

edges : “ depends on” relations

Application programs

Process-to-process channels

Host-to-host connectivity

Hardware

Page 64: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

process-to-process channels RRP: Request Reply Protocol MSP: Message Stream Protocol

host-to-host protocol (provides a host to host connectivity service) HHP: Host-to-Host Protocol

64

Application programs

Process-to-process channels

Host-to-host connectivity

Hardware

Page 65: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

hardware level peers directly communicate with each other over

a link the applications are said to employ the services of

the protocol stack RRP/HHP or MSP/HHP

65

Application programs

Process-to-process channels

Host-to-host connectivity

Hardware

Page 66: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Encapsulation (header/body)

66

Host Host

Applicationprogram

Applicationprogram

RRP

Data Data

HHP

RRP

HHP

Applicationprogram

Applicationprogram

RRP Data RRP Data

HHP RRP Data

High-level messages are encapsulated inside of low-level messages

Page 67: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Operation flow host1

application sends a message to its peer by passing the message to protocol RRP (uninterpreted)

RRP communicates control info to its peer, instructing it

how to handle the message when it is received attaches a “header” to the message

67

Page 68: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

header a small data structure - from a few bytes to a few

dozen bytes usually attached to the front of a message

body (or payload) the rest of the message

data application data is “encapsulated” in the new

message created by protocol RRP

68

Page 69: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

encapsulation high-level messages are encapsulated inside of low-

level messages the process of encapsulation is repeated at each level

of the protocol graph inspection & process

nodes in the network (e.g., switches and routers) may inspect the HHP header at the front of the message

69

Page 70: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

70

It is sometimes the case that the low-level protocol applies some simple transformation to the data it is given, such as to compress or encrypt it

Page 71: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Multiplexing and Demultiplexing

A fundamental idea of packet switching is to multiplex multiple flows of data over a single physical link

The same idea applies up and down the protocol graph The header that RRP attaches to its messages contains

an identifier that records the application to which the message belongs

We call this identifier RRP’s demultiplexing key, or demux key

71

L2

L3

R2

R3

L1 R1

Switch 1 Switch 2

Page 72: 1 Introduction 1.1 Applications 1.2 Requirements 1.3 Network Architecture 1.4 Implementing Network Software 1.5 Performance.

Source host at the source host, RRP includes the appropriate demux key

in its header

Destination host when the message is delivered to RRP on the destination

host, it strips its header examines the demux key demultiplexes the message to the correct application

72