Filter BGP route based on ospf_metric1 ?

Robert Sander r.sander at heinlein-support.de
Wed Mar 23 18:23:26 CET 2022


Hi,

Our routers speak OSPF and have a full mesh of BGP connections for our internal routes. This works quite well.

One router sees the other through OSPF:

80.241.60.8/32     via 10.25.19.251 on bond0.19 [ospf1 2022-03-17] * I (150/2474) [80.241.60.8]
         Type: OSPF unicast univ
         OSPF.metric1: 2474
         OSPF.metric2: 16777215
         OSPF.tag: 0x00000000
         OSPF.router_id: 80.241.60.8

The BGP session is established to 80.241.60.8 and e.g. this route is learned:

192.168.100.0/22   via 10.25.19.251 on bond0.19 [thor 2022-03-17 from 80.241.60.8] * (100/2474) [i]
         Type: BGP unicast univ
         BGP.origin: IGP
         BGP.as_path:
         BGP.next_hop: 80.241.60.8
         BGP.local_pref: 100

In the first line the ospf_metric1 is shown: (100/2474)
But when I try to filter on it (because I want to drop routes with a too high metric),
the route attribute ospf_metric1 is "(void)".

This seems to be because it's a BGP route and not an OSPF route.

Is it somehow possible to achieve this?

PS: This is with bird 1.6.8.

Kindest Regards
-- 
Robert Sander
Heinlein Consulting GmbH
Schwedter Str. 8/9b, 10119 Berlin

http://www.heinlein-support.de

Tel: 030 / 405051-43
Fax: 030 / 405051-19

Zwangsangaben lt. §35a GmbHG:
HRB 220009 B / Amtsgericht Berlin-Charlottenburg,
Geschäftsführer: Peer Heinlein -- Sitz: Berlin


More information about the Bird-users mailing list