cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
474
Views
6
Helpful
7
Replies

router not installing lower admin distance route

tato386
Level 6
Level 6

I have a router that is running EIGRP and BGP and also redistributing both protocols into both processes.  There is a route that is received via external EIGRP with the default distance of 170 and this route is also received via BGP with admin distance 20.

When the router is restarted it seems to pickup the external EIGRP route first and installs it into the route table.  The BGP route with the lower admin distance is known but does not replace the 170 distance route until I do a "clear ip route" of the problem subnet.  

Similarly, if I temporarily disable the BGP peer the EIGRP external will be installed (as expected) but when I re-activate the BGP peer it does not replace the EIGRP route.

So it seems like the BGP route cannot dislodge the EIGRP route from the table without help from "clear ip route".  How can I troubleshoot this?

Thanks,

Diego  

1 Accepted Solution

Accepted Solutions

Hi,

well, in this case it's a little more complicated.

When you are redistributing the EIGRP prefix to BGP, it gets the weight attribute value 32768 by default. And when the same prefix is received by eBGP later on, it's having the weight attribute 0 assigned. So the original prefix (redistributed from EIGRP) wins within BGP process and is still the best from the BGP point of view. No matter it has a worse AD assigned.

So to make the eBGP prefix to win, you need to use a route-map when redistributing EIGRP to BGP.

Something like:

route-map E2B permit 10

set weight 0

set local-preference 50

!

router bgp ...

redistribute eigrp route-map E2B

!

!

This is just an example, you might need a more sophisticated route-map (matching some prefixes only, e.g.) depending on your network topology.

Am I clearer now?

Best regards,

Milan

View solution in original post

7 Replies 7

nspasov
Cisco Employee
Cisco Employee

Are you doing mutual redistribution between the two protocols?

Thank you for rating helpful posts!

Hi,

I guess even one direction EIGRP to BGP redistribution would explain this behaviour?

Playing with BGP attributes would help then (like to set the Weight of EIGRP redistributed prefixes to 0 and the Local Preference of the eBGP prefixes to 200 or something similar).

Best regrads,

Milan

I thought that admin distance is the "strongest" metric and would trump all others.  Where would I change this in the "eigrp/redistribute bgp" command?

Thanks,

Diego

Hi,

well, in this case it's a little more complicated.

When you are redistributing the EIGRP prefix to BGP, it gets the weight attribute value 32768 by default. And when the same prefix is received by eBGP later on, it's having the weight attribute 0 assigned. So the original prefix (redistributed from EIGRP) wins within BGP process and is still the best from the BGP point of view. No matter it has a worse AD assigned.

So to make the eBGP prefix to win, you need to use a route-map when redistributing EIGRP to BGP.

Something like:

route-map E2B permit 10

set weight 0

set local-preference 50

!

router bgp ...

redistribute eigrp route-map E2B

!

!

This is just an example, you might need a more sophisticated route-map (matching some prefixes only, e.g.) depending on your network topology.

Am I clearer now?

Best regards,

Milan

Yes, very clear indeed.  I will try that tonight during a maintenance window and let you know.

Thank you,

Diego

Your route-map is working perfectly.

Thank you very much.

Diego

yes, I am.

Review Cisco Networking for a $25 gift card