cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3632
Views
8
Helpful
8
Replies

Question about default-information originate

rookie R
Level 1
Level 1

Hello there!


From what I understand, the

default-information originate

should generate an OE2 default route only if there is already a default route in the routing table.
My question is, Would it still generate a default route due to the

default-information originate

if the default route is an OE2 OSPF route? I think it would not,but I am not sure,and I can't find any link to prove that. It would be nice to send me a link as well.

Thanks so much!

1 Accepted Solution

Accepted Solutions

My friends,

Please allow me to join and add a few comments.

@Flavio Miranda , I respectfully beg to disagree with you. You configured the first router with a static default route and in OSPF, you configured "default-information originate". That's okay and that is why this first router is injecting a default route in OSPF. However, the second router receives and propagates this default route in OSPF regardless of having "default-information originate" configured on it. If Packet Tracer emulates the IOS OSPF faithfully, the presence of the "default-information originate" command on the second router with your particular topology and configuratio will make no difference whatsoever.

If we dig deeper into the meaning of this command, the "default-information originate" commands the router to originate its own Type-5 LSA for the network 0.0.0.0/0 if there already is a default route in the routing table installed from a different routing process. We need to be very mindful of this difference: Originating a Type-5 LSA is different from flooding someone else's Type-5 LSA.

In a regular area, we flood anyone's Type-5 LSAs without any extra configuration; in other words, we don't need to configure "default-information originate" to flood someone else's Type-5 LSA advertising a default route. The originating router of that Type-5 LSA will be the final OSPF router that the outbound traffic flows through before exiting our autonomous system.

If I, as a router, originate my own Type-5 LSA for the default route, then I am myself claiming to the other routers that I am also directly connected with the outside world and I can also be used as the final exit from the autonomous system. I will always pass other router's Type-5 LSAs (assuming a regular area, not the stubby types) and I won't conceal their existence, but with "default-information originate", I will add my own offer to be an exit point. So whoever is closer to me than to other exit points in terms of OSPF cost will be using me to reach the external networks; whoever is closer to them will be using them.

So that is why configuring the "default-information originate" on your second 1941 router in the topology does not make sense, and also does not make any difference: Regardless of the configuration, that router will flood the Type-5 LSA received from the first router on the left but it will not add originate its own Type-5 LSA to also pose itself as a valid exit point from the autonomous system. If you only look into the routing tables, you won't be able to tell the difference because for the third router, the next hop would be the same in either case. You would need to look into the OSPF link-state database to see how many Type-5 LSAs for the network 0.0.0.0/0 are there and who originated them.

M02@rt37 , you are almost correct. In reality, what happens is this: The "default-information" originate command makes the router check the routing table to see if there is a default route learned from any other source than the same OSPF process where this command is configured. If there is such a default route, the router will inject the default route by originating its own Type-5 LSA for it. If, however, the router finds out that there is no default route in the routing table, or that the default route there is from the same OSPF process, it won't inject a default route on its own because all that's needed is to flood the existing information about the default route that already exists in the OSPF process - and that happens automatically as part of routine OSPF operations.

This has an interesting consequence: If one router runs two different OSPF processes, say, "router ospf 1" and "router ospf 2", then if it learns a default route in OSPF process 1, it can still inject it using "default-information originate" into OSPF process 2.

The bottom line is: The "default-information originate" causes the router to inject a default route by originating the router's own Type-5 LSA for it, under the condition that the routing table on the router contains the default route from a different routing information source than the same OSPF process which is being configured with this command. The different routing information source may be a different routing protocol altogether, a static route, DHCP, or a different OSPF process.

Please feel welcome to ask further!

Best regards,
Peter

 

View solution in original post

8 Replies 8

Hi @rookie R 

 It will. I just did the following lab here on

PacketTracer

.

In one router I added a default route and the command

default-information originate

First Router:

!

router ospf 1

log-adjacency-changes

redistribute static subnets

network 10.10.30.12 0.0.0.3 area 0

default-information originate


!

ip classless

ip route 0.0.0.0 0.0.0.0 10.10.20.2


!




On the neighbor, I added only the command "default-information originate"




Second Router

!

router ospf 1

log-adjacency-changes

network 10.10.30.0 0.0.0.3 area 0

network 10.10.30.12 0.0.0.3 area 0

default-information originate

!

LA_1941#sh ip route static  (No static/default route here)

LA_1941#

