[FROG] Why two duplicate route-map exist in bgpd and zebra ?
Simon Jones
batmanustc at gmail.com
Mon Apr 20 21:08:25 EDT 2020
Hi all,
I'm using quagga-0.99, I set a route-map by vtysh like this:
vtysh# prefix-list ARP2HOST_PL3 ...
> vtysh# route-map ARP2HOST_RM2 deny sequence 6
> vtysh# match interface lo
> vtysh# route-map ARP2HOST_RM2, permit, sequence 10
> vtysh# match ip address prefix-list ARP2HOST_PL3
But I found there are two SAME route-map exist in zebra and bgpd, like this:
vtysh# show route-map
> ZEBRA:
> route-map ARP2HOST_RM2, deny, sequence 6
> Match clauses:
> interface eth0
> Set clauses:
> Call clause:
> Action:
> Exit routemap
> route-map ARP2HOST_RM2, permit, sequence 10
> Match clauses:
> ip address prefix-list ARP2HOST_PL3
> Set clauses:
> Call clause:
> Action:
> Exit routemap
> BGP:
> route-map ARP2HOST_RM2, deny, sequence 6
> Match clauses:
> Set clauses:
> Call clause:
> Action:
> Exit routemap
> route-map ARP2HOST_RM2, permit, sequence 10
> Match clauses:
> ip address prefix-list ARP2HOST_PL3
> Set clauses:
> metric 13
> community 0:100
> Call clause:
> Action:
> Exit routemap
And when I use command
> vtysh# redistribute static route-map ARP2HOST_RM2
the redistribute will NOT process any static route SOMETIME, not always !!!
Then I compare by add route-map through zebra.conf and bgpd.conf, like
this:
> zebra.conf:
> route-map ARP2HOST_RM2 deny sequence 6
> match interface lo
>
> bgpd.conf:
> prefix-list ARP2HOST_PL3 ...
> route-map ARP2HOST_RM2, permit, sequence 10
> match ip address prefix-list ARP2HOST_PL3
And show route-map result beome:
> vtysh# show route-map
> ZEBRA:
> route-map ARP2HOST_RM2, deny, sequence 6
> Match clauses:
> interface eth0
> Set clauses:
> Call clause:
> Action:
> Exit routemap
> BGP:
> route-map ARP2HOST_RM2, permit, sequence 10
> Match clauses:
> ip address prefix-list ARP2HOST_PL3
> Set clauses:
> metric 13
> community 0:100
> Call clause:
> Action:
> Exit routemap
Then the redistribute will work.
focus on code, I guess ALL of zebra(zebra_routemap.c) and
bgpd(bgp_routemap.c) will process route-map from vtysh command, which cause
this bug?
If it is, how to set route-map correctly by vtysh?
Thanks !!!
----
Simon Jones
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.frrouting.org/pipermail/frog/attachments/20200421/0621905e/attachment.html>
More information about the frog
mailing list