OSPF & merge external on

Mikhail Mayorov mm at tagan.ru
Sun Jun 26 22:36:43 CEST 2022


Hi!

Thanks for the clarifications. I understand. But I'm still trying to 
find a solution with ECMP on my network. And so far I can't find an 
elegant solution. I want to use OSPF and "merge external on" to form an 
IGP table in which the local interfaces of all routers were equivalent 
on links between cities (ECMP). To do this, I added static routes /32 
with BFD checks of local interfaces neighboring routers. Below I have 
given the output of OSPF state on the router 10.10.97.72.

I expected to get a mixed route on router 10.10.97.72 to the network 
10.10.97.33/32 through "router 10.10.97.33" and through "router 
10.10.97.73" since this subnet (10.10.97.33/32) is in LSA5 of both of 
these routers and the weight (distance) and OSPF.metric1/2 to these 
routers are the same. But it didn't happen. Something went wrong?! 
Although the route 10.10.8.0/21 worked and is available through all 6 links.

Why this LSA5 wasn't merge?

LSA5 router 10.10.97.73 (distance 2000): external 10.10.97.33/32 metric2 
10000 via 10.112.0.12
LSA5 router 10.10.97.33 (distance 2000): external 10.10.97.33/32 metric2 
10000

bird>show route for10.10.97.33/32alltable igpcoret4
Table igpcoret4:
10.10.97.33/32unicast [igpcore4 22:53:27]*E2 (150/2000/10000)[10.10.97.33]
via 10.112.0.1 on A2.1 weight 10
via 10.112.0.3 on A2.2 weight 10
via 10.112.0.5 on A3.1 weight 10
via 10.112.0.7 on A3.2 weight 10
Type:OSPF-E2 univ
OSPF.metric1:2000
OSPF.metric2:10000
OSPF.tag:0x00000000
OSPF.router_id:10.10.97.33
unicast [static4 22:53:12](140)
via 10.112.0.1 on A2.1 weight 1
via 10.112.0.3 on A2.2 weight 1
via 10.112.0.5 on A3.1 weight 1
via 10.112.0.7 on A3.2 weight 1
Type:static univ
bird>show route for10.10.8.0/21alltable igpcoret4
Table igpcoret4:
10.10.8.0/21unicast [igpcore4 22:53:27]*E2 (150/2000/10000)[10.10.97.73]
via 10.112.0.1 on A2.1 weight 10
via 10.112.0.3 on A2.2 weight 10
via 10.112.0.5 on A3.1 weight 10
via 10.112.0.7 on A3.2 weight 10
via 10.112.0.9 on A1.1 weight 10
via 10.112.0.11 on A1.2 weight 10
Type:OSPF-E2 univ
OSPF.metric1:2000
OSPF.metric2:10000
OSPF.tag:0x00000000
OSPF.router_id:10.10.97.73
bird>showospf state igpcore4
area 0.0.0.0
router 10.10.97.33
distance 2000
router 10.10.97.72metric 2000
router 10.10.97.72metric 2000
router 10.10.97.72metric 2000
router 10.10.97.72metric 2000
router 10.10.97.73metric 10
router 10.10.97.67metric 300
router 10.10.97.66metric 300
router 10.10.97.68metric 65535
stubnet 10.112.0.0/31metric 2000
stubnet 10.112.0.2/31metric 2000
stubnet 10.112.0.4/31metric 2000
stubnet 10.112.0.6/31metric 2000
stubnet 10.112.0.12/31metric 10
stubnet 10.112.0.14/31metric 300
stubnet 10.112.0.18/31metric 300
stubnet 10.112.0.22/31metric 65535
external 0.0.0.0/0metric2 10000
external 10.112.0.0/31metric2 10000
external 10.112.0.2/31metric2 10000
external 10.112.0.4/31metric2 10000
external 10.112.0.6/31metric2 10000
external 10.112.0.12/31metric2 10000
external 10.112.0.14/31metric2 10000
external 10.112.0.18/31metric2 10000
external 10.112.0.22/31metric2 10000
external 87.245.238.204/31metric2 10000
external 10.10.8.0/21metric2 10000
external 10.10.97.33/32metric2 10000
external 10.10.97.66/32metric2 10000via 10.112.0.19
external 10.10.97.67/32metric2 10000via 10.112.0.15
external 10.10.97.72/32metric2 10000via 10.112.0.0
external 10.10.97.73/32metric2 10000via 10.112.0.13
router 10.10.97.66
distance 2300
router 10.10.97.73metric 300
router 10.10.97.33metric 300
router 10.10.97.69metric 65535
router 10.10.97.67metric 10
stubnet 10.112.0.16/31metric 300
stubnet 10.112.0.18/31metric 300
stubnet 10.112.0.24/31metric 65535
stubnet 10.112.0.28/31metric 10
external 10.112.0.16/31metric2 10000
external 10.112.0.18/31metric2 10000
external 10.112.0.24/31metric2 10000
external 10.112.0.28/31metric2 10000
external 10.10.0.0/21metric2 10000
external 10.10.97.33/32metric2 10000via 10.112.0.18
external 10.10.97.66/32metric2 10000
external 10.10.97.67/32metric2 10000via 10.112.0.29
external 10.10.97.73/32metric2 10000via 10.112.0.16
router 10.10.97.67
distance 2300
router 10.10.97.33metric 300
router 10.10.97.66metric 10
router 10.10.97.69metric 65535
stubnet 10.112.0.14/31metric 300
stubnet 10.112.0.28/31metric 10
stubnet 10.112.0.26/31metric 65535
external 10.112.0.14/31metric2 10000
external 10.112.0.26/31metric2 10000
external 10.112.0.28/31metric2 10000
external 10.10.0.0/21metric2 10000
external 10.10.97.33/32metric2 10000via 10.112.0.14
external 10.10.97.66/32metric2 10000via 10.112.0.28
external 10.10.97.67/32metric2 10000
router 10.10.97.68
distance 67535
router 10.10.97.73metric 65535
router 10.10.97.33metric 65535
stubnet 10.112.0.20/31metric 65535
stubnet 10.112.0.22/31metric 65535
external 10.112.0.20/31metric2 10000
external 10.112.0.22/31metric2 10000
external 10.10.97.68/32metric2 10000
router 10.10.97.69
distance 67835
router 10.10.97.66metric 65535
router 10.10.97.67metric 65535
stubnet 10.112.0.24/31metric 65535
stubnet 10.112.0.26/31metric 65535
external 10.112.0.24/31metric2 10000
external 10.112.0.26/31metric2 10000
external 10.10.97.69/32metric2 10000
router 10.10.97.72
distance 0
router 10.10.97.33metric 2000
router 10.10.97.33metric 2000
router 10.10.97.33metric 2000
router 10.10.97.33metric 2000
router 10.10.97.73metric 2000
router 10.10.97.73metric 2000
stubnet 10.112.0.0/31metric 2000
stubnet 10.112.0.2/31metric 2000
stubnet 10.112.0.4/31metric 2000
stubnet 10.112.0.6/31metric 2000
stubnet 10.112.0.8/31metric 2000
stubnet 10.112.0.10/31metric 2000
external 10.112.0.0/31metric2 10000
external 10.112.0.2/31metric2 10000
external 10.112.0.4/31metric2 10000
external 10.112.0.6/31metric2 10000
external 10.112.0.8/31metric2 10000
external 10.112.0.10/31metric2 10000
external 10.10.97.72/32metric2 10000
external 100.105.99.0/30metric2 10000
router 10.10.97.73
distance 2000
router 10.10.97.72metric 2000
router 10.10.97.72metric 2000
router 10.10.97.33metric 10
router 10.10.97.66metric 300
router 10.10.97.68metric 65535
stubnet 10.112.0.8/31metric 2000
stubnet 10.112.0.10/31metric 2000
stubnet 10.112.0.12/31metric 10
stubnet 10.112.0.16/31metric 300
stubnet 10.112.0.20/31metric 65535
external 0.0.0.0/0metric2 10000
external 10.112.0.8/31metric2 10000
external 10.112.0.10/31metric2 10000
external 10.112.0.12/31metric2 10000
external 10.112.0.16/31metric2 10000
external 10.112.0.20/31metric2 10000
external 10.10.8.0/21metric2 10000
external 10.10.97.33/32metric2 10000via 10.112.0.12
external 10.10.97.66/32metric2 10000via 10.112.0.17
external 10.10.97.72/32metric2 10000via 10.112.0.8
external 10.10.97.73/32metric2 10000
external 188.170.160.52/30metric2 10000
On 26.06.2022 00:02, Ondrej Zajicek wrote:
> On Sat, Jun 25, 2022 at 10:00:14PM +0300, Mikhail Mayorov wrote:
>> Hello!
>>
>> I would like use ECMP for 0.0.0.0/0. This route announced on 10.10.97.33,
>> 10.10.97.72, 10.10.97.73 as LSA5. Below I have given the output of the
>> command on the router 10.10.97.67.
>> I expected to see a default route through 2 interfaces C3 to D1, but next
>> hops not merge.
>> Maybe I misunderstand the work "merge external on". I expected that the bird
>> would combine routes from different routers for the same destination
>> although OSPF.metric1 or OSPF.metric2.
> Hello
>
> Option "merge external" causes BIRD to combine external routes from
> different routers, but only those that have the same metric (ECMP =
> equal cost multipath).
>
> In your example 0.0.0.0/0 from 10.10.97.33 has metric1 300 / metric2 10000,
> while 0.0.0.0/0 from 10.10.97.73 has metric1 310 / metric2 10000.
>
> Therefore, the only the first is used, which has only one next hop
> (like the route to 10.10.97.33/32).
>
-- 

Regards,
Mikhail V. Majorov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://trubka.network.cz/pipermail/bird-users/attachments/20220626/d2178d90/attachment.htm>


More information about the Bird-users mailing list