Question 'show ip bgp neig' and advertised routes

Answered Question
Mar 31st, 2010

I think I heard this before but I can't find the answer:
Imagine you have route-maps, prefix-lists etc filtering a given advertised BGP route.


Then you want to analyze how the advertised routes to a neighbor would look like without the effect of the aforementioned prefix-lists, route-maps, etc.

Is there any command to accomplish that?

To my understanding 'advertised-routes' should list the output of the actual advertised routes to a neighbor including filters (such as prefix-lists, route-maps).

R2#show ip bgp neig 10.2.2.47 ?

  advertised-routes  Display the routes advertised to a BGP neighbor

  dampened-routes    Display the dampened routes received from neighbor (eBGP

                     peers only)

  flap-statistics    Display flap statistics of the routes learned from

                     neighbor (eBGP peers only)

  paths              Display AS paths learned from neighbor

  received           Display information received from a BGP neighbor

  received-routes    Display the received routes from neighbor

  routes             Display routes learned from neighbor

  |                  Output modifiers

  <cr>

I have this problem too.
0 votes
Correct Answer by Giuseppe Larosa about 6 years 8 months ago

Hello Marlon,

>> Is there any command to accomplish that?

sh ip bgp

if no filter is applied all valid BGP routes not learned by that neighbor would be advertised to it

so if x.x.x.x is the neighbor

sh ip bgp | exclude x.x.x.x

should give you a good approximation of you would send to x.x.x.x without any filter applied: all the local RIB

well actually only >* best paths are sent out

soa regular expression would be needed

sh ip bgp | include  *>

Hope to help

Giuseppe

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Loading.
Correct Answer
Giuseppe Larosa Wed, 03/31/2010 - 15:24

Hello Marlon,

>> Is there any command to accomplish that?

sh ip bgp

if no filter is applied all valid BGP routes not learned by that neighbor would be advertised to it

so if x.x.x.x is the neighbor

sh ip bgp | exclude x.x.x.x

should give you a good approximation of you would send to x.x.x.x without any filter applied: all the local RIB

well actually only >* best paths are sent out

soa regular expression would be needed

sh ip bgp | include  *>

Hope to help

Giuseppe

Actions

This Discussion