In other words, it tells the router to create and flood information about a default route throughout the OSPF domain.
The default-information originate command tells the ASBRs to flood a default route into OSPF, but only if the ASBR itself has a default route in its IP routing table.
General syntax:
default-information originate [always] [metric metric-value] [metric-type typevalue] [route-map map-name]
The following list summarizes the features of the default-information originate OSPF subcommand:
■ With all default parameters, it injects a default route into OSPF, as an External Type 2 route, using a Type 5 LSA, with metric 1, but only if a default route exists in that router’s routing table.
■ With the always parameter, the default route is advertised even if there is no default route in the router’s routing table.
■ The metric keyword defines the metric listed for the default route (default 1).
■ The metric-type keyword defines whether the LSA is listed as external type 1 or external type 2 (default).
■ The decision of when to advertise, and when to withdraw, the default route is based on matching the referenced route-map with a permit action.
Configure a default route on R4, pointing to a router in the EIGRP domain as the next-hop and advertise that route into the OSPF domain:
R4(config)#ip route 0.0.0.0 0.0.0.0 172.16.0.10
R4#show ip route
...
Gateway of last resort is 172.16.0.10 to network 0.0.0.0
...
S* 0.0.0.0/0 [1/0] via 172.16.0.10
R4(config)#router ospf 1
R4(config-router)#default-information originate
The route is propagated to R1, which adds it to its routing table and sets R4 as the Gateway of last resort:
R1#show ip route
...
Gateway of last resort is 192.168.0.14 to network 0.0.0.0
...
O*E2 0.0.0.0/0 [110/1] via 192.168.0.14, 00:00:42, Serial0/1
This route has a metric of 1 and default external Type 2 OSPF.
The route is also propagated (through the Type 5 LSA) to routers in other areas (except stub or NSSA areas):
R5 (also in Area 0):
R5#show ip route
...
Gateway of last resort is 192.168.0.17 to network 0.0.0.0
...
O*E2 0.0.0.0/0 [110/1] via 192.168.0.17, 00:10:11, Serial0/0
R5#show ip ospf database
OSPF Router with ID (5.5.5.5) (Process ID 1)
...
Type-5 AS External Link States
Link ID ADV Router Age Seq# Checksum Tag
0.0.0.0 4.4.4.4 1101 0x80000001 0x00C2DF 1
R11 (in Area 2):
R11#show ip route
...
Gateway of last resort is 10.0.1.1 to network 0.0.0.0
...
O*E2 0.0.0.0/0 [110/1] via 10.0.1.1, 00:10:35, Serial0/0.1
R11#show ip ospf data
OSPF Router with ID (11.11.11.11) (Process ID 1)
...
Type-5 AS External Link States
Link ID ADV Router Age Seq# Checksum Tag
0.0.0.0 4.4.4.4 855 0x80000001 0x00C2DF 1
No comments:
Post a Comment