6.7. Show, Clear, and Debug Command Reference

6.7.1. Command Hierarchies

6.7.1.1. Show Commands

show
— router router-name
policy [name [expand-variables] | damping [name] | prefix-list [name] | as-path [name] | as-path-group [name] | community [name] | admin | exclusive-access]
policy name sub-policy entry entry-id [name subpol-name]
policy name sub-policy entry entry-id name subpol-name entry-2 entry-id name-2 subpol-name
policy name sub-policy entry entry-id name subpol-name entry-2 entry-id name-2 subpol-name entry-3 entry-id name-3 subpol-name
show
— router router-name
— bgp
policy-test plcy-or-long-expr [plcy-or-expr [plcy-or-expr .. (up to 14 max)]] [family family] [rd rd] [prefix ip-prefix/ip-prefix-length] [longer] [neighbor ip-address] [display-rejects] [{detail | brief}]

6.7.2. Command Descriptions

6.7.2.1. Show Commands

The command outputs in the following section are examples only; actual displays may differ depending on supported functionality and user configuration.

policy

Syntax 
policy [name [expand-variables] | damping [name] | prefix-list [name] | as-path [name] | as-path-group [name] | community [name] | admin | exclusive-access]
policy name sub-policy entry entry-id [name subpol-name]
policy name sub-policy entry entry-id name subpol-name entry-2 entry-id name-2 subpol-name
policy name sub-policy entry entry-id name subpol-name entry-2 entry-id name-2 subpol-name entry-3 entry-id name-3 subpol-name
Context 
show>router
Description 

This command displays configured policy statement information.

Parameters 
admin —
When this keyword is specified, the entire policy option configuration is displayed, including any uncommitted configuration changes. This command is similar to the info command.
as-path —
When this keyword is specified, the parameter displays configured as-path regular expressions (optionally filtered by name).
as-path-group —
When this keyword is specified, the command displays configured as-path-groups, optionally filtered by name.
community —
When this keyword is specified, the command displays configured community lists, optionally filtered by name.
damping —
When this keyword is specified, the information about the route policy damping configurations is displayed.
entry entry-id
Displays the configuration (with parameter value substitution) of the subroutine policy called by the entry with entry ID.
exclusive-access —
Displays the policy that edits exclusive access and lock information.
expand-variables —
Displays the variables that are replaced with values in main policies or in sub-policies.
prefix-list name
Displays the prefix lists configured in the route policy.
policy name
Displays information similar to the info command for a specific policy-statement. If a name is provided, the matching policy-statement displays. If no statement name is specified, a list of all policies statements and descriptions display.
sub-policy —
When this keyword is specified, the configuration of a subroutine policy is displayed.
subpol-name
Specifies the policy name up to 64 characters.
entry-id
Specifies the numeric entry identifier of the policy.
Values—
1 to 4294967295

 

Output 

Table 69 describes route policy output fields.

Table 69:  Route Policy Output Fields  

Label

Description

Policy

Displays a list of route policy names.

Description

Displays the description of each route policy.

Policies

The total number of policies configured.

The following route policy commands are displayed with different command parameter options:

  1. show router policy
  2. show router policy admin
  3. show router policy “BGP to RIP”
  4. show router policy damping
  5. show router policy “pol1” sub-pol entry 10 name “pol2”

The following output is an example of route policy information.

Sample Output

The show router policy command displays all configured route policies.

A:ALA-1# show router policy 
===============================================================================
Route Policies
===============================================================================
Policy                           Description                                    
-------------------------------------------------------------------------------
Direct And Aggregate             Policy Statement ABC
-------------------------------------------------------------------------------
Policies : 
===============================================================================
A:ALA-1# 

The show router policy admin command is similar to the info command which displays information about the route policies and parameters.

A:ALA-1# show router policy admin 
    prefix-list "All-Routes"
            prefix 0.0.0.0/0 longer
            prefix 2.0.0.0/8 longer
            prefix 3.0.0.0/8 longer
            prefix 4.0.0.0/8 longer
            prefix 5.0.0.0/8 longer
            prefix 6.0.0.0/8 exact
            prefix 224.0.0.0/24 longer
    exit
...
A:ALA-1#

The show router policy name command displays information about a specific route policy.

show router policy “BGP To RIP”

description "Policy Statement For 'BGP To RIP'"
    entry 10
        description "Entry For Policy 'BGP To RIP"
        from
            protocol bgp
        exit
        to
            protocol rip
        exit
        action accept
            metric set 1
            next-hop 10.0.18.200
            tag 805
        exit
    exit
    default-action reject
A:ALA-1#

The show router policy damping command displays information about the route policy damping configurations.

A:ALA-1# show router policy damping

=============================================
Route Damping Profiles
=============================================
    damping "TEST-LOW"
        half-life 22
        max-suppress 720
        reuse 10000
        suppress 15000
    exit
    damping "TEST-HIGH"
        half-life 22
        max-suppress 720
        reuse 1000
        suppress 5000
    exit
    damping "TEST-MEDIUM"
        half-life 22
        max-suppress 720
        reuse 5000
        suppress 11000
    exit
=============================================
A:ALA-1#

The show router policy name sub-policy entry entry-id name subpol-name command displays information about the subroutine called by an entry of the route policy. In the following sample output, the term “telnet” is the value of a variable.

show router policy “BGP To RIP”

*A:Dut-B#  show router policy "pol1" sub-policy entry 10 name "pol2"
===============================================================================
pol1 entry 10 sub-policies
===============================================================================
-------------------------------------------------------------------------------
Level1 Sub-policy : pol2    Parent-policy : pol1, Parent-entry 10
-------------------------------------------------------------------------------
    entry 20
        from
            community "telnet"
        exit
    exit
===============================================================================

policy-test

Syntax 
policy-test plcy-or-long-expr [plcy-or-expr [plcy-or-expr .. (up to 14 max)]] [family family] [rd rd] [prefix ip-prefix/ip-prefix-length] [longer] [neighbor ip-address] [display-rejects] [{detail | brief}]
Context 
show>router>bgp
Description 

This command allows an operator to evaluate an existing policy or chain or policies (possibly including a logical expression) against received BGP routes to identify the routes accepted or rejected by the full evaluation of the policy, policy chain, or logical expression.

Parameters 
plcy-or-long-expr—
Specifies the name of a policy, up to 64 characters or a policy logical expression up to 255 characters.
plcy-or-expr—
Specifies the name of a policy, up to 64 characters or a policy logical expression up to 64 characters.
family—
Specifies the BGP address family.
Values—
ipv4, ipv6, vpn-ipv4, vpn-ipv6, label-ipv4, label-ipv6

 

rd—
Specifies the route distinguisher value in one of the following formats:
  1. ip-addr:comm-val
  2. 2byte-asnumber:ext-comm-val
  3. 4byte-asnumber:comm-val
ip-prefix/ip-prefix-length—
Specifies the IPv4 or IPv6 prefix to be evaluated.
longer—
Matches prefixes with a longer prefix-length.
ip-address—
Specifies the neighbor IP address.
display-rejects—
Displays routes rejected by the policy test as opposed to routes that are accepted.
detail—
Displays detailed information.
brief—
Displays abridged information.