When setting preference value of zero on a static route, then this gets shown as preference 200 when doing show route. Preference on static routes is based on a patch from Ondrej with SHA 7a49e97e7ec86bd336dc801411cb8b8f92f38388, but it looks as this has still not made into master. kenth ~ # cat /opt/appl/executing/etc/bird_route.conf protocol static static1 { ipv4 {import all;}; check link 1; route 0.0.0.0/0 via 10.210.137.1 {preference=0;}; } bird> show route Table master4: 0.0.0.0/0 unicast [static1 12:27:07.093] (200) via 10.210.137.1 on eth1 Setting preference to a value >= 1 makes this work correct. /k
On Tue, Jan 14, 2020 at 11:53:10AM +0000, Kenth Eriksson wrote:
When setting preference value of zero on a static route, then this gets shown as preference 200 when doing show route. Preference on static routes is based on a patch from Ondrej with SHA 7a49e97e7ec86bd336dc801411cb8b8f92f38388, but it looks as this has still not made into master.
kenth ~ # cat /opt/appl/executing/etc/bird_route.conf protocol static static1 { ipv4 {import all;}; check link 1; route 0.0.0.0/0 via 10.210.137.1 {preference=0;}; }
bird> show route Table master4: 0.0.0.0/0 unicast [static1 12:27:07.093] (200) via 10.210.137.1 on eth1
Setting preference to a value >= 1 makes this work correct.
Hi Preference value 0 is undefined in BIRD. It does not work even if set using 'preference' keyword for whole protocol. Although it probably should generate some warning/error. Also, i do not remember which patch exactly i sent you, but i think that proper syntax for multiple routes with different preference was 'preference X;', not 'preference=X;'. The second one is just generic per-route filter code. We planned to do some deeper review of static protocol code that improves several issues including handling of multiple routes, so we did not merged this small patches, but we did not managed that yet. -- Elen sila lumenn' omentielvo Ondrej 'Santiago' Zajicek (email: santiago@crfreenet.org) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) "To err is human -- to blame it on a computer is even more so."
On Tue, 2020-01-14 at 16:39 +0100, Ondrej Zajicek wrote:
Preference value 0 is undefined in BIRD. It does not work even if set using 'preference' keyword for whole protocol. Although it probably should generate some warning/error.
Ok I see. Unfortunately that makes it deviate even more from Cisco/Juniper administrative distance that can range from 0-255.
Also, i do not remember which patch exactly i sent you, but i think that proper syntax for multiple routes with different preference was 'preference X;', not 'preference=X;'. The second one is just generic per-route filter code.
I posted your patch on the list in May 2019; https://bird.network.cz/pipermail/bird-users/2019-May/013355.html It did not compile so I fixed that in patch 2; https://bird.network.cz/pipermail/bird-users/2019-May/013356.html And then aligned the preference syntax in patch 3; https://bird.network.cz/pipermail/bird-users/2019-May/013357.html
We planned to do some deeper review of static protocol code that improves several issues including handling of multiple routes, so we did not merged this small patches, but we did not managed that yet.
Great, hope to see that in a release really soon :)
participants (2)
-
Kenth Eriksson -
Ondrej Zajicek