[c-nsp] Communities on local prefixes
Andy BIERLAIR
andy.bierlair at root.lu
Wed Mar 18 03:16:33 EDT 2009
Hi,
I would like to set a BGP community tag on local (non-customer) prefixes
before I send them to my peers and customers.
Right now I am doing this with a route-map when I configure the neighbor.
Somewhat like this:
router bgp 65001
...
neighbor 1.2.3.4 route-map TEST-OUT out
...
network x.x.0.0 mask 255.255.0.0
...
route-map TEST-OUT permit 20
match ip address prefix-list local-out
set community 65001:9999
ip prefix-list local-out seq 5 permit x.x.0.0/16
ip prefix-list local-out seq 10 deny 0.0.0.0/0 le 32
This would tag my local prefixes with 65001:9999
While this is working, I don't find it to be the optimal solution. I want to
avoid setting communities on an outgoing route-map and I would like to have
my local prefixes tagged before they reach the "TEST-OUT" route-map.
In other words, when I do: sh ip bgp x.x.0.0 on the local router, I would
like to see this:
Local
0.0.0.0 from 0.0.0.0
Origin IGP, metric 0, localpref 100, weight 32768, valid, sourced,
local, best
Community: 65001:9999 <========
Is there a way to do so?
Thank you.
-
Andy
More information about the cisco-nsp
mailing list