Intradomain Routing EECS 122: Lecture 10 - PowerPoint PPT Presentation

1 / 39
About This Presentation
Title:

Intradomain Routing EECS 122: Lecture 10

Description:

Intradomain Routing EECS 122: Lecture 10 Department of Electrical Engineering and Computer Sciences University of California Berkeley – PowerPoint PPT presentation

Number of Views:160
Avg rating:3.0/5.0
Slides: 40
Provided by: Abha72
Category:

less

Transcript and Presenter's Notes

Title: Intradomain Routing EECS 122: Lecture 10


1
Intradomain RoutingEECS 122 Lecture 10
  • Department of Electrical Engineering and Computer
    Sciences
  • University of California
  • Berkeley

2
What is Routing?
  • Routing is the core function of a network
  • It ensures that
  • information accepted for transfer
  • at a source node
  • is delivered to the correct
  • set of destination nodes,
  • at reasonable levels of performance.

3
Datagram v/s Virtual Circuit
  • Datagram routing
  • Each packet to be forwarded independently
  • Virtual Circuit
  • Each packet from same o-d uses same route
  • More state (pick the right granularity)
  • QoS sensitive networks use VCs and signaling
  • Find a route that has the resources available for
    the connection.
  • Reserve the resources before sending data
    packets

4
Many Kinds of Routing
  • Driven by
  • Destination set
  • IP point-to-point
  • Multicast
  • Physical Characteristics
  • Optical
  • mobile wireless
  • Diffusion (sensor networks)
  • Interconnection network routing
  • Geographic (wireless)
  • Network Function
  • P2P
  • Content Distribution Networks

5
A Graph Model
  • Nodes are Routers/Hosts
  • Edges are undirected

6
Walks
A Walk from 1 to 11
Cycle 4-8-7-5-4
7
5
4
8
6
11
2
10
3
1
13
12
7
Paths
Routes are Paths
A Path is a Walk with no cycles
7
5
4
There are 24 paths from 1 to 11
8
6
11
2
10
3
1
13
12
8
Routes
Routes are Paths
A Path is a Walk with no cycles
Edges have weights
There are 24 paths from 1 to 11
9
Routing
Routes are Paths
A Path is a Walk with no cycles
7
5
Edges have weights
4
There are 24 paths from 1 to 11
8
Select the shortest path route Many ways to do
this
6
11
2
10
3
1
13
12
10
Routing affects Flow Control
  • Any function that paces the flow of bits into
    or within the network is flow control
  • Example All links have capacity 1

1
1
A
B
Nothing admitted
E
E
C
F
F
D
11
What is going on?
  • Routing and flow intimately related
  • Link congestion metrics for routing depends on
    flow control
  • Flow control feedback delay depends on routing
  • Optimizing them jointly is nice in theory but
    intractable in practice.
  • Separating flow control and routing makes both
    extremely difficult to implement with high
    performance

12
The internet has many Administrative Domains
B
7
5
4
8
6
11
2
10
3
1
13
12
C
A
13
Border Routers
B
7
5
4
RIP
4
8
6
6
11
2
2
10
OSPF
BGP
3
13
3
13
1
12
C
IGRP
A
14
Hierarchical Routing
4
4
B
6
BGP
6
B
7
5
IntraDomain
2
InterDomain
2
4
RIP
8
6
3
13
3
13
11
2
10
OSPF
IntraDomain
IntraDomain
3
1
13
12
IGRP
C
A
15
Routing Sub-Functions
  • Topology Update Characterize and maintain
    connectivity
  • Discover neighbors
  • Measure distance (one or more metric)
  • Disseminate
  • Route Computation
  • Kind of path Multicast, Unicast
  • Centralized or Distributed Algorithm
  • Policy
  • Hierarchy
  • Switching Forward the packets at each node

16
Routing Sub-Functions
  • Topology Update Characterize and maintain
    connectivity
  • Discover neighbors
  • Measure distance (one or more metric)
  • Disseminate
  • Route Computation
  • Kind of path Multicast, Unicast
  • Centralized or Distributed Algorithm
  • Policy
  • Hierarchy
  • Switching Forward the packets at each node

17
Three types of Routing Protocols
  • Topology changes can be detected by nearby nodes
  • These changes must be reflected in the routes
  • Mechanisms for disseminating information
  • Link State Communicate the names and costs of
    neighbors. Each node maintains the entire
    topology. E.g. used in OSPF
  • Distance Vector Communicate current distance
    estimates of node to every other node. E.g. used
    in RIP
  • Path Vector Communicate current estimates of
    preferred paths from node to every other node.
    E.g. used in BGP

18
Link State Protocols
  • Every node learns the topology of the network
  • Flooding of Link State Packets (LSP)
  • An efficient shortest path algorithm computes
    routes to every other node
  • Node updates Forwarding Table

19
Flooding Link State Information
  • Every router sends Link State Packets (LSPs) to
    all of its neighbors
  • LSPs arrive and wait in buffers to be accepted
  • If node j receives a LSP from node k it compares
    the sequence numbers. If this is the most recent
    one from k, send to N(j)-k.
  • This way each router can send its LSP to all
    other routers
  • Age starts out at 7. At any router, value is
    decremented every 8 seconds. At 0 discard.
  • As long as sequence dont wrap this works
  • Otherwise things can get ugly

20
Example Network
7
5
4
8
6
11
2
10
3
1
13
12
21
Example Network
7
5
4
8
6
11
2
10
3
1
13
12
22
Example Network
7
5
4
8
6
11
2
10
3
1
13
12
23
Example Network
7
5
4
8
6
11
2
10
3
1
13
12
24
Real story
  • Sequence numbers from some router, s, wrapped
    around
  • A lt B lt C lt A
  • Router, t, has a buffer with LSPs from s of all
    three values in order A, B, C
  • Store and flood A
  • Replace A with B and flood B
  • Replace B with C and flood C
  • Router u receives the LSPs in order ABC and goes
    through the same cycle and sends to v
  • The entire Arpanet was sending these LSPs and
    crashed
  • LSPs did not wait in buffers long enough to age

25
Some Issues
  • What happens if some routers are much faster at
    transmitting LSPs?
  • What happens if sequence numbers wrap?
  • What happens when a partitioned network is
    reconstituted?
  • What about security?
  • Etc., etc.
  • Many lines of code

26
Route Computation Dijkstra
  • Every node knows the graph
  • All link weights are gt 0
  • Goal at node 1 Find the shortest paths from 1 to
    all the other nodes.
  • Each node computes the same shortest paths so
    they all agree on the routes
  • Strategy at node 1 Find the shortest paths in
    order of increasing path length

3
2
3
1
2
1
4
1
1
4
4
6
5
1
1
27
Dijkstra Shortest Path
Notation c(i,j) gt0 cost of link from (I,j)
D(1,i) Shortest path from 1 to i. D(1,x,i)
Shortest path from 1 to i via x Let P(k) be the
set of nodes k-closest to 1
  • IDEA Given P(k) we can find P(k1) efficiently
  • To get P(k1), observe that
  • This node cannot be in P(k)
  • It must be one hop away from some node in P(k)
  • Suppose 2 were false. We picked i
  • Node i has no edge into P(k)
  • There must be a node x, not in P(k) such that
  • x is one hop away from P(k) and
  • D(1,i)D(1,x)D(x,i)
  • But then, D(1,x) lt D(1,i) and we would have
    picked x instead.
  • Pick node(s) that is one hop away from P(k) that
    is closest to 1.
  • Keep iterating until all nodes are in P

P(2)1,2
3
D(1,5)2 D(1,6,5)5
2
3
1
2
1
4
1
1
4
4
6
5
1
1
28
Dijkstra Shortest Path
29
Dijkstra Forwarding Table
At node 5
Outgoing Cost
1 2 2
2 2 1
3 3 1
4 3 3
6 6 1
3
2
3
1
2
1
4
1
1
4
4
6
5
1
1
30
Distance Vector Protocols
  • Communicate current distance estimates of node to
    every other node
  • This is called its distance vector Di
    (D(i,1),D(i,2),,D(i,n))
  • Initially, assume that all distance estimates are
    c(i,j)
  • The nodes do not need to learn the entire
    topology
  • Just the distance estimates (vectors) of their
    neighbors
  • Periodically each node sends its distance vector
    to all of its neighbors

3
2
3
1
2
1
4
1
1
4
4
6
5
1
1
At node 1 D1 (0,1,8,8, 8,4) Neighbor
estimates 2 (1,0,8,8,8,8) 6 (4,8,8,8,8,0)
At node 6 D6 (4,8,8,8,1,0) Neighbor
estimates 1 (0,8,8,8,8,4) 5 (8,8,8,8,0,1)
31
Distance Vector Protocols
  • Upon receiving a more recent distance vector from
    its neighbors, a node, i, stores it and revises
    Di
  • New D(i,d)
  • The total cost to send it via neighbor j is the
    sum of
  • The link cost c(i,j)
  • The stored estimate to reach d from j
  • Pick the lowest sum over all the neighbors
  • D(i,d) minjeN(i) c(i,j) D(j,d)

3
2
3
1
2
1
4
1
1
4
4
6
5
1
1
Node 6 receives (0,1,8, 8,8,8,4) from
1 (8,1,1,4,0,1) from 5
Old Info DV (4,8,8,8,1,0) Neighbor
estimates 1 (0, 8,8,8,8,4) 5 (8,8,8,8,0,1)
Revised DV (4,2,2,5,1,0) Neighbor estimates 1
(0,1, 8,8, 8,4) 5 (8,1,1,4,0,1)
Send all packets to 2 via 1.
32
Distance Vector Protocols
  • Forwarding Table at 6

3
2
3
1
2
Estimates DV (3,2,2,4,1,0) Neighbor
estimates 1 (0,1,3,5,2,3) 5 (2,1,1,3,0,1)
1
4
1
1
4
4
6
5
1
1
Node Cost
1 5 3
2 5 2
3 5 2
4 5 4
5 5 1
33
Why does this compute shortest paths?
  • Suppose in every tick each node sends its
    distance vector.
  • Assume that initial distances are 8
  • At time h, node i has as an estimate of the
    shortest path to node j that has lt h1 hops!
  • Dh1(i,j) minkeN(i) Dh(k) c(i,k)

1
1
1
1
3
3
4
2
2
2
2
6
3
3
3
1
1
1
4
1
4
5
6
5
6
6
6
5
5
4
2
3
2
3
2
4
34
Counting to Infinity
All links cost 1
A
B
C
3
4
0
A
B
C
5
6
0
Ping-Pong to Eternity
35
Bad News Travels Slowly
1
4
3
1
1
1
2
M
1
D(2,1)2, D(3,1)1, D(4,1)2
36
Bad News Travels Slowly
1
4
3
1
Node 2 takes about M Iterations to figure out
that D(2,1)M
1
1
2
M
1
  • Fundamental Cause After a network change, think
    of the network
  • protocol running from time 0. The initial
    conditions are arbitrary
  • Tricks exist to get around these problems but not
    fool proof

37
Asynchronous Bellman Ford
  • In general, nodes are using different and
    possibly inconsistent estimates
  • If no link changes after some time t, the
    algorithm will eventually converge to the
    shortest path
  • No synchronization required at all

38
Oscillations
  • Link costs must reflect link speed AND congestion
  • Under both LSP and DV routing occurs over a tree
  • The costs of the links of this tree will increase
  • The other links will not be congested
  • Their costs will drop
  • Routing protocol will shift traffic and create a
    new tree
  • This process of shifting and reshifting can be
    severe
  • Way out Change congestion costs slowly
    (exponential averaging) Route dampening

39
Link State vs. Distance VectorNo clear winner
  • LS is robust since it each node computes its own
    routes independently
  • Suffers from the weaknesses of the topology
    update protocol. Inconsistency etc.
  • Excellent choice for a well engineered network
    within one administrative domain
  • E. g. OSPF
  • DV works well when the network is large since it
    requires no synchronization and has a trivial
    topology update algorithm
  • Suffers from convergence delays
  • Very simple to implement at each node
  • Excellent choice for large networks
  • E.g. RIP
Write a Comment
User Comments (0)
About PowerShow.com