02-29-2012 01:23 PM - edited 03-04-2019 03:29 PM
To All,
Below are some regular expressions that I understand:
ip as-path access-list 1 permit ^$ - permits only locally originated BGP routes
ip as-path access-list 1 permit .* - permit any
ip as-path access-list 1 permit _65535$ - permits networks that originated in 65535
There is a regular expression I do not understand which is being utilized on a network:
ip as-path access-list 1 permit 65535$
What does it mean when the underscore is not present before 65535$
Any responses are welcome.
Thank You,
Brian
Solved! Go to Solution.
02-29-2012 02:23 PM
It does the same thing as your _65535$ expression does. The AS-Path has to end with 65535 (actually originate from).
HTH,
John
02-29-2012 11:54 PM
Hi,
as John said, it's the same in your case.
But using another example:
5535$ matches also networks that originated in AS 65535
while
_5535$ does not match them.
HTH,
Milan
03-01-2012 03:39 AM
As a side note, if you want to test these without trying to decode the as-path access-list commands, you can run these at the cli as well:
sh ip bgp regexp 65535$
This will show you what it will match on before doing anything that would affect traffic.
02-29-2012 02:23 PM
It does the same thing as your _65535$ expression does. The AS-Path has to end with 65535 (actually originate from).
HTH,
John
02-29-2012 11:54 PM
Hi,
as John said, it's the same in your case.
But using another example:
5535$ matches also networks that originated in AS 65535
while
_5535$ does not match them.
HTH,
Milan
03-01-2012 03:39 AM
As a side note, if you want to test these without trying to decode the as-path access-list commands, you can run these at the cli as well:
sh ip bgp regexp 65535$
This will show you what it will match on before doing anything that would affect traffic.
03-01-2012 06:45 AM
Thanks everybody for the responses - they are much appreciated!
Brian
03-01-2012 07:04 AM
John,
Thanks for that command line for checking what it would match. 5+ for you...
Mike
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide