Cis 185 CCNP Route Chapter 3: Implementing OSPF: Rick Graziani Cabrillo College Graziani@cabrillo - Edu Spring 2015
Cis 185 CCNP Route Chapter 3: Implementing OSPF: Rick Graziani Cabrillo College Graziani@cabrillo - Edu Spring 2015
Spring 2015
LSAs
OSPF packet types
3
Part I - LSAs using all normal areas
Multi Area OSPF
What are the router Backbone
types? Area Normal Areas
ASBR
Internal
Internal
Internal
4
Part I - LSAs using all normal areas
Routes Received on all OSPF Routers
R200
R2 router ospf 1
router ospf 1 network 99.0.0.4 0.0.0.3 area 51
network 192.168.2.0 0.0.0.255 area 0 network 99.0.0.0 0.0.255.255 area 51
network 10.0.0.0 0.0.0.3 area 0
network 11.0.0.0 0.0.0.3 area 0
default-information originate
ABR contains network statements for
ip route 0.0.0.0 0.0.0.0 serial 0/2 each area it belongs to, using the
proper area value.
LSAs using all normal areas
Multi Area OSPF
What are the router Backbone
types? Area Normal Areas
ASBR
Internal
Internal
Internal
7
Multi Area OSPF
What are the router Backbone Normal Areas
types? Area
ASBR
Internal
Internal
Internal
8
Multi Area OSPF
ASBR
Internal
Internal
Internal
9
Understanding LSAs (FYI ONLY)
show ip ospf database
This is not the link state database, only a summary.
It is a tool to help determine what routes are included in the routing table.
We will look at this output to learn the tool as well as become familiar with the
different types of LSAs.
To view the link state database use: show ip ospf database [router|network|…]
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS age | Options | LS type |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link State ID |
LSA Header +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Advertising Router |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS sequence number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS checksum | length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 10
LSA 1 - Router Link States
LSA 1 – Router LSA
Generated by each router for each area it belongs to.
Describes the states of the links in the area
B to which this router belongs.
LSA 1 - Router |
|
LS age |
Link State ID
Options | 1 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|
Link States
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Advertising Router |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS sequence number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS checksum | length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| 0 |V|E|B| 0 | # links |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link ID |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link Data |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type | # TOS | metric |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ... |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TOS | 0 | TOS metric |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link ID |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link Data |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ... |
12
LSA 1 – Router Link States
LSA 1’s
LSA 1’s
LSA 1’s
Each router floods their LSA 1s ONLY within their own area.
LSA 1s only announce the links (networks) within the area.
Router receives LSA 1s from neighbor, floods those LSA 1s to other
neighbors within the same area.
13
R100# show ip ospf database
OSPF Router with ID (100.100.100.100) (Process ID 1)
15
LSA 1 - Router Link States
LSA 1’s
LSA 1’s
LSA 1’s
16
LSA 2 - Network Link States
LSA 2’s
LSA 2’s
19
LSA 2 - Network Link States
R3# show ip ospf database
Net Link States (Area 51)
Link ID ADV Router Age Seq# Checksum
99.0.0.6 200.200.200.200 241 0x80000002 0x006159
LSA 2’s
LSA 2’s
21
LSA 3 – Summary Net Link States
24
LSA 3 – Summary LSAs
LSA 3’s
LSA 3’s
LSA 1’s
25
LSA 3 – Summary Net Link States
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS age | Options | 3 or 4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Link State ID |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Advertising Router |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS sequence number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LS checksum | length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Network Mask |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| 0 | metric |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TOS | TOS metric |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ... |
26
New or change, do
not run SPF
algorithm.
LSA 1’s
LSA 3’s
X LSA 3’s
Process using
DV technique
not LSA 1 Link
States.
• Routers only see the topology of the area they belong to.
• When a link in one area changes, the adjacent routers originate in LSA 1’s and
flood them within the area, causing intra-area (internal) routers to re-run the
SPF and recalculating the routing table.
• ABRs do not announce topological information between areas.
• ABRs only inject routing information into other areas, which is basically a
distance-vector technique. 27
LSA 1’s
LSA 3’s
LSA 3’s
• ABRs calculate intra-area routes and announce them to all other areas as
inter-area routes, using LSA 3’s.
• OSPF ABRs will only announce inter-area routes that were learned from the
backbone area, area 0.
• The backbone area serves as a repository for inter-area routes.
• This keeps OSPF safe from routing loops.
28
LSA 3 – Summary Net Link States (INTERNAL)
ABR
R33# show ip ospf database
Summary Net Link States (Area 1)
Link ID ADV Router Age Seq# Checksum
10.0.0.0 1.1.1.1 130 0x8000000c 0x00ec09
9.0.0.0 1.1.1.1 130 0x8000000d 0x00ec09
192.168.2.0 1.1.1.1 130 0x8000000e 0x00ec09
11.0.0.0 1.1.1.1 130 0x8000000f 0x00ec09
172.16.10.0 1.1.1.1 130 0x80000010 0x00ec09
172.16.11.0 1.1.1.1 130 0x80000011 0x00ec09
99.0.0.0 1.1.1.1 130 0x80000012 0x00ec09
99.0.0.4 • Link ID =
1.1.1.1 IP network
130addresses of networks
0x80000013 in other
0x00ec09 areas
99.1.0.0 • ADV Router = ABR
1.1.1.1 130Router ID 0x80000014
sending the0x00ec09
LSA-3
• Bottom line: Should see networks in other areas and the ABR
advertising that route.
• Rick’s reminder: LSA 3 -> “networks sent by the A B R”
1 2 3
33
LSA 3
R1# show ip ospf database
Summary Net Link States (Area 1) <- Per Area
Link ID ADV Router Age Seq# Checksum
10.0.0.0 1.1.1.1 255 0x8000000c 0x00ec09
9.0.0.0 1.1.1.1 255 0x8000000d 0x00ec09
192.168.2.0 1.1.1.1 255 0x8000000e 0x00ec09
11.0.0.0 1.1.1.1 255 0x8000000f 0x00ec09
172.16.10.0 1.1.1.1 255 0x80000010 0x00ec09
172.16.11.0 1.1.1.1 255 0x80000011 0x00ec09
99.0.0.0• ABR 1.1.1.1
will show all routes
255 it is injecting into the
0x80000012 other area
0x00ec09 including:
99.0.0.4 • LSA 3s from other 255
1.1.1.1 areas 0x80000013 0x00ec09
99.1.0.0 • LSA 1s from it’s adjacent
1.1.1.1 255 area it0x80000014
is injecting0x00ec09
into this area
• Bottom line: Should see networks in other areas and the ABR
advertising that route.
• Rick’s reminder: LSA 3 -> “networks sent by the A B R”
1 2 3 34
LSA 3 – Summary Net Link States
R2# show ip route
36
LSA 4 – ASBR
Summary Link
States
38
LSA 4 – ASBR Summary Link States
42
LSA 5 - AS External Link
States
ASBR
R2 (ASBR)
router ospf 1
redistribute static
ip route 57.0.0.0 255.0.0.0 ser 0/3
45
R2 (ASBR)
router ospf 1
redistribute static
ip route 57.0.0.0 255.0.0.0 ser 0/3
LSA 5
LSA 5’s
LSA 5
• Designated by “E2”
• Notice that the cost is 20 for all redistributed routes, we will see why later.
• It has to do with E2 routes and where the default cost is 20.
– Redistribute command (Route Optimization chapter): If a value is not
specified for the metric option, and no value is specified using the default-
metric command, the default metric value is 0, except for OSPF where the
default cost is 20.
• Cost of 1 for the redistributed route.
48
LSA 5 - AS External Link States
R33# show ip ospf database
49
LSA 5 - AS External Link States
E1 vs. E2 External Routes
External routes fall under two categories:
external type 1
external type 2 (default)
The difference between the two is in the way the cost (metric) of the route
is being calculated.
The cost of a type 2 route is always the external cost, irrespective of the
interior cost to reach that route.
A type 1 cost is the addition of the external cost and the internal cost
used to reach that route.
A type 1 route is always preferred over a type 2 route for the same
destination.
More later… 50
Stub Areas
Stub Areas
53
Stub Areas
Receives all routes from within A.S.:
Within the local area - LSA 1s and LSA 2s (if appropriate)
From other areas (Inter-Area) - LSA 3s
ABR:
ABR blocks all LSA 4s and LSA 5s.
‘If LSA 5s are not known inside an area, LSA 4s are not necessary.’
LSA 3s are propagated by the ABR.
R100 (INTERNAL)
router ospf 1
area 51 stub << Command: area area stub
Default
route to
ABR We only see routes in our
• Sent by ABR: LSA 3s (Inter-Area routes) injected area, other areas, and a
• Blocked: default route.
No external routes.
• LSA 4s (reachability to ASBR)
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in External routes no longer affect Stub Area routing tables. 56
Stub Areas
R100# show ip ospf database
61
Totally Stubby Areas
Receives routes from within A.S.:
Only from within the local area - LSA 1s and LSA 2s (if appropriate)
Does not receive routes from other areas (Inter-Area) - LSA 3s
ABR:
ABR blocks all LSA 4s and LSA 5s.
ABR blocks all LSA 3s, except propagating a default route.
Default route is injected into totally stubby area by ABR.
Configuring:
All routers must be configured as “stub”
ABR must be configured as “stub no-summary” 62
Totally Stubby
Areas
R1: (ABR)
router ospf 1
area 1 stub no-summary
^^ Command: area area stub no-summary
R22 and R33: (INTERNAL ROUTERS)
router ospf 1
area 1 stub
^^ Command: area area stub
63
LSA 1s still sent
Totally within each area.
Stubby Area
Stub Area
Blocked LSA 3 LSA 3
Blocked LSA 4 LSA 4 Blocked
Blocked LSA 5 LSA 5 Blocked
Default
Default
route to
We only see routes in our area and route to
ABR
a default route. ABR
injected No inter-area or external routes. We only see routes in
• Blocked:
injected our area, other areas,
• LSA 3s (Inter-Area routes) and a default route.
• LSA 4s (reachability to ASBR) No external routes.
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in other areas and external routes no longer affect Stub Area routing tables. 64
Totally Stubby
Areas
R33# show ip route
• Default route is injected into totally stubby area by ABR for all other networks
(inter-area and external routes)
• Does not receive routes from other areas (Inter-Area)
• Does not receive routes from External A.S. (External Routes) 65
Totally Stubby Areas
R1# show ip route
1.0.0.0/32 is subnetted, 1 subnets
C 1.1.1.1 is directly connected, Loopback0
9.0.0.0/24 is subnetted, 1 subnets
C 9.0.0.0 is directly connected, Serial0/1
10.0.0.0/30 is subnetted, 1 subnets
C 10.0.0.0 is directly connected, Serial0/0
11.0.0.0/30 is subnetted, 1 subnets
O 11.0.0.0 [110/1626] via 10.0.0.2, 00:05:26, Serial0/0
99.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O IA • Notice, there is no automatic default route on ABR, as there
99.0.0.0/30 [110/1690] via 10.0.0.2, 00:05:26, Serial0/0
O IA
O IA
are with the internal stub routers.
99.0.0.4/30 [110/1691] via 10.0.0.2, 00:05:26, Serial0/0
99.1.0.0/16 [110/1691] via 10.0.0.2, 00:05:26, Serial0/0
C
• This default route came from the ASBR.
172.16.0.0/24 is subnetted, 4 subnets
172.16.1.0 is directly connected, FastEthernet0/0
C • In other words the ABR will inject the default route into the
172.16.2.0 is directly connected, FastEthernet0/1
O IA 172.16.10.0 [110/1627] via 10.0.0.2, 00:05:26, Serial0/0
O IA stub area whether or not it has a default route in its routing
172.16.11.0 [110/1627] via 10.0.0.2, 00:05:26, Serial0/0
table.
172.30.0.0/24 is subnetted, 2 subnets
O 172.30.1.0 [110/2] via 172.16.1.2, 00:04:51, FastEthernet0/0
O 172.30.2.0 [110/2] via 172.16.1.3, 00:04:41, FastEthernet0/0
O 192.168.2.0/24 [110/65] via 10.0.0.2, 00:05:26, Serial0/0
O*E2 0.0.0.0/0 [110/1] via 10.0.0.2, 00:05:26, Serial0/0
66
Quick Review
67
LSA 1s – Router LSAs
LSA 1’s
LSA 1’s
LSA 1’s
LSA 2’s
LSA 2’s
LSA 3’s
LSA 3’s
LSA 1’s
LSA 5
LSA 5’s
LSA 5
Default
route to
ABR We only see routes in our
• Sent by ABR: LSA 3s (Inter-Area routes) injected area, other areas, and a
• Blocked: default route.
• LSA 4s (reachability to ASBR) No external routes.
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in External routes no longer affect Stub Area routing tables. 73
Totally Stubby Area LSA 1s still sent
Totally within each area.
Stubby Area Stub Area
Blocked LSA 3 LSA 3
Blocked LSA 4 LSA 4 Blocked
Blocked LSA 5 LSA 5 Blocked
Default
route to Default
ABR We only see routes in our area and route to
injected a default route. ABR
No inter-area or external routes. We only see routes in
• Blocked: injected our area, other areas,
• LSA 3s (Inter-Area routes) and a default route.
• LSA 4s (reachability to ASBR) No external routes.
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in other areas and external routes no longer affect Stub Area routing tab les. 74
Multiple ABRs and Calculating
the Cost of Intra-Area Routes
Cost Inter-Area Routes
10 + 21 = 30 My cost = 21
15 + 6 = 21
My
c os
t =6
91
Multiple ABRs
Routing
Table ABR1
RTA
Distribute
List LSA 1’s Network X
RTB
SPF
RTC ABR2
LSDB
Area 51 Area 0
92
Multiple ABRs
To ABR
Routing
Table ABR1
RTA
Distribute
Link State Logic
List LSA 3’s Network X
RTB
With stub and totally stubby areas this may not be the most optimum route!
94
Multiple ABRs – Stub Networks
Totally Stubby Area
ABR2 is “closer” a My cost to
lesser metric, so I will ABR1 network X is
RTA
use ABR2 for all Cost = 10 10
routes outside my LSA 3’s Network X
RTB Cost = 5
area even if its not
the most optimum Default Route My cost to
path. RTC ABR2 network X is
200
Area 51 Area 0
Stub and totally stubby area ABRs inject a default route into the area.
Stub ABRs block LSA 4’s and 5’s (external networks)
Totally Stubby ABRs block LSA 3’s (interarea networks), 4’s and 5’s (external
networks)
In both cases internal routers can only determine the best route to an ABR, which
may not be the best route to the destination network. 95
Virtual Links
Virtual Links
97
Virtual Links
99
Virtual Links
100
The command to configure a virtual link is as follows:
area <area-id> virtual-link <remote-router-id>
RTA(config)#router ospf 1
RTA(config-router)#network 192.168.0.0 0.0.0.255 area 51
RTA(config-router)#network 192.168.1.0 0.0.0.255 area 3
RTA(config-router)#area 3 virtual-link 10.0.0.1
…
RTB(config)#router ospf 1
RTB(config-router)#network 192.168.1.0 0.0.0.255 area 3
RTB(config-router)#network 192.168.2.0 0.0.0.255 area 0
RTB(config-router)#area 3 virtual-link 10.0.0.2
101
Virtual
Links
OSPF allows for linking
discontinuous parts of
the backbone using a
virtual link.
OSPF messages
between virtual link
routers sent as unicast.
router ospf 1
area 1 virtual-link 4.4.4.4
C1 interface loopback 1
ip address 1.1.1.1 255.255.255.0
router ospf 4
area 1 virtual-link 1.1.1.1
C2
interface loopback 1
ip address 4.4.4.4 255.255.255.0 102
Route Summarization
Route
Summarization
Inter-Area Route Summarization - Area Range
By default ABRs do not summarize routes between areas.
In OSPF, an ABR will advertise networks in one area into another area.
If at least one component subnet exists (subnets that sit inside the range), then the ABR advertises
the summary route as a Type 3 LSA.
If no component subnets exist, the ABR does not advertise the summary.
The ABR assigns a metric for the summary route's Type 3 LSA, by default, to match the best
(lowest) metric amongst all component subnets.
The area range command can also explicitly set the cost of the summary.
On the ABR (Summarizes routes before injecting them into different area)
Router(config-router)# area area-id range network-address subnet-mask
area-id - Identifier of the area about which routes are to be summarized.
(From area)
106
172.17.1.0/24
172.17.2.0/24
172.17.3.0/24
172.17.4.0/24
172.17.5.0/24
172.17.6.0/24
172.17.7.0/24
Summarize Area 1 172.17.0.0 routes on Area 1 ABRs .
107
172.17.1.0/24
172.17.2.0/24
172.17.3.0/24
172.17.4.0/24
172.17.5.0/24
172.17.6.0/24
172.17.7.0/24
110
Inter-Area Route Summarization - Area Range
Before
R2# show ip route
172.17.0.0/24 is subnetted, 7 subnets
O IA 172.17.1.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.2.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.3.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.4.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.5.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.6.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
O IA 172.17.7.1 [110/66] via 10.0.0.1, 00:02:19, Serial0/0
After
R2# show ip route
ASBR
router ospf 1
summary-address 128.213.64.0 255.255.224.0
redistribute bgp 50 metric 1000 subnets (later)
113
Default Routes
Injecting Default Routes into OSPF
By default, 0.0.0.0/0 route is not propagated from the ASBR to other routers.
An autonomous system boundary router (ASBR) can be forced to generate a default
route into the OSPF domain.
As discussed earlier, a router becomes an ASBR whenever routes are redistributed
into an OSPF domain.
However, an ASBR does not, by default, generate a default route into the OSPF
routing domain. 115
Injecting Default Routes into OSPF
The way that OSPF generates default routes (0.0.0.0) varies depending on the type of
area the default route is being injected into.
Stub and Totally Stubby Areas
For stub and totally stubby areas, the area border router (ABR) to the stub area
generates a summary link-state advertisement (LSA) with the link-state ID 0.0.0.0.
This is true even if the ABR doesn't have a default route.
In this scenario, you don't need to use the default-information originate command. 116
Stub Area LSA 1s still sent
within each area.
Stub Area
LSA 3 LSA 3
LSA 4 LSA 4 Blocked
LSA 5 LSA 5 Blocked
Default
route to
ABR We only see routes in our
• Sent by ABR: LSA 3s (Inter-Area routes) injected area, other areas, and a
• Blocked: default route.
• LSA 4s (reachability to ASBR) No external routes.
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in External routes no longer affect Stub Area routing tables. 117
Totally Stubby Area LSA 1s still sent
Totally within each area.
Stubby Area Stub Area
Blocked LSA 3 LSA 3
Blocked LSA 4 LSA 4 Blocked
Blocked LSA 5 LSA 5 Blocked
Default
route to Default
ABR We only see routes in our area and route to
injected a default route. ABR
No inter-area or external routes. We only see routes in
• Blocked: injected our area, other areas,
• LSA 3s (Inter-Area routes) and a default route.
• LSA 4s (reachability to ASBR) No external routes.
• LSA 5s (External routes)
• The ABR injects a default route into the stub area, pointing to the ABR.
• This does not mean the ABR has a default route of its own.
• Changes in other areas and external routes no longer affect Stub Area routing tab les. 118
Injecting Default Routes into OSPF
Normal Areas
By default, in normal areas routers don't generate default routes.
To have an OSPF router generate a default route, use the default-information originate command.
This generates an external type-2 link with link-state ID 0.0.0.0 and network mask 0.0.0.0.
This command should only be used on the ASBR.
Some documentation states this command works only on an ASBR while other documentation
states this command turns a router into an ASBR .
119
Injecting Default Routes into OSPF
router ospf 10
default-information originate [always] [metric metric-value]
[metric-type type-value] [route-map map-name] 120
Injecting Default Routes into OSPF
There are two ways to generate a default.
1) default-information originate
Conditional: If the ASBR already has the default route (ip route 0.0.0.0 0.0.0.0),
you can advertise 0.0.0.0 into the area.
ASBR
router ospf 1
network 172.16.1.0 0.0.0.255 area 0
default-information originate
ip route 0.0.0.0 0.0.0.0 10.0.0.2 122
Injecting Default Routes into OSPF
No 0.0.0.0/0 route, but
propagated anyway or
“always”
ASBR
router ospf 1
network 172.16.1.0 0.0.0.255 area 0
default-information originate always
123
Redistributing External Routes
E1 vs. E2 External Routes
External routes fall under two categories:
External type 1
External type 2.
The difference between the two is in the way the cost (metric) of the route is being
calculated.
A type 1 (E1) cost is the addition of the external cost and the internal cost used to
reach that route.
The cost of a type 2 (E2) route is always the external cost, irrespective of the interior
cost to reach that route.
Type 2 (E2) is the default!
124
Redistributing External Routes metric-type 1
RIP routes redistributed with a metric
(cost) of 500 plus the outgoing cost of
the interface and a metric-type 1
564 564
565
566
ASBR
router ospf 1
redistribute rip metric 500 metric-type 1
network 206.202.0.0 0.0.0.255 area 0 127
Redistributing External Routes metric-type 2
500 500
500
500
ASBR
router ospf 1
redistribute rip metric 500 metric-type 2
network 206.202.0.0 0.0.0.255 area 0 128
MPLS and OSPF
129
Adjacency over Layer 2 MPLS VPN
To the customer routers running OSPF (routers R1 and R2), the Layer 3
MPLS VPN backbone looks like a standard corporate backbone.
The CE routers form adjacencies with the PE routers.
The OSPF network type of the CE-PE link can be point-to-point, broadcast
or NBMA.
132
Configuring OSPF – Part 2 of 2