CSCI 5273 Computer Networks Stevens, Chapter 9 Routing - PowerPoint PPT Presentation

1 / 34
About This Presentation
Title:

CSCI 5273 Computer Networks Stevens, Chapter 9 Routing

Description:

On initailization, router determines all available interfaces and sends a ... For each Neighbour of D listed in D's LSP with a link cost to N of c, see if (N, ... – PowerPoint PPT presentation

Number of Views:52
Avg rating:3.0/5.0
Slides: 35
Provided by: DirkGr8
Category:

less

Transcript and Presenter's Notes

Title: CSCI 5273 Computer Networks Stevens, Chapter 9 Routing


1
CSCI 5273Computer NetworksStevens, Chapter
9Routing
  • Dirk GrunwaldAssoc. ProfessorDept. of Computer
    ScienceUniversity of Colorado, Boulder

2
Outline
  • Routing domains levels
  • RIP routing
  • Distance Vector Routing
  • Examples of RIP information management
  • OSPF routing
  • Link state routing

3
Gateway Hierarchy
InternetCore
AutonomousSystem(AS)
AutonomousSystem(AS)
4
Two levels of Routing Protocols
RoutingDomain
RoutingDomain
IGP
IGP
EGP
RoutingDomain
EGP
EGP
Intra-domainrouting protocol
Exteriorrouting protocol
IGP
5
Routing Protocols
  • Intra-domain Gateway Protocols
  • RIP
  • RIP V2
  • OSPF - open shortest path first
  • IS-IS (similar to OSPF)
  • Exterior Gateway Protocols
  • EGP
  • BGP

6
RIP
  • Distance vector routing algorithm based on hops
    that communicates between routers using UDP
  • On initailization, router determines all
    available interfaces and sends a REQUEST packet
    out each interface. Special request for send
    everything
  • On receipt of request,
  • Either return everything
  • Or, for each requested destination, return
    distance 1
  • On response
  • Update routing tables

7
RIP V1 Protocol
Command
Version
MBZ
Address Family
MBZ
32-bit IP address
MBZ
MBZ
Metric (value of 1..16)
Up to 24 more routes in same format...
8
Metrics
N2 is 1 hop
N1
R1
Route to N3via R2 withhop count of 2
N3 is 1 hop
N2
N1 is 1 hop
R2
N3
N2 is 1 hop
9
Problems
  • Hop count limited to 15
  • Can only be used within an AS where maxiumum
    network diameter of 15
  • Its based on HOPS, not e.g., latency or
    bandwidth
  • No notion of subnet addressing in RIP V1

10
RIP V2 Protocol
Command
Version
Routing domain
Address Family
Route tag
32-bit IP address
32-bit subnet mask
32-bit next-hop IP address
Metric (value of 1..16)
Up to 24 more routes in same format...
11
RIP V2
  • Routing domain is an identifier of the routing
    daemon
  • Process ID in UNIX
  • So you can run multiple instances of RIP
  • Route tag carries an autonomous system number for
    EGP and BGP
  • Next op address is where packets corresponding to
    that (sub)network should be sent. A value of zero
    means send to the system sending RIP info.
  • Simple authentication scheme with clear-text
    password

12
Distance Vector Routing
  • Also called Bellman-Ford or Ford-Fulkerson
    algorithms
  • Used by RIP
  • Each router is responsible for keeping track and
    informing its neighbors of its distance to each
    destination
  • The router computes its distance to a destination
    based on its neighbors distance to the
    destination
  • Router must know its own ID and the cost of its
    links to each neighbor

13
Distance Vector Routing For Address D
17
2
Link number
1
2
R
35
3
5
4
41
5
Link cost
14
Distance Vector Routing For Address D
97
81
17
2
Cost from neighbor to destination D
1
2
R
35
62
3
5
4
41
5
29
118
15
Distance Vector Routing For Address D
97
81
99
17
2
Cost for Rto get to Dvia this link
98
1
2
R
35
62
3
5
97
4
41
5
70
123
29
118
Minimumcost route
16
Distance Vector Routing For Address D
70
70
17
2
Cost fromR to D
1
2
R
35
70
3
5
4
41
5
70
70
17
Problems With Distance Vector
  • Slow convergence to the lowest cost route
  • Slow recovery time
  • Slow recovery leads to routing problems during
    recovery
  • Router loops
  • Count to infinity

