cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1187
Views
0
Helpful
5
Replies

Where is a prefix-list applied?

Filip Knezevic
Level 1
Level 1

Hello all!

 

Any Jedi Master CLI tricks to quickly check where a route-map or a prefix-list is applied? It can be very confusing when you have a lot of BGP sessions and want to know where is a certain map applied.

Let's say I want to know if there are are route-maps affecting 193.XXX.XXX.0/24 prefix. Yes there are. But I don't see where.

 

Herkul#sh conf | i 193.XXX.XXX.0
ip prefix-list BLA seq 5 permit 193.XXX.XXX.0/24
ip prefix-list BLA-Hosting seq 5 permit 193.XXX.XXX.0/24

This is saying there are prefix lists BLA and BLA-Hosting. But where?

 

 

1 Accepted Solution

Accepted Solutions

Probably the best way is to copy the whole config in notepad, and just search for what you need :).

 

If there is no elegant way.

View solution in original post

5 Replies 5

Jon Marshall
Hall of Fame
Hall of Fame

 

If you just wanted to see all mentions of that prefix list - 

 

"sh run | include BLA"

 

if it was specifically for BGP - 

 

"sh run | include neighbor.*BLA

 

Jon

Hello John,

 

Thanks for the reply.

I know that.

If I do sh run | i BLA it will tell me there is ip prefix-list and the sequenece number. So how can I see which route-map this prefix list belongs?

 

In the example:

Herkul#sh conf | i 193.XXX.XXX.0
ip prefix-list BLA seq 5 permit 193.XXX.XXX.0/24
ip prefix-list BLA-Hosting seq 5 permit 193.XXX.XXX.0/24

 

I want to see which route-map ip prefix-list BLA is applied to. 

I want to see which route-map ip prefix-list BLA -Hosting is applied to. 

 

Hope this makes sense.

Hi

 

I guess that you already know but once you find the ACL matching your prefix :

- sh route-map (or more precise : sh route-map | i route-map|<acl_name>) : will print route map

- sh run | i <route-map_name> : will find the application point (interface, bgp peer...)

 

I don't think that there is another way.

 

Regards,

Yes, the thing is I dont know the route-map. :)

 

This is a core router with dozens od BGP sessions and hundreds of route-maps. I'm troubleshooting a customer. I know their BGP session and route-map applied to THAT session. But I want to see if on any of the upstream peerings I have any filters regarding this prefix. 

Really strange system with prefix lists/route-maps. I would expect more flexibility in troubleshooting. It can be difficult with huge configurations. Easy in GNS3 though :).

 

 

Probably the best way is to copy the whole config in notepad, and just search for what you need :).

 

If there is no elegant way.

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: