protocols for multiaccess networks

25
Protocols for Multiaccess Networks Hosts broadcast packets When a collision occurs, all transmitted packets are lost Lost packets have to be retransmitted Protocols Slotted Aloha CSMA and CSMA/CD CSC358 - Introduction to Computer Networks

Upload: others

Post on 31-Jan-2022

8 views

Category:

Documents


0 download

TRANSCRIPT

Protocols for Multiaccess Networks

Hosts broadcast packetsWhen a collision occurs, all transmitted packets are lostLost packets have to be retransmitted

ProtocolsSlotted AlohaCSMA and CSMA/CD

CSC358 - Introduction to Computer Networks

Multiaccess Protocols

Using multiaccess protocols in everyday life:Slotted AlohaCSMACSMA/CD

Lesson?

CSC358 - Introduction to Computer Networks

Layered Architecture

CSC358 - Introduction to Computer Networks

Network Layer

Service:Delivers data packets (segments) from the transport layerof the origin host to the transport layer of the destinationhost.

FunctionalityPath Determination (Routing)SwitchingAddressing

CSC358 - Introduction to Computer Networks

Layered Architecture

CSC358 - Introduction to Computer Networks

Network Layer

Path Determination (Routing)Switching

CSC358 - Introduction to Computer Networks

Network Layer

ComplexityCoordination between peer processes of all nodesError handling (link/node failure)Adaptation to changes in the traffic load

CSC358 - Introduction to Computer Networks

Outline

IntroductionRouting

Shortest Path RoutingBellman-Ford algorithmDijkstra’s algorithm

Internet Nework Layer

CSC358 - Introduction to Computer Networks

Routing Algorithms

CSC358 - Introduction to Computer Networks

Routing Algorithms

Performance MeasureRelation Throughput - Average Delay

CSC358 - Introduction to Computer Networks

Routing Algorithms

Routing Decision:Datagram service: for each packetVirtual Circuit service: for each session

What is the advantage of virtual circuit service?

CSC358 - Introduction to Computer Networks

Virtual Circuit Service

Connection OrientedVirtual Circuit setupData TransferVirtual Circuit teardown

CSC358 - Introduction to Computer Networks

Virtual Circuit Service

Call Admission ControlRate Allocation (and Policing)QoS guarantees

CSC358 - Introduction to Computer Networks

Datagram Service

Connectionlessno Call Admission Controlno QoS guarantees (“best effort service”)

− > dynamic transmission rate adaptation (TCP)

CSC358 - Introduction to Computer Networks

Routing Algorithms: Classification

Centralized - DistributedCentralized: routing decision are made at a central nodeDistributed: computation of routes is shared among thenetwork nodes

Static - DynamicStatic: routes are fixed regardless of traffic conditionsDynamic: routes are changed in response to changes intraffic conditions (congestion)

CSC358 - Introduction to Computer Networks

Routing Algorithms: Flooding

MechanismEach node forwards packets to all its neighbors

Rulesdo not send packet to node from where it was obtainedsend the same packet to a neighbor at most once

Why use Flooding?broadcast (topology) informationwhen network topology changes frequently

CSC358 - Introduction to Computer Networks

Routing Algorithms: Shortest Path Routing

Cost

CSC358 - Introduction to Computer Networks

Routing Algorithms: Shortest Path Routing

Link costs will change with time and so may shortest path.Therefore, we need a way to efficiently compute the shortestpaths.Two main approaches

Bellman-Ford algorithm (Distance Vector Routing)Dijkstra’s algorithm (Link State Routing)

CSC358 - Introduction to Computer Networks

Bellman-Ford Algorithm

Find shortest path from all nodes to a destination node.

Di = minj{dij + Dj}

Di : shortest distance from node i to the destination node 1dij : cost of link from node i to node j

CSC358 - Introduction to Computer Networks

Bellman-Ford algorithm

Node 1 is the destination nodedij =∞, when no link from i to jDk

1 = 0, k = 0,1,2, ...

InitializationD0

i =∞, for all i 6= 1Update

Dk+1i = minj{dij + Dk

j }, k = 0,1,2, ...

CSC358 - Introduction to Computer Networks

Distance Vector Routing

Distributed algorithm. Each nodes has local information.Each node maintains a table (distance vector) of its (bestknown) shortest distance to each destination node, as wellas which link to get there.Each node knows the link costs to all its neighborsNodes exchange their distance vector with its neighborsNodes update their distance vector based on theseexchanges

Bellman-Ford algorithm is used to update distance vector.

CSC358 - Introduction to Computer Networks

Dijkstra’s algorithm

Find shortest form a source node to all other nodes.

IdeaFind the closest nodeFind the second closest nodeetc.

CSC358 - Introduction to Computer Networks

Dijkstra’s algorithm

Node 1 is the source nodedij =∞, when no link from i to jDi : estimate of distance from the source node 1 to node iP: set of “permanently labeled” nodes

InitializationP = {1}D1 = 0Di = di1, for all i 6= 1

UpdateStep 1: (Find closest node) Find i /∈ P such that

Di = minj /∈P

Dj

Set P = P ∪ {i}. If P contains all nodes, then stop.Step 2: (Update distance estimates) For all j /∈ P set

Dj = min{Dj ,Di + dij}Go to Step 1.

CSC358 - Introduction to Computer Networks

Link State Routing

Distributed algorithm. Each nodes needs globalinformation.Each node discovers its neighbors and the correspondinglink costs.Each node broadcasts this information to all other nodes.Using this global information, each node computes theshortest path to all other nodes.

Dijkstra’s algorithm is used to compute the shortest path.

CSC358 - Introduction to Computer Networks

Routing Algorithms

Distance Vector RoutingDistributed algorithmEach node uses local informationSuffers from count-to-infinity problemCan oscillate

Link State RoutingDistributed algorithmEach node needs global informationCan oscillate

CSC358 - Introduction to Computer Networks