02-16-2021 12:16 PM - edited 02-16-2021 12:18 PM
Hi,
I´ve a technical question about the use of the "default-information orignate" command in OSPF! I`d like to anncounce a local static Default-Route into OSPF via two different Link-Networks to a L3 Stack! The Interfaces which connect the Router to the Stack-Members have already different Costs but that don`t influence the Default-Route because on the Stack I can see two entries for 0.0.0.0/0 learned - which probably indicate a Equal-Cost Link-Balancing?!
As I can see, when I setup two different OSPF Processes and put into each one of the Link-Networks with a "default-information originate /w different metrics" it seems to work as I`d like it to be, meaning that one Connection/Link is prefered over the other and the second one kicks in when the primary Link e.g. fails...
Can someone explain that behavior in more detail for me and tell me if this procedure is correctly used in the form?!
thanks in advance!
02-16-2021 01:19 PM
Question - why do you need two 2 different OSPF processes here on 1 device? if you are playing with metric,
what is the goal here failover between the links?
02-16-2021 01:44 PM - edited 02-17-2021 02:33 AM
which type default route appear is it E1 or E2?
Use E1 as type make the OSPF take Cost to router "config with default information"
While E2 not take cost "defualt type"
02-16-2021 11:27 PM
Hello @whistleblower14 ,
>> As I can see, when I setup two different OSPF Processes and put into each one of the Link-Networks with a "default-information originate /w different metrics" it seems to work as I`d like it to be, meaning that one Connection/Link is prefered over the other and the second one kicks in when the primary Link e.g. fails...
Different OSPF processes are totally separated and they do not share any data, they have different databases.
Two different OSPF processes will compete for installing prefixes in the IP routing table.
To be noted the IP routing table daemon is not able to make distinction about the different types of OSPF routes : each OSPF process presents a candidate prefix with the OSPF AD and a metric value as parameters the OSPF route type is not visible.
The process that presents the lowest metric is preferred regardless of the OSPF route type.
As already noted you don't need to use two different OSPF processes to have two different candidate OSPF default routes this can be done with a single OSPF process in most cases eventually using a route-map to change the route type and the seed metric based on the existence of a static default route and its associated IP next-hop.
router ospf 10
default-information originate route-map SELECT
access-list 11 permit host 10.10.10.2
access-list 12 permit host 10.20.20.2
ip prefix-list DEFAULT permit 0.0.0.0/0
route-map SELECT permit 10
match address prefix DEFAULT
match ip next-hop 11
set type 1
set metric 50
route-map SELECT permit 20
match address prefix DEFAULT
match ip next-hop 12
set type 1
set metric 500
Hope to help
Giuseppe
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide