diff --git a/zebra/zebra_vrf.c b/zebra/zebra_vrf.c index 34db978ead33..b3ae1f337261 100644 --- a/zebra/zebra_vrf.c +++ b/zebra/zebra_vrf.c @@ -391,6 +391,11 @@ static void zebra_vrf_table_create(struct zebra_vrf *zvrf, afi_t afi, memset(&p, 0, sizeof(p)); p.family = afi2family(afi); + if (route_node_lookup_maynull(zvrf->table[afi][safi], &p)) + /* do not override the existing default route */ + return; + + /* create a fake default route */ rn = srcdest_rnode_get(zvrf->table[afi][safi], &p, NULL); zebra_rib_create_dest(rn); }