[quagga-dev 11665] Re: [PATCH V2] zebra: MBGP routes should not be installed in the kernel

Everton Marques everton.marques at gmail.com
Mon Oct 27 19:05:53 GMT 2014


Hi,

On Thu, Oct 23, 2014 at 2:25 PM, Balaji.G <balajig81 at gmail.com> wrote:

> MBGP routes are used only for PIM RPF checks and hence should
> not be installed in the kernel's FIB. Ignore route node set to Multicast
> SAFI.
>
> Signed-off-by: Balaji.G <balajig81 at gmail.com>
> ---
>  zebra/zebra_rib.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
> index dc7e1ca..3f393d9 100644
> --- a/zebra/zebra_rib.c
> +++ b/zebra/zebra_rib.c
> @@ -1249,6 +1249,7 @@ rib_process (struct route_node *rn)
>    struct nexthop *nexthop = NULL, *tnexthop;
>    int recursing;
>    char buf[INET6_ADDRSTRLEN];
> +  rib_table_info_t *info = rn->table->info;
>
>    assert (rn);
>
> @@ -1286,6 +1287,9 @@ rib_process (struct route_node *rn)
>        if (! nexthop_active_update (rn, rib, 0))
>          continue;
>
> +      if (info->safi == SAFI_MULTICAST)
> +       continue;
> +
>        /* Infinit distance. */
>        if (rib->distance == DISTANCE_INFINITY)
>          continue;
> --
> 1.9.1
>
>
This fix is really needed.
Only comment is the description could be more generic because it fixes MRIB
routes installed from other sources than MBGP as well.

Everton
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.quagga.net/pipermail/quagga-dev/attachments/20141027/4d1914bb/attachment-0001.html>


More information about the Quagga-dev mailing list