[c-nsp] Redistributed EIGRP Route Preferred over EBGP?

Klaudiusz Staniek klstanie at cisco.com
Mon Apr 18 14:16:16 EDT 2011


Hi Cris,

When EIGRP is redistributed to BGP the Cost Community is added to the prefix - it's basically FD for EIGRP.

If router compares the prefix containing the Cost Community with the same prefix but without CC the default CC (which is 2^31+1 = 2147483649) is used. In that case your EIGRP learned route wins. 

I can bet that you have a route loop in your network right now and the EIGRP route is announced back to the originator through BGP. I think that because your CC is quite high.

You can check if the number of BGP table increases or if the hop count is increasing in eigrp topology for that prefix.

The solution is just to set Cost Community to any low value on import from BGP with route-map. This should be done for redistribution from any protocol to MP-BGP (incl. static and connected) with EIRGP on PE-CE
rotuer bgp <AS#>
 address-family ipv4 vrf <vrf>
 neighbor 192.168.2.2 route-map RM-SET-COST-COMM in

route-map RM-SET-COST_COMM permit 10
 set extcommunity cost pre-bestpath 1 100

Cheers,
klaus



On 2011-04-18, at 19:31, Chris Mason wrote:

> Hi,
> 
> I have a DMVPN setup running EIGRP between the HUB and SPOKES. The HUB
> is then running E-BGP back to the core.
> The HUB and SPOKES are all within the same EIGRP AS so the routes
> being learnt are internal EIGRP routes.
> 
> I have remote sites which have a primary and secondary router with
> EIGRP being used on the secondary router.
> The primary router will be advertising the same prefixes via BGP.
> 
> On the HUB, I am redistributing the EIGRP learnt routes into BGP.
> In the scenario below I am also learning the same prefix via BGP for
> the sites primary circuit.
> 
> Based on the following output I would expect the BGP learnt route to
> be preferred over the EIGRP redistributed route as I am setting a
> weight of 64000 on the BGP route.
> The EIGRP route will have a weight of 32768 because it is locally redistributed:
> 
> Router# show ip bgp vpnv4 vrf VPN-A 172.31.254.105/32
> BGP routing table entry for 65222:400:172.31.254.105/32, version 125981
> Paths: (2 available, best #2, table VPN-A)
>  Advertised to update-groups:
>        2    3    5    8
>  100 65000 65116
>    172.31.235.1 from 172.31.235.1 (172.16.0.33)
>      Origin incomplete, metric 0, localpref 100, weight 64000, valid, external
>      Extended Community: RT:65222:400
>      mpls labels in/out /nolabel
>  Local
>    172.31.238.166 from 0.0.0.0 (172.31.235.254)
>      Origin incomplete, metric 297372416, localpref 100, weight
> 32768, valid, sourced, best
>      Extended Community: RT:65222:400
>        Cost:pre-bestpath:128:297372416 (default-1850111231) 0x8800:32768:0
>        0x8801:44:12928000 0x8802:65281:284444416 0x8803:65362:1400
>      mpls labels in/out /nolabel
> 
> I can't work out why we are preferring the EIGRP path to the BGP path?
> Does anyone have any ideas or am I missing something obvious?
> 
> Thanks,
> Chris
> _______________________________________________
> cisco-nsp mailing list  cisco-nsp at puck.nether.net
> https://puck.nether.net/mailman/listinfo/cisco-nsp
> archive at http://puck.nether.net/pipermail/cisco-nsp/
> 


More information about the cisco-nsp mailing list