Here is what I want to do. I want to be able to redistribute all BGP routes into OSPF but give some routes a higher metric so that those routes will still route over OSPF unless there is an outage on the OSPF link. Then those routes will take the BGP path. I have several branch sites just on MPLS running BGP and several branch sites just on a layer 2 connection running OSPF.
I have hub sites that run both connections but right now those hub sites send everything over the OSPF link and if the traffic needs to go out over the MPLS cloud our Core site handle the traffic without going out the MPLS link we have also at the hub site. So I want to be able to list out the BGP networks at the hub sites so that instead of the traffic going to the Core it will route out the direct MPLS link. I see sites on MPLS come directly into the hub site over the MPLS link so I am sure we have async routing taking place.
Here's a previous post on this, that may help with your costing of particular routes during the redistribution:
This is close but all my sites are eEbgp and not Ibgp. I would assume that this would work also for Ebgp but is there a easier way? I have about 100 MPLS sites and if I create a access-list for all of those sites that would be a pretty long list since I would have to include all the networks at those sites.
IBGP, EBGP, makes no difference.
Perhaps a diagram and/or a snippet of a sanitized configuration might be prudent, so we can craft a more informed response?
I want to be able to redistribute all BGP routes into OSPF but give some routes a higher metric so that those routes will still route over OSPF unless there is an outage on the OSPF link...
A: 2 ways to do this: prefix-list>>>mapped to route-maps>>> with setting higher metrics for BGP routes
or: ACLs matching for all routes then PBR.
Can you post a diagram and generic conifg..that might give us better idea of what you want to do?