LA_1941#







LA_1941#sh ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

* - candidate default, U - per-user static route, o - ODR

P - periodic downloaded static route




Gateway of last resort is 10.10.30.14 to network 0.0.0.0




10.0.0.0/8 is variably subnetted, 10 subnets, 4 masks

C 10.10.10.0/23 is directly connected, GigabitEthernet0/1

L 10.10.10.1/32 is directly connected, GigabitEthernet0/1

C 10.10.30.0/30 is directly connected, GigabitEthernet0/0/0

L 10.10.30.2/32 is directly connected, GigabitEthernet0/0/0

O 10.10.30.4/30 [110/2] via 10.10.30.1, 00:21:35, GigabitEthernet0/0/0

O 10.10.30.8/30 [110/2] via 10.10.30.1, 00:21:35, GigabitEthernet0/0/0

C 10.10.30.12/30 is directly connected, GigabitEthernet0/0

L 10.10.30.13/32 is directly connected, GigabitEthernet0/0

O E2 10.20.30.0/29 [110/20] via 10.10.30.1, 00:21:35, GigabitEthernet0/0/0

O 10.30.30.0/30 [110/2] via 10.10.30.1, 00:21:35, GigabitEthernet0/0/0

O*E2 0.0.0.0/0 [110/1] via 10.10.30.14, 00:08:34, GigabitEthernet0/0 (default route received as 0*E2)





On the next router, I can see the default route propagated as 0*E2




Third Router




SD_1941>en

SD_1941#sh ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

* - candidate default, U - per-user static route, o - ODR

P - periodic downloaded static route




Gateway of last resort is 10.10.30.5 to network 0.0.0.0




10.0.0.0/8 is variably subnetted, 8 subnets, 3 masks

O 10.10.30.0/30 [110/2] via 10.10.30.5, 00:23:52, GigabitEthernet0/0/0

C 10.10.30.4/30 is directly connected, GigabitEthernet0/0/0

L 10.10.30.6/32 is directly connected, GigabitEthernet0/0/0

O 10.10.30.8/30 [110/2] via 10.10.30.5, 00:25:58, GigabitEthernet0/0/0

O 10.10.30.12/30 [110/3] via 10.10.30.5, 00:17:11, GigabitEthernet0/0/0

C 10.20.30.0/29 is directly connected, GigabitEthernet0/0

L 10.20.30.1/32 is directly connected, GigabitEthernet0/0

O 10.30.30.0/30 [110/2] via 10.10.30.5, 00:29:09, GigabitEthernet0/0/0

O*E2 0.0.0.0/0 [110/1] via 10.10.30.5, 00:10:56, GigabitEthernet0/0/0


 

 

FlavioMiranda_0-1691228232133.png

 

The

PacketTracer

file is attached in case you want to test.

 

Hello @Flavio Miranda ,

to understand what is really happening you need to use the command

show ip ospf database external 0.0.0.0

to find out how many LSA type 5 exist and who has generated it/them

In this case, there should be only one generated by R1 and propagated by R2 to R3.

Looking at the IP routing table is not enough to understand what a link state protocol like OSPF is doing.

As noted by @Peter Paluch  in his long, but nice to read, explanation post.

Hope to help

Giuseppe

 

@Giuseppe Larosa ,

As noted by @Peter Paluch  in his long, but nice to read, explanation post.

LOL, is that a hidden nudge for me to stop ranting? : D

Best regards,
Peter

 

M02@rt37
VIP
VIP

Hello @rookie R,

You are correct. The

default-information originate

command in OSPF is used to inject a

default route (0.0.0.0/0) 

into the OSPF routing domain and advertise it to other OSPF routers. However, it will only generate a

default route

if there is an existing default route in the routing table, regardless of whether the existing

default route

is an OSPF External Type 2 (OE2) route or not.

If the existing

default route

in the routing table is an OE2 OSPF route, the

default-information originate

command will not generate a new

default route

. The command will use the existing

default route

as the one to be originated and advertised to other OSPF routers.

 

Best regards
.ı|ı.ı|ı. If This Helps, Please Rate .ı|ı.ı|ı.

My friends,

Please allow me to join and add a few comments.

@Flavio Miranda , I respectfully beg to disagree with you. You configured the first router with a static default route and in OSPF, you configured "default-information originate". That's okay and that is why this first router is injecting a default route in OSPF. However, the second router receives and propagates this default route in OSPF regardless of having "default-information originate" configured on it. If Packet Tracer emulates the IOS OSPF faithfully, the presence of the "default-information originate" command on the second router with your particular topology and configuratio will make no difference whatsoever.

