[j-nsp] MX series BGP config macros ?

John Brown john at citylinkfiber.com
Sat Nov 5 16:24:01 EDT 2016


Hi,

I'm trying to build a BGP policy config that will advertise routes based on how
a subscriber tags a route towards us.

If they send a route with community 65010:XXX  with XXX = an ASN
then we will not announce it towards that ASN.

In a small configuration this is pretty easy to do, but I'm looking at
trying to
see if there is a more elegant and scaleable solution.

With hundreds of peers on a router, it doesn't make sense to have a bunch of
community members for each ASN

It would be nice to have code that did


protocol bgp
group  eBGP-Some-Peer
peer-as 1234
export [Dont-Export]


policy-statement  Dont-Export
term
    from
         protocol bgp
         community 65010:$PEERASN
    then
         reject



Where $PEERASN gets expanded to 1234 because of the BGP session
it is associated with.

Then I can just apply Dont-Export to multiple peers and not have to customize
it for each one



Hopefully this explains it well enough.

Thank you


More information about the juniper-nsp mailing list