Routing, Performance, Layers
- Routing: Link-State and Distance-Vector
- network performance
- the ISO 7-layer model
- reliable transmission
- flow and congestion control
Dijkstra's shortest path algorithm
- input: a set of nodes N = {n1, n2, ... } and distances
(costs) between nodes D = {(n1,n2=d1), (n1,n3=d2), ... }, as
well as the root node r from which distances are desired
- the root node r is the initial value of the set K = {r}
of nodes whose distance from r is known
- compute (and save) all the direct distances from r to each
of the nodes in N, using infinity if there is no direct connection
- pick the node (c) in N that has the least distance
(to r), remove it from N, and add it to K
- reduce (wherever possible) all distances for all nodes in N
with a direct link to the node c selected in the previous step
- repeat the preceding two steps until N is empty (all distances
are now known) or until all nodes in N have infinite distance
(the network is partitioned)
Link-State Routing
- With Dijkstra's algorithm, each router can build
its routing tables given
a "map" (a graph representing the network)
- how do the routers get the map?
- each router broadcasts all the information it knows about: its links
to its neighbors
- each message has a sequence number: later information overrides
earlier information
- the "map" is pieced together from the information
- broadcasting is done by each node sending to its neighbors and
suppressing duplicates: flooding
Distance-Vector Routing
- suppose X sends its routing table to neighbor Y
- the cost for Y to reach X is mY(X)
- for every destination D with cost mX(D) in X's routing
table, Y compares mX(D)+mY(X) to mY(D).
- If mX(D)+mY(X) < mY(D), then a route through X is lower-cost
than the existing route, and Y updates its routing table appropriately
- all communication is between neighbors
- great for finding low-cost routes, slow at updating tables when
links fail
Routing: In-class exercises
- flooding: one person sends, everyone receives
- link-state routing: everyone in a network floods the information
about their neighbors to everyone else in the network, each router
builds their own map and routing table. The information is resent
whenever it changes.
- distance-vector routing: everyone tells all their neighbors about
who they can reach and at what distance. I send my information
to all my neighbors whenever my routing table changes.
- Please bring pieces of paper that can be used to simulate messages
in a network