6

Is it possible to perform the following configurations on Cisco routers, and are there any challenges with these types of configurations (mainly #3)?

  1. Match an OSPF route tag of 12000 (Definitely Possible)
  2. Redistribute OSPF into BGP (Definitely Possible)
  3. Set BGP AS Prepend towards a next-hop router (Challenge)

Network Diagram

Edit:

The DMVPN hub will be learning specific and summary routes from the DMVPN spoke via EIGRP 100 (DMVPN Tunnel 100). The DMVPN hub will redistribute these routes into OSPF, and tag them with a value of 12000. To prevent routing loops, or any abnormal routing behavior, I'm trying to prevent any routes with a tag of 12000 from being redistributed into the MPLS.

5
  • 2
    Yes, this is possible, but I think we need more specifics on what problem you're trying to solve. AS prepending for a given prefix is really only going to be useful if you're multihomed to two different upstreams - it doesn't really matter if you prepend with only a single upstream. Jun 27, 2015 at 18:49
  • The DMVPN hub will be learning specific and summary routes from the DMVPN spoke via EIGRP 100 (DMVPN Tunnel 100). The DMVPN hub will redistribute these routes into OSPF, and tag them with a value of 12000. To prevent routing loops, or any abnormal routing behavior, I'm trying to prevent any routes with a tag of 12000 from being redistributed into the MPLS.
    – Gregory R.
    Jun 27, 2015 at 22:23
  • is that ebgp or ibgp Jun 29, 2015 at 10:09
  • Ok. It is eBGP.
    – Gregory R.
    Jun 29, 2015 at 16:28
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can post and accept your own answer.
    – Ron Maupin
    Jan 5, 2021 at 2:09

2 Answers 2

1

Based on your comment:

I'm trying to prevent any routes with a tag of 12000 from being redistributed into the MPLS.

Any routes redistributed into OSPF from EIGRP will be OSPF external routes. It is easy to redistribute only internal routes from OSPF into BGP:

router bgp 100
 redistribute ospf 1
!

Alternatively, you can use a route map to match a tag and deny redistribution:

route-map FROM_OSPF deny 10
 match tag 12000
route-map FROM_OSPF permit 20
!
router bgp 100
 redistribute ospf 1 route-map FROM_OSPF
!

You can also use a route map to set the routes with the tag to the BGP community no-advertise and/or no-export:

route-map FROM_OSPF permit 10
 match tag 12000
 set community no-advertise  no-export
route-map FROM_OSPF permit 20
!
router bgp 100
 redistribute ospf 1 route-map FROM_OSPF
!

Route-Maps for IP Routing Protocol Redistribution Configuration:

enter image description here

enter image description here

0

What you are asking to do is impossible with BGP as there is no TAG support.

Are you trying to build an overlay network on top of your existing BGP environment? Our you terminating eBGP on the MPLS side of your DMVPN spoke? Are you advertising all networks on each side of your drawing? (All remote networks to DMVPN spoke and listed BGP router)

Without more information I don't really see any possibility of a routing loop. Your advertised routes on the BGP side will have a lower Administrative Distance and would be preferred by the other routers on the network by default.

I'll leave you with one last question. Why not handle this with the OSPF redistribution to the BGP router in question? You could easily create a prefix-list and route-map to block the networks of concern from being learned by the BGP router. If you need assistance with this let me know and I will update the post.

Best of luck.

Daniel

3
  • Daniel, eBGP is terminating on the MPLS side of the DMVPN spoke, and all networks on each side of the drawing will be advertised. The option of filtering within the OSPF area was discussed. However, a decision was made (not by myself) to not perform any filtering within the OSPF area because it's apparently not recommended. I'm still looking for documentation that supports why this is not recommended. If this is my only option, I'm willing to go forward with it. Many thanks for answering my question.
    – Gregory R.
    Jul 1, 2015 at 8:47
  • That sounds more like someones personal preference than it does any actual best practice. Let us know how it plays out.
    – Daniel
    Jul 1, 2015 at 15:26
  • 1
    @Daniel, you can use route maps with BGP redistribution which do recognize tags. Match on the tags, then deny routes, set communities, do AS prpending, etc., all based on the tags which BGP itself doesn't support.
    – Ron Maupin
    Mar 27, 2016 at 23:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.