cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4547
Views
10
Helpful
9
Replies

BGP route-map and prefix-list for redistribute (connected/static) in IPv4

johnelliot6
Explorer
Explorer

Hi,

 

Have an unusual problem with prefix redistribution using route-map and PL

 

The supernet prefix for some reason is not being tagged with communities, and so, isnt being redistributed to our RR's - Smaller prefixes within the supernet are being tagged correctly (And redist. to our RRs)

 

The PL in question is this:

 

ip prefix-list PL_GvvvvvM_RANGES seq 5 permit 2xx.xxx.xx.0/20 le 32

 

route-map is:

 

route-map GccccM_RANGES permit 10
match ip address prefix-list PL_GvvvvvM_RANGES
set community xxx:xxx xxx:xxx xxx:xxx

 

And redist statemements under IPv4:

redistribute connected route-map GccccM_RANGES
redistribute static route-map GccccM_RANGES

 

All static routes to next-hops appear to work (Smaller profixes, Im unable to try the supernet as there are active routes contained in the supernet, and also asdsigned to Interfaces)

static route to Null0 for the supernet, I get no community tags (Route is visible in BGP though as soon as it is null routed...just no communities)

Ive tried adding a larger prefix in the PL (/19 with le 32) - I matches the prefixes, but again, the supernet doesnt get tagges, but smaller prefixes do.

 

I thought it may have something to do with the supernet being null routed, but I tried null routing a /23 within the supernet, and it was successfully matched, and community tages applied,

 

A little stumped as to what is causing this - Thanks

9 Replies 9

Georg Pauwen
VIP Master VIP Master
VIP Master

Hello, 

weird indeed. I labbed this in GNS3 and community tags worked for supernet. Can you post the full configs of both routers ?

Configs are very large on these routers - I can potentially post a subset of the conf if that would help?

 

Maybe the bgp sections, the route-maps/PLs/CLs and null routes?

 

Thanks

paul driver
VIP Expert VIP Expert
VIP Expert

Hello

is your PL correct to what you wish to be advertised?
ip prefix-list PL_GvvvvvM_RANGES seq 5 permit 2xx.xxx.xx.0/20 le 32  <-- which is saying this PL networks that are of 2xx.xxx.xx.0/20 and greater

 

have you tried
ip prefix-list PL_GvvvvvM_RANGES seq 5 permit 0.0.0.0/0 ge 19 le 32

 

res

Paul


Please rate and mark as an accepted solution if you have found any of the information provided useful.
This then could assist others on these forums to find a valuable answer and broadens the community’s global network.

Kind Regards
Paul

Hi - Thanks for the reply, to answer your questions:

 

s your PL correct to what you wish to be advertised?
ip prefix-list PL_GvvvvvM_RANGES seq 5 permit 2xx.xxx.xx.0/20 le 32  <-- which is saying this PL networks that are of 2xx.xxx.xx.0/20 and greater

 

The above should match 2xx.xxx.xx.0/20 and all prefixes contained within that /20 that are legth of /32 or less?  

 

And:

have you tried
ip prefix-list PL_GvvvvvM_RANGES seq 5 permit 0.0.0.0/0 ge 19 le 32

 

Yes - Have not tried that one(I will shortly), but I did try 2xxx.xxx.xxx.0/19 le 32 - It matched /30s,/29's,/28s ettc and /24's in the supernet.....but still no community on the supernet

 

I also tried matching the /20 explicityly - 2xxx.xxx.xxx.0/20 - It matched the /20 (Well the PL got a hit, and the /20 was in BGP.....just no community tags.

 

Thanks

Hello,

actually I think you have already posted the relevant parts...

Maybe you can post the static route for the supernet ?

It (obviously) should have 255.255.240.0 mask (20)

The only reason it is not tagged can really be that it is not matched in the prefix list...

Just to be sure, and to check for bugs, what IOS version are you running ?

 

Ji,

 

Sure - No problems.

 

ip route 2cc.ccc.ccc.cc0 255.255.240.0 Null0

I also have (Amongst oter /24's) Null routes for some of the /24s in the supernet
ip route 2cc.ccc.vvv.0 255.255.255.0 Null0

 

The /24 gets community tags, but the /20 does not....for some reason.....Ill check bugs and see if I can find anything - Cheers.

What happens if you remove::

redistribute connected route-map GccccM_RANGES

so that you are just left with redistributing the static routes ?

Unfortunately Id need to do that under maintenance window - it would bring down a lot of customers

 

Cheers

Just a guess,

 

isn't there also an aggregate-address configured for your /20?

 

HTH,

Milan

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: