Routing Protocols - PowerPoint PPT Presentation

1 / 22
About This Presentation
Title:

Routing Protocols

Description:

Each node maintains a set of triples: (Destination, Cost, NextHop) Each node sends updates to (and receives updates from) ... Edsger Wybe Dijkstra: 1930-2002 ... – PowerPoint PPT presentation

Number of Views:27
Avg rating:3.0/5.0
Slides: 23
Provided by: markc195
Category:

less

Transcript and Presenter's Notes

Title: Routing Protocols


1
Routing Protocols
2
Routing
  • Forwarding versus Routing
  • forwarding to select an output port based on
    destination address and routing table
  • routing process by which routing table is built
  • Network as a Graph

3
Routing
  • Problem Find the lowest cost path between any
    two nodes
  • Factors
  • Static topology, SOL delays
  • Dynamic load, congestion
  • Scalable

4
Distance Vector (RIP)
  • Each node maintains a set of triples
  • (Destination, Cost, NextHop)
  • Each node sends updates to (and receives updates
    from) its directly connected neighbors
  • periodically (on the order of several seconds)
  • whenever its table changes (called triggered
    update)
  • Used by Routing Information Protocol (RIP)

5
Routing
  • Each update is a list of pairs
  • (Destination, Cost)
  • Update local table if receive a better route
  • smaller cost
  • came from next-hop
  • Refresh existing routes delete if they time out

6
Example
Routing table at node B
Destination A C D E F G
Cost 1 1 inf inf inf inf
Next Hop A C
7
Example
  • Routing table at node B

B
C
A
D
E
F
G
Destination A C D E F G
Cost 1 1 2 2 2 3
Next Hop A C C A A A
8
Routing Loops
  • Example 1
  • F detects that link to G has failed
  • F sets distance to G to infinity and sends update
    to A
  • A sets distance to G to infinity since it uses F
    to reach G
  • A receives periodic update from C with 2-hop path
    to G
  • A sets distance to G to 3 and sends update to F
  • F decides it can reach G in 4 hops via A

9
Example 2
  • Link from A to E fails
  • A advertises distance of infinity to E
  • B and C advertise a distance of 2 to E
  • B and C both set the distance to E to infinity
  • B decides it can reach E in 3 hops through C
    advertises this to A
  • A decides it can reach E in 4 hops through B
    advertises this to C
  • C decides that it can reach E in 5 hops......

10
Heuristics to break routing loops
  • set infinity to 16
  • split horizon
  • Dont send routes learned from particular
    neighbor to that neighbor (B doesnt send route
    E,2,A to A)
  • split horizon with poison reverse
  • Include negative information (B sends route E,?
    to A)
  • Only work with routing loop with simple loop,
    more complex techniques later

11
Example 2 with poison
  • Link from A to E fails
  • A advertises distance of infinity to E
  • B and C advertise a distance of 2 to E to each
    other
  • B decides it can reach E in 3 hops through C
    advertises this to A, sends ? to C,
  • since C was using B to get to E, C advertises a
    distance of ? to E
  • Since B was using C to get to E, B advertises a
    distance of ? to E

12
RIP Network
C advertises to router A and D, cost 0 to 2,3,
cost 1 to 5,6,1 and cost 2 to 4
13
Summary Distance Vector
  • Send entire routing table (Large amount of data
    (O(N)) )
  • Send it only to directly connected neighbors (to
    a few endpoints (O(1))
  • Routers do not have global information about
    connections in the network

14
Link State (OSPF)
  • Strategy Send to all nodes (not just neighbors)
    information about directly connected links (not
    entire routing table).
  • Link State Packet (LSP)
  • id of the node that created the LSP
  • cost of link to each directly connected neighbor
  • sequence number (SEQNO)
  • time-to-live (TTL) for this packet
  • Example Open Shortest Path First Protocol (OSPF)

15
Reliable Flooding
  • store most recent LSP from each node
  • forward LSP to all nodes but one that sent it
  • generate new LSP periodically increment SEQNO
  • start SEQNO at 0 when reboot
  • decrement TTL of each stored LSP discard when
    TTL0

16
Reliable Flooding
17
What do you do with LSPs
  • Want to calculate shortest path from D to every
    other node
  • Naïve approach explores every possibility
  • O(NN)
  • NP Complete multicriteria

18
Route Calculation (Dijkstras) O(N2)
19
Edsger Wybe Dijkstra 1930-2002
  • Dijkstra is renowned for the insight that
    mathematical logic is and must be the basis for
    sensible computer program construction and for
    his contributions to mathematical methodology.
  • thirteen hundred written works
  • leader in the abolition of the GOTO statement
    from programming
  • "The question of whether computers can think is
    like the question of whether submarines can swim

20
Route Calculation (in practice)
  • Forward search algorithm
  • Each switch maintains two lists
  • Tentative and Confirmed
  • Each list contains a set of triples
  • (Destination, Cost, NextHop)

21
(destination, cost, nexthop)
Step 1. 2. 3. 4.
Confirmed (D,0,-) (D,0,-) (D,0,-) (C,2,C) (D,0
,-) (C,2,C)
Tentative (B,11,B) (C,2,C) (B,11,B) (B,5,C) (
A,12,C)
Step 5. 6. 7.
Confirmed (D,0,-) (C,2,C) (B,5,C) (D,0,-) (C,2,C)
(B,5,C) (D,0,-) (C,2,C) (B,5,C) (A,10,C)
Tentative (A,12,C) (A,10,C)
22
Link State vs distance-vector
  • Distance vector (original ARPANET)
  • Node talks to direct neighbors
  • Sends everything it has learned
  • Link State (Later ARPANET)
  • Node talks to everyone
  • Only sends what it knows for sure
Write a Comment
User Comments (0)
About PowerShow.com