PREV NEXT INDEX

Avici Systems Inc.


show ip bgp regexp


Displays routes that match the regular expression.

Syntax: show ip bgp regexp "regular-expression" [ | { include | exclude | begin} routeExpression]

.

regular-expression

One regular expression with or without quotes or more than one regular expression within double-quotes to match BGP autonomous system paths.

routeExpression

A route expression to the right of the pipe and output modifier keyword combination

Description: Use the show ip bgp regexp command to display routes matching the specified regular expression. A regular expression can be further modified by using the optional output modifier ( | ), also refered to as a pipe, along with an output modifier keyword.

NOTE The output modifier symbol is the same as the logical OR ( | ) and should not be confused with it in this case.

Regular expressions used in BGP are listed in the table below:

Table 4-12. Regular Expressions Used in BGP
Term Description

values

A single or series of character sequences within double-quotes ( " ), e.g. "108" for a single character sequence or "108 110 120" for a series of charater sequences.

Ranges

A sequence of characters within square brackets [1-4] or [1234]

.

Matches any single character.

*

Matches 0 or more sequences of the pattern

^

Matches the beginning of an input string

$

Matches the end of an input string

\character

Matches the character.

_

Matches a comma, left brace, right brace, the beginning of an input string, the end of an input string, or a space

+

Matches 1 or more sequences of a character



Use the output modifier symbol ( | ) and a modifier option to further modify the search space.

Factory Default: None.

Command Mode: Executive and privileged.

Example: The following example shows output show ip bgp regexp command where the expression _116_ is used to match all instances of the string 116 where the route begins with 10:

router#show ip bgp regexp "_116_" | begin 10

Status codes: * - valid Origin codes: i - IGP d - damped e - EGP h - history ? - incomplete s - suppressed > - best a - aggregate i - internal Network Next Hop Metric LocPrf Weight Path *> 34.34.2.0/24 10.5.1.116 0 100 0 116 i *> 34.34.3.0/24 10.5.1.116 0 100 0 116 i *> 34.34.34.0/24 10.5.1.116 0 100 0 116 i

router#

The following table describes the fields in the display:

Table 4-13. Fields Displayed by show ip bgp regexp 
Field Description

Status codes

Status of the entry in the table. Valid values are:

  • * - Entry is valid.

  • d - Route is currently damped.

  • h - Route has earned some penalty points, but not enough points to exceed threshold. See bgp dampening.

  • > - Entry identifies the best route for that network.

  • i- Entry was learned from an IGP (IS-IS or OSPF) in the local autonomous system.

Network

IP address of a network.

Next Hop

IP address of the next system used when forwarding packets to the destination network. 0.0.0.0 in this field indicates the router has non-BGP routes to the network.

Metric

Inter-autonomous system metric.

LocPrf

Local preference value. See the set local-preference route map configuration command. Default value is 100.

Weight

Weight of the route as defined by set weight and router bgp route map configuration commands.

Path

Autonomous system path to the destination network. One entry in this field per autonomous system in the path.

Origin codes

Identifies the origin of the entry. Valid values are:

  • i - Entry originated from IGP. Entry was advertised by the network command.

  • e - Entry originated from EGP.

  • ? - Entry origin is not clear. Reachability information learned from some other source (usually indicates router is redistributed from IGP into BGP).

Related Commands: show ip bgp
show ip bgp neighbors
show ip bgp peer-group
show ip bgp summary


PREV NEXT INDEX

Copyright © 2004 Avici Systems Inc.
Avici® and TSR® is a registered trademark of Avici Systems Inc.
IPriori™, Composite Links™, SSR™, QSR, and NSR® are trademarks of Avici Systems Inc.

   Source File Name: BGP_Nd.fm
    HTML File Name: BGP_Nd58.html
    Last Updated: 05/10/04 at 16:36:55

Please email suggestions and comments to: doc@avici.com