[Contents] [Prev] [Next] [Index] [Report an Error]


show route aspath-regex

Syntax

show route aspath-regex "regular-expression ..."
<brief | detail | extensive | terse>
<logical-router (all | logical-router-name)>

Description

Display the entries in the routing table that match the specified BGP autonomous system (AS) path regular expression.

Options

regular-expression—Regular expression that matches an entire AS path.

brief | detail | extensive | terse—(Optional) Display the specified level of output.

logical-router (all | logical-router-name)—(Optional) Perform this operation on all logical routers or on a particular logical router.

Additional Information

You can specify a regular expression as:

You also can include the operators described in the table of AS path regular expression operators in the JUNOS Policy Framework Configuration Guide. The following list summarizes these operators:

When you specify more than one AS number or path term, or when you include an operator in the regular expression, enclose the entire regular expression in quotation marks. For example, to match any path that contains AS number 234, specify the following command:

show route aspath-regex ".* 234 .*"

Required Privilege Level

view

List of Sample Output

show route aspath-regex (matching a specific AS number)
show route aspath-regex (matching any path with two AS numbers)

Output Fields

routing-table-name—Name of the routing table (for example, inet.0).

destinations—Number of destinations for which there are routes in the routing table.

routes—Number of routes in the routing table:

prefix—Route address.

[protocol/preference]—Protocol from which the route was learned and the route's preference value.

+—A plus sign before [protocol/preference] indicates the active route, which is the route installed from the routing table into the forwarding table.

—A hyphen before [protocol/preference] indicates the last active route.

*—An asterisk before [protocol/preference] indicates that the route is both the active and the last active route. An asterisk before a to line indicates the best subpath to the route.

time—How long the route has been known.

localpref—Local preference value included in the route.

from—Address and interface from which route was learned.

AS Path—AS path included in the route.

[ ]—Brackets enclose the local AS number associated with the AS path if more than one AS number is configured on the router, or if AS path prepend is configured.

{ }—Braces enclose AS sets, which are groups of AS numbers in which the order does not matter. A set commonly results from route aggregation. The numbers in each AS set are displayed in ascending order.

( )—Parentheses enclose a confederation.

( [ ] )—Parentheses and brackets enclose a confederation set.

show route aspath-regex (matching a specific AS number)

user@host> show route aspath-regex 65477
inet.0: 46411 destinations, 46411 routes (46409 active, 0 holddown, 2 hidden)
+ = Active Route, - = Last Active, * = Both
 
111.222.1.0/25     *[BGP/170] 00:08:48, localpref 100, from 111.222.2.24
                   AS Path: [65477] ({65488 65535}) IGP
                     to 111.222.18.225 via fpa0.0(111.222.18.233)
111.222.1.128/25   *[IS-IS/15] 09:15:37, metric 37, tag 1
                     to 111.222.18.225 via fpa0.0(111.222.18.233)
                    [BGP/170] 00:08:48, localpref 100, from 111.222.2.24
                   AS Path: [65477] ({65488 65535}) IGP
                     to 111.222.18.225 via fpa0.0(111.222.18.233)
...

show route aspath-regex (matching any path with two AS numbers)

user@host> show route aspath-regex ".* 234 3561 .*"
 
inet.0: 46351 destinations, 46351 routes (46349 active, 0 holddown, 2 hidden)
+ = Active Route, - = Last Active, * = Both
 
9.20.0.0/17        *[BGP/170] 01:35:00, localpref 100, from 131.103.20.49
                   AS Path: [666] 234 3561 2685 2686 Incomplete
                     to 192.156.169.1 via 192.156.169.14(so-0/0/0)
12.10.231.0/24     *[BGP/170] 01:35:00, localpref 100, from 131.103.20.49
                   AS Path: [666] 234 3561 5696 7369 IGP
                     to 192.156.169.1 via 192.156.169.14(so-0/0/0)
24.64.32.0/19      *[BGP/170] 01:34:59, localpref 100, from 131.103.20.49
                   AS Path: [666] 234 3561 6327 IGP
                     to 192.156.169.1 via 192.156.169.14(so-0/0/0)
...

[Contents] [Prev] [Next] [Index] [Report an Error]