If we dig deeper into the meaning of this command, the "default-information originate" commands the router to originate its own Type-5 LSA for the network 0.0.0.0/0 if there already is a default route in the routing table installed from a different routing process. We need to be very mindful of this difference: Originating a Type-5 LSA is different from flooding someone else's Type-5 LSA.

In a regular area, we flood anyone's Type-5 LSAs without any extra configuration; in other words, we don't need to configure "default-information originate" to flood someone else's Type-5 LSA advertising a default route. The originating router of that Type-5 LSA will be the final OSPF router that the outbound traffic flows through before exiting our autonomous system.

If I, as a router, originate my own Type-5 LSA for the default route, then I am myself claiming to the other routers that I am also directly connected with the outside world and I can also be used as the final exit from the autonomous system. I will always pass other router's Type-5 LSAs (assuming a regular area, not the stubby types) and I won't conceal their existence, but with "default-information originate", I will add my own offer to be an exit point. So whoever is closer to me than to other exit points in terms of OSPF cost will be using me to reach the external networks; whoever is closer to them will be using them.

So that is why configuring the "default-information originate" on your second 1941 router in the topology does not make sense, and also does not make any difference: Regardless of the configuration, that router will flood the Type-5 LSA received from the first router on the left but it will not add originate its own Type-5 LSA to also pose itself as a valid exit point from the autonomous system. If you only look into the routing tables, you won't be able to tell the difference because for the third router, the next hop would be the same in either case. You would need to look into the OSPF link-state database to see how many Type-5 LSAs for the network 0.0.0.0/0 are there and who originated them.

M02@rt37 , you are almost correct. In reality, what happens is this: The "default-information" originate command makes the router check the routing table to see if there is a default route learned from any other source than the same OSPF process where this command is configured. If there is such a default route, the router will inject the default route by originating its own Type-5 LSA for it. If, however, the router finds out that there is no default route in the routing table, or that the default route there is from the same OSPF process, it won't inject a default route on its own because all that's needed is to flood the existing information about the default route that already exists in the OSPF process - and that happens automatically as part of routine OSPF operations.

This has an interesting consequence: If one router runs two different OSPF processes, say, "router ospf 1" and "router ospf 2", then if it learns a default route in OSPF process 1, it can still inject it using "default-information originate" into OSPF process 2.

The bottom line is: The "default-information originate" causes the router to inject a default route by originating the router's own Type-5 LSA for it, under the condition that the routing table on the router contains the default route from a different routing information source than the same OSPF process which is being configured with this command. The different routing information source may be a different routing protocol altogether, a static route, DHCP, or a different OSPF process.

Please feel welcome to ask further!

Best regards,
Peter

 

Thanks @Peter Paluch for that clarification.

Best regards
.ı|ı.ı|ı. If This Helps, Please Rate .ı|ı.ı|ı.

Thanks so much. It's a great honor for you to answer my question. I read some of your billions of posts, which greatly helped me. Your spirit of helping others inspires me to learn more and to help others with my limited knowledge.

Would you please answer another question for me? How do I find answers like this on my own, I mean, I searched this

default-information originate

  command, but all the articles only talk about the basic meaning of it. And I also tested it on EVE-NG only to find out that the

default-information originate 

command won't generate a

default route

when there is already an OE2

default route

in the RIB, but I can't find any determine evidence to support my guess, not to mention about the

default route

can be generated from another OSPF process thing, and I am afraid that I was wrong so I came here to ask for help.

Hello @rookie R ,

Hey... you make me blush. Thank you very much for your kind words! I am only trying to make myself helpful...

Finding in-depth answers to these questions - that's admittedly sometimes a challenge. The main resource I recommend are Cisco IOS and IOS XE Configuration Guides, Command References, and Troubleshooting Technotes. And the next step would be understanding the protocol (RFCs, for example), and then labbing. If you understand how the protocol works, it also translates into your understanding what is the expected effect of a command. The labbing then helps to uncover the parts of the functionality that are more poorly described.

And of course, these forums here.

I am not sure if this answer is satisfactory... but it is probably the best one I can give right now.

You are always welcome here.

Best regards,
Peter

 

Review Cisco Networking for a $25 gift card