Beruflich Dokumente
Kultur Dokumente
OSPF Fundamentals
Open Shortest Path First Routing Protocol
Internets Second IGP
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
Page 41 - 1
this led to
link-state protocols
OSPF is an important implementation for IP
basic idea: every router knows topology of the
whole network, including subnets and other
routers
see RFC 2328 (2178, 1583 are obsolete)
Page 41 - 2
OSPF Domain
N2
R2
R1 1
N12
1
N1
N4
R4
edge
point-to-point network
N11
R9
(N12,13,14,15)
R3
R5
1
N14
external networks
knot
N3
N13
N9
N12
N15
5 R10
N8
6
R7
R11
R6
N6
1
LAN network
R12
R8
N10
2007, D.I. Manfred Lindner
N7
OSPF Principles
Page 41 - 3
R2
R1
N13
8
R4
N3
1
R5
2
6
R3
R9
1
2
N9
N12
R7
R11
R6
N11
N14
N15
R10
N8
N6
1
R12
2
R8
R5 and R7 (both are ASBR) have e.g. BGP
connections to other Autonomous Systems
N10
2007, D.I. Manfred Lindner
N7
OSPF Fundamentals, v4.5
Routing Table
Page 41 - 4
NEXT HOP
DISTANCE
N1
N2
N3
N4
N6
N7
N8
N9
N10
N11
R3
R3
R3
R3
R10
R10
R10
R10
R10
R10
10
10
7
8
8
12
10
11
13
14
R5
R7
R5
R10
6
8
NEXT HOP
R10
R5
R5
R10
DISTANCE
10
14
14
17
Page 41 - 5
10
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
11
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Summary Cost
Router-Name
Router-Name of Predecessor
Rx
Selected
Boundary
Rx
Rx
Ry
Ry
Ry
Page 41 - 6
12
The Principle
Select Root
predecessor = Root
cost = 0
Selected = true
13
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R2
R1
R1
R6
R1
R7
15
R1
Page 41 - 7
14
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
15
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
Page 41 - 8
R4
R3
16
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
17
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
R4
R3
R6
R1
R8
23
R7
R9
R4
R5
R4
Page 41 - 9
18
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
R4
R3
R6
R1
R8
23
R7
R9
R4
R5
R4
R6
R1
R9
R4
R8
20
R6
R5
R4
19
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
R4
R3
R6
R1
R8
23
R7
R9
R4
R5
R4
R6
R1
R9
R4
R8
20
R6
R5
R4
R5
R4
R9
R4
R8
12
R5
Page 41 - 10
20
R3
2
6
15
R1
15
R4
R8
R7
15
R9
11
R6
R5
6
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
R4
R3
R6
R1
R8
23
R7
R9
R4
R5
R4
R6
R1
R9
R4
R8
20
R6
R5
R4
R5
R4
R9
R4
R8
12
R5
R9
R4
R8
12
R5
21
R3
2
6
R1
R8
R7
R4
R9
R6
R5
Selected
Boundary
R1
R1
R2
R1
R6
R1
R7
15
R1
R2
R1
R6
R1
R7
R2
R3
R2
R3
R2
R6
R1
R7
R2
R9
21
R3
R4
R3
R7
R2
R6
R1
R4
R3
R9
10
R7
R8
23
R7
R4
R3
R6
R1
R8
23
R7
R9
R4
R5
R4
R6
R1
R9
R4
R8
20
R6
R5
R4
R5
R4
R9
R4
R8
12
R5
R9
R4
R8
12
R5
R8
12
R5
Page 41 - 11
22
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
23
Page 41 - 12
24
25
Page 41 - 13
26
27
Page 41 - 14
28
let's get
acquainted !
somebody
out there?
hello
hello
29
here is my
topology
database
Page 41 - 15
30
LS request
31
LS update
Page 41 - 16
32
thanks - got it
LS ack
33
Page 41 - 17
34
LS request
35
LS update
Page 41 - 18
36
nice
neighbourhood
here...
thanks - got it
LS ack
37
I must tell
everybody...
I must tell
everybody...
L
ter
u
o
r
SA
SA
SA
SA
rL
ute
ro
L
er
ut
ro
ro
rL
ute
rou
ter
LSA
Page 41 - 19
38
OSPF Start-up
DB R3
DB R2
R3
DB R1
R2
R1
39
OSPF Hello R1 - R2
DB R3
DB R2
DB R1
Hello
R3
R2
Hello
R1
Page 41 - 20
40
DB R2
DB R1
DB-Desc
R3
R2
LS-Request
R1
41
DB R2
DB R1
LS-Update
R3
R2
LS-Ack
R1
Page 41 - 21
42
DB R2
DB R1
DB-Desc
R3
R2
LS-Request
R1
43
DB R2
DB R1
LS-Update
R3
R2
LS-Ack
R1
Page 41 - 22
44
DB R2
R3
DB R1
R2
Router LSA R2
R1
Router LSA R1
45
OSPF Hello R2 - R3
DB R3
DB R2
DB R1
Hello
R3
R2
R1
Hello
link between R2-R3 activated: get acquainted
using Hello, determination of designated router
2007, D.I. Manfred Lindner
Page 41 - 23
46
DB R2
DB R1
LS-Update
R3
R2
R1
LS-Update
R2 and R3 synchronize their databases
(DB-Des., LS-Req.,LS-Upd., LS-Ack.)
2007, D.I. Manfred Lindner
47
DB R2
R3
R2
DB R1
R1
Router LSA R2
Page 41 - 24
48
DB R2
R3
DB R1
R2
Router LSA R3
R1
49
DB R2
DB R1
point-to-point network
R3
Stub
Network
R2 Network LSA R2
R1
Transit
Network
Designated Router R2 notifies other nodes about the multi-access network using
Network-LSA (transport mechanism are LS-Update packets hop-by-hop
2007, D.I. Manfred Lindner
Page 41 - 25
50
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
51
Page 41 - 26
52
LSA Broad 1
Sequence
number
LSA R1
R1-R6 / 88
S1
S0
R2
S0
S0
R4
R6
R1
S1
S1
R3
S0
S1
LSA R1-R6 / 88
LSA R1
R1-R6 / 88
53
LSA Broad 2
LSA R1
R1-R6 / 88
LSA Source ACK R1-R6 / 88
R1-R6 / 88
S1
S0
R2
S0
S0
R4
R6
R1
S1
S1
R3
S1
S0
ACK R1-R6 / 88
LSA R1
R1-R6 / 88
OSPF Fundamentals, v4.5
Page 41 - 27
54
LSA Broad 3
LSA R1
R1-R6 / 88
S1
LSA Source
R1-R6 / 88
S0
LSA R1-R6 / 88
R2
S0
S0
R4
R6
R1
S1
S1
R3
S0
S1
LSA R1
R1-R6 / 88
R2 sends LSA R1-R6
->R4 updates its DB
LSA R1
R1-R6 / 88
55
LSA Broad 4
LSA R1
R1-R6 / 88
S1
LSA Source
R1-R6 / 88
S0
Ack R1-R6 / 88
R2
S0
S0
R4
R6
R1
S1
S1
R3
S1
S0
LSA R1
R1-R6 / 88
R4 confirms LSA R1-R6
LSA R1
R1-R6 / 88
OSPF Fundamentals, v4.5
Page 41 - 28
56
LSA Broad 5
LSA R1
R1-R6 / 88
S1
LSA Source
R1-R6 / 88
LSA R1
R1-R6 / 88
S0
R2
S0
S0
R4
R6
R1
S1
S1
S1
R3
S0
Propagation
of LSA
stopped here
LSA R1-R6 / 88
LSA R1
R1-R6 / 88
Ack R1-R6 / 88
57
LSA Usage
reasons:
automatic correction of unnoticed topology-mistakes (e.g.
happened during distribution or some router internal
failures in the memory)
combining two separated parts of an OSPF area (here
OSPF also assures database consistency without
intervention of an administrator)
Page 41 - 29
58
59
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
Page 41 - 30
60
DB R3b
R4a
R3a
R3b
R2b
R1a
R2a
R1b
DB R1a
DB R1b
61
DB R3b
R4a
R3a
R3b
Hello
R2b
R1a
R1b
R2a
Hello
DB R1a
DB R1b
Page 41 - 31
62
DB R3b
R4a
R3a
R3b
LS-Update
R2b
R1a
R1b
R2a
LS-Update
DB R1a
DB R1b
LS-Updates
describe whole
domain topologies
63
DB R3b
Router-LSA
R1a
R1b
R4a
R3a
R3b
Router-LSA
Router-LSA
R2b
R1a
R1b
R2a
Router-LSA
DB R1a
Router-LSA
DB R1b
Router-LSAs
describe local
links only !!!
2007, D.I. Manfred Lindner
Page 41 - 32
64
Inconsistent Databases !
DB R3a
DB R3b
R4a
R3a
R3b
R2b
R1a
R1b
R2a
DB R1a
DB R1b
65
DB R3b
R4a
R3a
Router-LSA R3b
R2b
R1a
R1b
R2a
DB R1a
R3b
Router-LSA
describes
link R3b-R1b
link R3b-R2b
OSPF Fundamentals, v4.5
Page 41 - 33
DB R1b
66
DB R3b
Router-LSA
R3a
R4a
R3a
R3b
Router-LSA
R2b
R1a
R1b
R2a
DB R1a
Router-LSA
describes
link R3a-R4a
link R3a-R2a
DB R1b
67
Improvement
Page 41 - 34
68
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
69
Page 41 - 35
70
Broadcast Network
Any-to-Any Relation
R2
R1
R3
R5
R4
Router-Router Neighbourhood-Relation
2007, D.I. Manfred Lindner
71
Page 41 - 36
72
therefore
a Backup Designated Router (BR) is used
DR and BR
are elected by exchanging hello-messages at start-up
Attention !!!
this concept influences only how routing information is
exchanged among those routers
no influence on actual IP forwarding which is based on
routing tables
2007, D.I. Manfred Lindner
73
R1
R3
R5
R4
Router-Router Neighbourhood-Relation
2007, D.I. Manfred Lindner
Page 41 - 37
74
75
DB R2
DB R1
point-to-point network
R3
Stub
Network
R2 Network LSA R2
R1
Transit
Network
Designated Router R2 notifies other nodes about the multi-access network using
Network-LSA (transport mechanism are LS-Update packets hop-by-hop
2007, D.I. Manfred Lindner
Page 41 - 38
76
77
Page 41 - 39
78
Agenda
OSPF Principles
Introduction
The Dijkstra Algorithm
Communication Procedures
LSA Broadcast Handling
Splitted Area
Broadcast Networks
Summary of Benefits
79
Link-State:
every router notifies all routers about the state of his
directly connected links
using flooding mechanism (LSA)
calculates optimal paths whenever a new LSA is received
Page 41 - 40
80
OSPF Benefits 1
81
OSPF Benefits 2
Page 41 - 41
82
OSPF Benefits 3
83
OSPF Benefits 4
Page 41 - 42
84
Page 41 - 43
85