18
Routing Loops
A
A
C
C
B
B
D
D
19
Count To Infinity (worse case loop)
A
A
A
A
B
B
B
B
C
20
OSPF - Open Shortest Path First
  • OSPF uses IP directly (I.e., like ICMP)
  • Routes calculated based on TOS
  • Each interface is assigned a dimensionless cost,
    for each TOS
  • If several equal-cost routes are available,
    traffic is load-balanced
  • Subnets are associated with each advertised route
  • Supports authentication
  • Uses multicast to distribute information

21
Link State Routing
  • Used by OSPF and IS-IS
  • Construct a Link State Packet that lists
    neighbors and costs to get to those neighbours
  • Use Dijkstras algorithm to compute global routes
    as a tree from the current router

22
Dijkstras Algorithm
  • Two sets of paths PATH and TENT(ative)
  • (destination, path cost, forwarding direction)
  • (1) Place (self, 0,0) in path
  • (2) For any (D,C,F) placed in PATH, examine Ds
    LSP. For each Neighbour of D listed in Ds LSP
    with a link cost to N of c, see if (N, c, ) is
    already in TENT or PATH. If not listed, or if c
    is less than existing cost, add (N, Cc,) to
    TENT
  • (3) Terminate if TENT is empty, otherwise find
    (D,C,F) with minimum C and add that to PATH. Goto
    (2)

23
Example of Dijkstras Algorithm
C(0)
F(2)
B(2)
G(5)
24
Example of Dijkstras Algorithm
C(0)
Place F in path
F(2)
B(2)
G(5)
E(6)
G(3)
25
Example of Dijkstras Algorithm
C(0)
F(2)
B(2)
G(5)
E(6)
Better pathto G exists
G(3)
26
Example of Dijkstras Algorithm
Add B to Path
C(0)
F(2)
B(2)
A(8)
E(6)
E(3)
G(3)
27
Example of Dijkstras Algorithm
C(0)
F(2)
B(2)
A(8)
E(6)
E(3)
G(3)
Better pathto E exists
28
Example of Dijkstras Algorithm
C(0)
Add E to path
F(2)
B(2)
A(8)
E(3)
G(3)
D(5)
29
Original Distribution of LSPs
  • Neighbor-to-neighbor protocol for LSP
    distribution
  • Eash LSP consists of
  • Identity of router generating the LSP
  • A sequence number
  • The time left until the LSP should be discarded
  • A list of neighbors, and the cost of links to
    each
  • LSP is broadcast to all neighbors
  • LSPs have a 64 second lifetime - each router
    must resend each minute
  • Wrap-around comparison on sequence numbers used

30
Problem in 1991
  • A router announced LSPs with random TTLs
  • a lt b lt c lta
  • Each router that processed one of these LSPs
    over-wrote the one in memory and generated more
    copies of the bad LSP, since it thought that this
    LSP was newer needed to be propagated to
    neighbors
  • The TTL field never changed because of the rapid
    rate of updates

31
Revised method using 32-bit sequences
  • LSPs compared only by their sequence numbers -
    if you get LSP with sequence S T, and S lt T,
    then T is more recent (no matter what TTL says)
  • LSPs are purged when old, based on TTL. Every
    router decrements TTL
  • When TTL reaches 0, router refloods the LSP.
    Given (sequence, TTL) (S,x) (T,y) then S lt T if
    x 0, but not otherwise
  • LSPs generated much less frequently (1hr)
  • Router starts with the lowest sequence number. If
    the network retains old LSP, it will be flooded
    back to source, when then knows current
    sequence number to use

32
BGP
  • Replacement for EGP
  • AS classifications
  • Stub - only has a single connection to another AS
  • Multihomed - multiple connections, but doesnt
    carry transit traffic
  • Transit - has connections to more than one other
    AS and is designed to carry both local and
    transit traffic
  • BGP supports Policy Based Routing
  • Did you pay for this?

33
BGP
  • Uses TCP
  • Distance vector protocol, but BGP enumerates the
    route to each destination (using a sequence of AS
    numbers)
  • Each AS is identified by a 16-bit number

34
CIDR - Classless inter-domain routing
  • Based on hierarchy of address prefixes
Write a Comment
User Comments (0)
About PowerShow.com