EECB 473 Data Network Architecture and Electronics Lecture 3 Packet Processing Functions.

Post on 17-Dec-2015

215 views 0 download

Tags:

Transcript of EECB 473 Data Network Architecture and Electronics Lecture 3 Packet Processing Functions.

EECB 473 Data Network Architecture and Electronics

Lecture 3Packet Processing Functions

Aims of this lectureIdentify functions that occur in packet

processingDevise set of operations sufficient for all

packet processingFind an efficient implementation for the

operations

Packet Processing Functions We Will ConsiderAddress lookup and packet forwardingError detection and correctionFragmentation, segmentation, and

reassemblyFrame and protocol demultiplexingPacket classificationQueueing and packet discardScheduling and timingSecurity: authentication and privacyTraffic measurement, policing, and shaping

Address Lookup And Packet ForwardingForwarding requires address lookupLookup is table drivenTwo types

Exact match (typically layer 2)Longest-prefix match (typically layer 3)

Cost depends on size of table and type of lookup

Error Detection And CorrectionData sent with packet used as verification

ChecksumCRC

Cost proportional to size of packetOften implemented with special-purpose

hardware

An Important Note About CostThe cost of an operation is proportional to the amount

of data processed. An operation such as checksum computation that requires examination of all the data in a packet is among the most expensive.

Fragmentation, Segmentation, And ReassemblyIP fragments and reassembles datagramsATM segments and reassembles AAL5

packetsSame idea; details differCost is high because

State must be kept and managedUnreassembled fragments occupy memory

Frame And Protocol DemultiplexingTraditional technique used in layered

protocolsType appears in each header

Assigned on outputUsed on input to select ‘‘next’’ protocol

Cost of demultiplexing proportional to number of layers

Packet ClassificationAlternative to demultiplexingCrosses multiple layersAchieves lower costMore on classification later in the course

which is inclusive ofStatic and Dynamic ClassificationDemultiplexing versus ClassificationOptimized Packet ProcessingClassification Languages

Queueing And Packet DiscardGeneral paradigm is store-and-forward

Incoming packet placed in queueOutgoing packet placed in queue

When queue is full, choose packet to discard

Affects throughput of higher-layer protocols

Queueing PrioritiesMultiple queues used to enforce priority

among packetsIncoming packet

Assigned priority as function of contentsPlaced in appropriate priority queue

Queueing disciplineExamines priority queuesChooses which packet to send

Examples Of Queueing DisciplinesPriority Queueing

Assign unique priority number to each queue

Choose packet from highest priority queue that is nonempty

Known as strict priority queueingCan lead to starvation

Examples Of Queueing Disciplines(continued)Weighted Round Robin (WRR)

Assign unique priority number to each queue

Process all queues round-robinCompute N, max number of packets to select

from a queue proportional to priorityTake up to N packets before moving to next

queueWorks well if all packets equal size

Examples Of Queueing Disciplines(continued)Weighted Fair Queueing (WFQ)

Make selection from queue proportional to priority

Use packet size rather than number of packets

Allocates priority to amount of data from a queue rather than number of packets

Scheduling And TimingImportant mechanismsUsed to coordinate parallel and concurrent

tasksProcessing on multiple packetsProcessing on multiple protocolsMultiple processors

Scheduler attempts to achieve fairness

Security: Authentication And PrivacyAuthentication mechanisms

Ensure sender’s identityConfidentiality mechanisms

Ensure that intermediaries cannot interpret packet contents

Note: in common networking terminology, privacy refers to confidentialityE.g. Virtual Private Networks

Traffic Measurement And PolicingUsed by network managersCan measure aggregate traffic or per-flow

trafficOften related to Service Level Agreement

(SLA)Cost is high if performed in real-time

Traffic ShapingMake traffic conform to statistical boundsTypical use

Smooth burstsAvoid packet trains

Only possibilitiesDiscard packets (seldom used)Delay packets

Example Traffic Shaping MechanismsLeaky bucket

Easy to implementPopularSends steady number of packets per secondRate depends on number of packets waitingDoes not guarantee steady data rate

Example Traffic Shaping Mechanisms(2)Token bucket

Sends steady number of bits per secondRate depends on number of bits waitingAchieves steady data rateMore difficult to implement

Illustration Of Traffic ShaperPackets

Arrive in burstsLeave at steady rate

Timer ManagementFundamental piece of network systemNeeded for

SchedulingTraffic shapingOther protocol processing (e.g.,

retransmission)Cost

Depends on number of timer operations (e.g., set, cancel)

Can be high

SummaryPrimary packet processing functions are

Address lookup and forwardingError detection and correctionFragmentation and reassemblyDemultiplexing and classificationQueueing and discardScheduling and timingSecurity functionsTraffic measurement, policing, and shaping