02-25-2021 03:36 PM
Hello Community,
I'm working on the setup of a Cisco CSR. I have a route 10.0.0.0/24 learned by a BGP session on tunnel 200 and 201 (MPLS and failover), I also have a static route 10.0.0.0/29 (smaller than the previous one) to a tunnel 202.
I need to make the setup so when the MPLS is up the route goes through 200 or 201 but if it fails goes to 202, in case the MPLS is back up return to those tunnels.
I have done some basic tracking with SLA between two static routes /32 but I got lost when the two BGP tunnels come to play, and with the size difference between the BGP and the static routes, can somebody give me some light on this ?
Thanks !
02-25-2021 03:40 PM - edited 02-25-2021 03:41 PM
The more specific route is always going to be used.
It is not clear when you say the route should go via MPLS which route you are talking about, the /24 or the /29.
If the route received by BGP and your static route had the same prefix length then you could just add an AD higher than BGP (AD 20) to your static route and it should work as expected.
Jon
02-25-2021 03:51 PM
Hi Jon ! thanks for the response
The MPLS route is the /24, the /29 is the static route. Is there a way so I can give priority to the /24 ?
02-25-2021 04:00 PM
Not really no because in routing the longest match always wins.
The only way you could prioritise the /24 is to make sure the /29 is not in the IP routing table which is what you may be using IP SLA for ?
Can you not make the routes the same prefix length ?
Jon
02-25-2021 11:13 PM
Hello
it sounds like you could possibly incorporate policy based routing to route via a certain path based on a object tracking method -this way if reachability to the tracked object becomes unreachable the routing will take the alternate path
02-26-2021 12:25 AM
Hello,
in addition to the other posts, an EEM script that simply removes/adds the static routes based on either a syslog entry, or an IP SLA state track, could work as well. Can you post the running config of your CSR ?
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide