Guest

Cisco IOS Software Releases 12.2 SB

BGP Route-Map Policy List Support

Table Of Contents

BGP Route-Map Policy List Support

Contents

Prerequisites for Route-Map Policy List Support

Restrictions for Route-Map Policy List Support

Information About Route-Map Policy List Support

Policy Lists in a Route-Map Configuration

How Route-Map Policy Lists Work

How to Configure Route-Map Policy Lists

Creating a BGP Policy List

Policy Lists Simplify the Configuration of BGP Policy Routing

Prerequisites

Restrictions

Creating a BGP Policy List that Matches the AS-path and MED

Creating a BGP Policy List that Matches a Community Using Regular Expression Filtering

Creating a BGP Policy List That Filters External Routes

What to Do Next

Configuring a Route-Map to Reference a Policy List

Configuring Policy Lists in Route-Maps

Prerequisites

Configuring a Route-Map with AND Semantics

Configuring a Route-Map with OR

Verifying the Configuration of Policy Lists Within Route-Maps

Verifying With Show Commands

Configuration Examples for Route-Map Policy Lists

Configuring Policy List Examples

Configuring Route-Maps to Reference Policy Lists Examples

Verifying BGP Route-Map Policy List Support

Related Documents

Standards

MIBs

RFCs

Technical Assistance

Command Reference

match policy-list

show route-map


BGP Route-Map Policy List Support


The BGP Route-Map Policy List Support feature introduces new functionality to Border Gateway Protocol (BGP) route maps. This feature adds the capability for a network operator to group route map match clauses into named lists called policy lists. A policy list functions like a macro. When a policy list is referenced in a route map, all of the match clauses are evaluated and processed as if they had been configured directly in the route map. This enhancement simplifies the configuration of BGP routing policy in medium-size and large networks because a network operator can preconfigure policy lists with groups of match clauses and then reference these policy lists within different route maps. The network operator no longer needs to manually reconfigure each recurring group of match clauses that occur in multiple route map entries.

Feature History for the BGP Route-Map Policy List Support Feature

Release
Modification

12.0(22)S

This feature was introduced.

12.2(15)T

This feature was integrated into Cisco IOS Release 12.2(15)T.

12.2(18)S

This feature was integrated into Cisco IOS Release 12.2(18)S.

12.2(27)SBC

This feature was integrated into Cisco IOS Release 12.2(27)SBC.


Finding Support Information for Platforms and Cisco IOS Software Images

Use Cisco Feature Navigator to find information about platform support and Cisco IOS software image support. Access Cisco Feature Navigator at http://www.cisco.com/go/fn. You must have an account on Cisco.com. If you do not have an account or have forgotten your username or password, click Cancel at the login dialog box and follow the instructions that appear.

Contents

Prerequisites for Route-Map Policy List Support

Restrictions for Route-Map Policy List Support

Information About Route-Map Policy List Support

How to Configure Route-Map Policy Lists

Configuration Examples for Route-Map Policy Lists

Related Documents

Command Reference

Prerequisites for Route-Map Policy List Support

This document assumes that BGP is configured in your network and that neighbors have been established.

Restrictions for Route-Map Policy List Support

The following restrictions apply to the BGP Route-Map Policy List Support feature for this release:

IPv6 Not Supported

This feature does not support the configuration of IP version 6 (IPv6) match clauses in policy-lists.

Not Supported by Older Releases

Policy lists are not supported in versions of Cisco IOS Software prior to Cisco IOS Release 12.0(22)S and 12.2(15)T. Reloading a router that is running an older version of Cisco IOS software may cause some routing policy configurations to be lost.

Set Clauses Not Supported

Policy lists support only match clauses and do not support set clauses. However, policy lists can coexist, within the same route map entry, with match and set clauses that are configured separately from the policy lists.

Not Supported by General IP Policy Routing

Policy lists are supported only by BGP. They are not supported by other IP routing protocols. This limitation does not interfere with normal operations of a route map, including redistribution, because policy list functions operate transparently within BGP and are not visible to other IP routing protocols.

Information About Route-Map Policy List Support

To configure this feature, you must understand the following concepts:

Policy Lists in a Route-Map Configuration

How Route-Map Policy Lists Work

Policy Lists in a Route-Map Configuration

This feature introduces policy-list configuration mode and the ip policy-list command that is used to configure policy lists. A policy list is like a route map that contains only match clauses. The policy list is created and then referenced within a route map. There are no changes to match clause semantics and route map functions. Match clauses are configured in policy lists with permit and deny statements. The route map evaluates and processes each match clause and permits or denies routes based on the configuration. AND and OR semantics in the route map function the same way for policy-lists as they do for match and set clauses. This feature also introduces the match policy-list command to route-map configuration mode. The match policy-list command is used to reference a policy list within a route map for evaluation.

How Route-Map Policy Lists Work

A policy lists functions like a macro when it is configured in a route map and has the following capabilities and characteristics:

When a policy list is referenced within a route map, all the match statements within the policy list are evaluated and processed.

Two or more policy lists can be configured with a route map. Policy- lists can be configured within a route map to be evaluated with AND or OR semantics.

Policy lists can also coexist with any other preexisting match and set statements that are configured within the same route map but outside of the policy lists.

When multiple policy lists perform matching within a route map entry, all policy lists match on the incoming attribute only.

Policy lists support only match clauses and do not support set clauses. Policy lists can be configured for all applications of route maps, including redistribution, and can also coexist, within the same route map entry, with match and set clauses that are configured separately from the policy lists.


Note Policy lists are supported only by BGP and not supported by other IP routing protocols.


How to Configure Route-Map Policy Lists

This section contains the following procedures:

Creating a BGP Policy List

Configuring a Route-Map to Reference a Policy List

Verifying the Configuration of Policy Lists Within Route-Maps

Creating a BGP Policy List

To configure a route-map policy list, perform the steps in this section.

Policy Lists Simplify the Configuration of BGP Policy Routing

Policy lists simplify the configuration of BGP routing policy in medium-size and large networks. The network operator can reference preconfigured policy lists with groups of match clauses in route maps and easily apply general changes to BGP routing policy. The network operator no longer needs to manually reconfigure each recurring group of match clauses that occur in multiple route map entries.

Prerequisites

This document assumes that BGP is configured in your network and that neighbors have been established.

Restrictions

The following restrictions apply to the BGP Route-Map Policy List Support feature:

This feature does not support the configuration of IP version 6 (IPv6) match clauses in policy-lists.

Policy lists are not supported in versions of Cisco IOS Software prior to Cisco IOS Release 12.0(22)S and 12.2(15)T. Reloading a router that is running an older version of Cisco IOS software may cause some routing policy configurations to be lost.

Policy lists support only match clauses and do not support set clauses. However, policy lists can coexist, within the same route map entry, with match and set clauses that are configured separately from the policy lists.

Policy lists are supported only by BGP. They are not supported by other IP routing protocols. This limitation does not interfere with normal operations of a route map, including redistribution, because policy list functions operate transparently within BGP and are not visible to other IP routing protocols.

Creating a BGP Policy List that Matches the AS-path and MED

To create a BGP policy list that matches the autonomous system path and Multi Exit Discriminator (MED) of a router, use the following steps:

SUMMARY STEPS

1. enable

2. configure terminal

3. ip policy-list policy-list-name {permit | deny}

4. match as-path as-number

5. match metric metric

6. end

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

configure terminal

Example:

Router# configure terminal

Enters global configuration mode.

Step 3 

ip policy-list policy-list-name {permit | deny}

Example:

Router(config)# ip policy-list policy-list-name permit

Enters policy-list configuration mode and creates a BGP policy list that will permit routes that are allowed by the match clauses that follow.

Step 4 

match as-path as-number

Example:

Router(config-policy-list)# match as-path as-number

Creates a match clause to permit routes from the specified autonomous system path.

Step 5 

match metric metric

Example:

Router(config-policy-list)# match metric metric

Creates a match clause to permit routes with the specified metric.

Step 6 

end

Example:

Router(config-policy-list)# end

Exits policy-list configuration mode and enters privileged EXEC mode.

Creating a BGP Policy List that Matches a Community Using Regular Expression Filtering

To create a BGP policy list that matches the specified BGP community using a regular expression and the next hop of a router, use the following steps:

SUMMARY STEPS

1. enable

2. configure terminal

3. ip policy-list policy-list-name {permit | deny}

4. match community regular-expression

5. match ip next-hop ip-address

6. end

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

configure terminal

Example:

Router# configure terminal

Enters global configuration mode.

Step 3 

ip policy-list policy-list-name {permit | deny}

Example:

Router(config)# ip policy-list policy-list-name deny

Enters policy-list configuration mode and creates a BGP policy list that will deny routes that are matched by the match clauses that follow.

Step 4 

match community regular-expression

Example:

Router(config-policy-list)# match community regular-expression

Creates a match clause to permit routes that match the specified regular expression.

Step 5 

match ip next-hop ip-address

Example:

Router(config-policy-list)# match ip next-hop ip-address

Creates a match clause to permit routes with the specified next hop of a router.

Step 6 

end

Example:

Router(config-policy-list)# end

Exits policy-list configuration mode and enters privileged EXEC mode.

Creating a BGP Policy List That Filters External Routes

To create a BGP policy list to deny external routes and routes with the specified tag, use the following steps:

SUMMARY STEPS

1. enable

2. configure terminal

3. ip policy-list policy-list-name {permit | deny}

4. match route-type external

5. match tag tag-value

6. end

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

configure terminal

Example:

Router# configure terminal

Enters global configuration mode.

Step 3 

ip policy-list policy-list-name {permit | deny}

Example:

Router(config)# ip policy-list policy-list-name permit

Enters policy-list configuration mode and creates a BGP policy list that will permit routes that are allowed by the match clauses that follow.

Step 4 

match route-type external

Example:

Router(config-policy-list)# match route-type external

Configures the match clause to match only external routes.

Step 5 

match tag tag-value [... tag-value]

Example:

Router(config-policy-list)# match tag 257

Configures a match clause to permit routes that match the specified route tag.

Step 6 

end

Example:

Router(config-policy-list)# end

Exits policy-list configuration mode and enters privileged EXEC mode.

What to Do Next

The next step is to create a route-map to reference the policy lists. For more information, refer to the next section "Configuring a Route-Map to Reference a Policy List."

Configuring a Route-Map to Reference a Policy List

To configure a route-map to reference a policy list, perform the steps in this section.

Configuring Policy Lists in Route-Maps

Policy lists support only match clauses and do not support set clauses. However, policy lists can coexist, within the same route map entry, with match and set clauses that are configured separately from the policy lists. The first route-map example configures AND semantics, and the second route-map configuration example configures semantics. Both examples in this section show sample route map configurations that reference policy lists and separate match and set clauses in the same configuration.

Prerequisites

The steps in this section assume that policy lists have already been created.

Configuring a Route-Map with AND Semantics

SUMMARY STEPS

1. enable

2. configure terminal

3. route-map route-map-name [permit I deny] [sequence-number]

4. match ip-address access-list-number

5. match policy-list policy-list-name

6. set community {community-number [additive] | none}

7. set local-preference preference-value

8. end

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

configure terminal

Example:

Router# configure terminal

Enters global configuration mode.

Step 3 

route-map map-tag [permit | deny] [sequence-number]

Example:

Router(config)# route-map newroutemap permit 257

Enters route-map configuration mode and creates a route map.

Step 4 

match ip address {access-list-number | access-list-name} [... access-list-number | ... access-list-name]

Example:

Router(config-route-map)# match ip address 10

Creates a match clause to permit routes that match the specified access-list-number.

Step 5 

match policy-list policy-list-name

Example:

Router(config-route-map)# match policy-list newpolicy

Creates a clause that will match the specified policy list. All match clauses within the policy list will be evaluated and processed. Multiple policy lists can referenced with this command. This command also supports AND or OR semantics like a standard match clause.

Step 6 

set community {community-number [additive] | none}

Example:

Router(config-route-map)# set community 1

Creates a clause to set or remove the specified community.

Step 7 

set local-preference preference-value

Example:

Router(config-route-map)# set local-preference 2

Creates a clause to set the specified local preference value.

Step 8 

end

Example:

Router(config-route-map)# end

Exits route-map configuration mode and places the router in privileged EXEC mode.

Configuring a Route-Map with OR

SUMMARY STEPS

1. enable

2. configure terminal

3. route-map route-map-name [permit | deny] [sequence-number]

4. match policy-list policy-list-name

5. set community {community-number [additive] | none}

6. set local-preference preference-value

7. end

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

configure terminal

Example:

Router# configure terminal

Enters global configuration mode.

Step 3 

route-map map-tag [permit | deny] [sequence-number]

Example:

Router(config)# route-map newmap permit 2

Enters route-map configuration mode and creates a route map.

Step 4 

match policy-list policy-list-name

Example:

Router(config-route-map)# match policy-list newpolicy

Creates a clause that will match the specified policy list. All match clauses within the policy list will be evaluated and processed. Multiple policy lists can referenced with this command. This command also supports AND or OR semantics like a standard match clause.

Step 5 

set community [community-number [additive] | none]

Example:

Router(config-route-map)# set community 1

Creates a clause to set or remove the specified community.

Step 6 

set local-preference preference-value

Example:

Router(config-route-map)# set local-preference 2

Creates a clause to set the specified local preference value.

Step 7 

end

Example:

Router(config-route-map)# end

Exits route-map configuration mode and places the router in privileged EXEC mode.

Verifying the Configuration of Policy Lists Within Route-Maps

To verify the configuration of policy lists, and verify the configuration of route-map to reference a policy list, perform the steps in this section.

Verifying With Show Commands

The ouyput from both of the show commands in this section can be filtered to display information about a single policy-list or route-map by entering the name of a route-map or policy at the end of each show command.

SUMMARY STEPS

1. enable

2. show ip policy-list [policy-list-name]

3. show route-map [route-map-name]

DETAILED STEPS

 
Command or Action
Purpose

Step 1 

enable

Example:

Router> enable

Enables privileged EXEC mode.

Enter your password if prompted.

Step 2 

show ip policy-list [policy-list-name]

Example:

Router# show ip newlist

Display information about configured policy lists and policy list entries.

Step 3 

show route-map [route-map-name]

Example:

Router# show route-map

Displays locally configured route-maps and route map entries.

Configuration Examples for Route-Map Policy Lists

The following examples illustrate the configuration and verification of this feature:

Configuring Policy List Examples

Configuring Route-Maps to Reference Policy Lists Examples

Verifying BGP Route-Map Policy List Support

Configuring Policy List Examples

The following configuration example creates a BGP policy list that permits matches on the autonomous system path and MED of a router:

Router(config)# ip policy-list POLICY-LIST-NAME-1 permit 
Router(config-policy-list)# match as-path 1
Router(config-policy-list)# match metric 10
Router(config-policy-list)# end

The following configuration example creates a BGP policy list that permits matches on the specified BGP community and the next hop of a router:

Router(config)# ip policy-list POLICY-LIST-NAME-2 permit 
Router(config-policy-list)# match community 20
Router(config-policy-list)# match metric 10
Router(config-policy-list)# ip community-list 20 permit 20:1
Router(config-policy-list)# end

The following configuration example creates a BGP policy list that denies matches on the specified BGP community and the next hop of a router:

Router(config)# ip policy-list POLICY-LIST-NAME-3 deny 
Router(config-policy-list)# match community 20
Router(config-policy-list)# match metric 10
Router(config-policy-list)# end

Configuring Route-Maps to Reference Policy Lists Examples

The configuration examples in this section create BGP route maps that reference BGP policy lists with the route-map route-map configuration command.

The following configuration example creates a route map that references policy lists and separate match and set clauses in the same configuration. This example uses AND semantics between POLICY-LIST-NAME-1 and POLICY-LIST-NAME-2.

Router(config)# route-map MAP-NAME-1 10
Router(config-route-map)# match ip-address 1
Router(config-route-map)# match policy-list POLICY-LIST-NAME-1 
Router(config-route-map)# match policy-list POLICY-LIST-NAME-2 
Router(config-route-map)# set community 10:1
Router(config-route-map)# set local-preference 140
Router(config-route-map)# end

The following configuration example creates a route map that references policy lists and separate match and set clauses in the same configuration. This example uses OR semantics between POLICY-LIST-NAME-3 and POLICY-LIST-NAME-4.

Router(config)# route-map MAP-NAME-2 10
Router(config-route-map)# match policy-list POLICY-LIST-NAME-3 POLICY-LIST-NAME-4
Router(config-route-map)# set community 10:1
Router(config-route-map)# set local-preference 140
Router(config-route-map)# end

Verifying BGP Route-Map Policy List Support

To verify that a policy list has been created, use the show ip policy-list command. The output of this command will display the policy-list name and configured match clauses. The following sample output is similar to the output that will be displayed:

Router# show ip policy-list 
policy-list POLICY-LIST-NAME-1 permit
  Match clauses:
    metric 20 
policy-list POLICY-LIST-NAME-2 permit
  Match clauses:
    as-path (as-path filter): 1 

Note A policy list name can be specified when the show ip policy-list command is entered. This option can be useful for filtering the output of this command and verifying a single policy list.


To verify that a route map has been created and a policy list is referenced, use the show route-map command. The output of this command will display the route map name and policy lists that are referenced by the configured route maps. The following sample output is similar to the output that will be displayed:

Router# show route-map
route-map ROUTE-MAP-NAME-1, deny, sequence 10
  Match clauses:
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
route-map ROUTE-MAP-NAME-1, permit, sequence 10
  Match clauses:
    IP Policy lists:
        POLICY-LIST-NAME-1
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes

Related Documents

Related Topic
Document Title

BGP commands

Cisco IOS Release 12.0 Network Protocols Command Reference, Part 1

Cisco IOS IP Command Reference, Volume 2 of 3: Routing Protocols, Release 12.2

Cisco IOS IP Command Reference, Volume 2 of 4: Routing Protocols, Release 12.3

BGP configuration tasks

Cisco IOS Release 12.0 Network Protocols Configuration Guide, Part 1

Cisco IOS IP Configuration Guide, Release 12.2

Cisco IOS IP Configuration Guide, Release 12.3


Standards

Standards
Title

No new or modified standards are supported by this feature, and support for existing standards has not been modified by this feature.


MIBs

MIBs
MIBs Link

No new or modified MIBs are supported by this feature, and support for existing MIBs has not been modified by this feature.

To obtain lists of supported MIBs by platform and Cisco IOS release, and to download MIB modules, go to the Cisco MIB website on Cisco.com at the following URL:

http://www.cisco.com/public/sw-center/netmgmt/cmtk/mibs.shtml


RFCs

RFCs
Title

No new or modified RFCs are supported by this feature.


Technical Assistance

Description
Link

Technical Assistance Center (TAC) home page, containing 30,000 pages of searchable technical content, including links to products, technologies, solutions, technical tips, and tools. Registered Cisco.com users can log in from this page to access even more content.

TAC Home Page:

http://www.cisco.com/public/support/tac/home.shtml

BGP Support Page:

http://www.cisco.com/cgi-bin/Support/browse/psp_view.pl?p=Internetworking:BGP


Command Reference

This section documents new and modified commands. All other commands used with this feature are documented in the Cisco IOS command reference publications.

New Commands

show ip policy-list

Modified Commands

show route-map

match policy-list

To configure a route map to evaluate and process a Border Gateway Protocol (BGP) policy list in a route map, use the match policy-list command in route-map configuration mode. To remove a path list entry, use the no form of this command.

match policy-list policy-list-name

no match policy-list policy-list-name

Syntax Description

policy-list-name

Name of the policy list to evaluate and process within the route map.


Defaults

This command is not enabled by default.

Command Modes

Route-map configuration

Command History

Release
Modification

12.0(22)S

This command was introduced.

12.2(15)T

This command was integrated into 12.2(15)T.

12.2(27)SBC

This command was integrated into Cisco IOS Release 12.2(27)SBC.


Usage Guidelines

When a policy list is referenced within a route map, all the match statements within the policy list are evaluated and processed.

Two or more policy lists can be configured with a route map. Policy lists can be configured within a route map to be evaluated with AND semantics or OR semantics.

Policy lists can also coexist with any other preexisting match and set statements that are configured within the same route map but outside of the policy lists.

When multiple policy lists perform matching within a route map entry, all policy lists match on the incoming attribute only.

Examples

The following configuration example creates a route map that references policy lists and separate match and set clauses in the same configuration:

Router(config)# route-map MAP-NAME-1 10
Router(config-route-map)# match ip-address 1
Router(config-route-map)# match policy-list POLICY-LIST-NAME-1 
Router(config-route-map)# set community 10:1
Router(config-route-map)# set local-preference 140
Router(config-route-map)# end

The following configuration example creates a route map that references policy lists and separate match and set clauses in the same configuration. This example processes the policy lists named POLICY-LIST-NAME-2 and POLICY-LIST-NAME-3 with OR semantics. A match is required from only one of the policy lists.

Router(config)# route-map MAP-NAME-2 10
Router(config-route-map)# match policy-list POLICY-LIST-NAME-2 POLICY-LIST-NAME-3
Router(config-route-map)# set community 10:1
Router(config-route-map)# set local-preference 140
Router(config-route-map)# end

Related Commands

Command
Description

ip policy-list

Creates a BGP policy list.

match community

Matches a BGP community.

match interface (IP)

Distributes routes that have their next hop out one of the interfaces specified.

match ip address

Distributes any routes that have a destination network number address that is permitted by a standard or extended access list, and performs policy routing on packets.

match ip next-hop

Redistributes any routes that have a next hop router address passed by one of the access lists specified.

match ip route-source

Redistributes routes that have been advertised by routers and access servers at the address specified by the access lists.

match metric (IP)

Redistributes routes with the metric specified.

match as-path

References a policy list within a route map for evaluation and processing.

match route-type (IP)

Redistributes routes of the specified type.

match tag

Redistributes routes in the routing table that match the specified tags.

neighbor weight

Assigns weight to a neighbor connection.

route-map (IP)

Defines the conditions for redistributing routes from one routing protocol into another, or enables policy routing.


show route-map

To display static and dynamic route maps, use the show route-map command in privileged EXEC mode.

show route-map [map-name | dynamic [dynamic-map-name | application [application-name]] | all] [detailed]

Syntax Description

map-name

(Optional) Name of a specific route map.

dynamic

(Optional) Displays dynamic route map information.

dynamic-map-name

(Optional) Name of a specific dynamic route map.

application

(Optional) Displays dynamic route maps based on applications.

application-name

(Optional) Name of a specific application.

all

(Optional) Displays all static and dynamic route maps.

detailed

(Optional) Displays the details of the access control lists (ACLs) that have been used in the match clauses for dynamic route maps.


Command Modes

Privileged EXEC

Command History

Release
Modification

10.0

This command was introduced.

12.0(22)S

This command was integrated into Cisco IOS Release 12.0(22)S, and support for continue clauses was integrated into the command output.

12.2(15)T

An additional counter collect policy routing statistic was integrated into Cisco IOS Release 12.2(15)T.

12.3(2)T

Support for continue clauses was integrated into Cisco IOS Release 12.3(2)T.

12.2(18)S

This command was integrated into Cisco IOS Release 12.2(18)S.

12.3(7)T

The dynamic, application, and all keywords were added.

12.0(28)S

The support for recursive next-hop clause was added.

12.3(14)T

The support for recursive next-hop clause was integrated into Cisco IOS Release 12.3(14)T. Support for the map display extension functionality was added. The detailed keyword was added.

12.2(27)SBC

This command was integrated into Cisco IOS Release 12.2(27)SBC.


Usage Guidelines

For Cisco IOS Release 12.3(14)T and later 12.4 and 12.4T releases, you can display the ACL-specific information that pertains to the route map in the same display without having to execute a show route-map command to display each ACL that is associated with the route map.

Examples

The show route-map command will display configured route-maps, match, set, and continue clauses. The output will vary depending on which keywords are included with the command, and which software image is running in your router.

show route-map Command with No Keywords Specified Example

The following is sample output from the show route-map command:

Router# show route-map

route-map ROUTE-MAP-NAME, permit, sequence 10
  Match clauses:
    ip address (access-lists): 1 
    metric 10 
  Continue: sequence 40
  Set clauses:
    as-path prepend 10
  Policy routing matches: 0 packets, 0 bytes
route-map ROUTE-MAP-NAME, permit, sequence 20
  Match clauses:
    ip address (access-lists): 2 
    metric 20 
  Set clauses:
    as-path prepend 10 10
  Policy routing matches: 0 packets, 0 bytes
route-map ROUTE-MAP-NAME, permit, sequence 30
  Match clauses:
  Continue: to next entry 40
  Set clauses:
    as-path prepend 10 10 10
  Policy routing matches: 0 packets, 0 bytes
route-map ROUTE-MAP-NAME, deny, sequence 40
  Match clauses:
    community (community-list filter): 20:2 
  Set clauses:
    local-preference 100
  Policy routing matches: 0 packets, 0 bytes
route-map LOCAL-POLICY-MAP, permit, sequence 10
  Match clauses:
  Set clauses:
    community 655370
  Policy routing matches: 0 packets, 0 bytes

The following example shows Multiprotocol Label Switching (MPLS)-related route map information:

Router# show route-map

route-map OUT, permit, sequence 10
Match clauses:
  ip address (access-lists): 1 
Set clauses:
  mpls label
Policy routing matches: 0 packets, 0 bytes
       
route-map IN, permit, sequence 10
Match clauses:
  ip address (access-lists): 2 
  mpls label
Set clauses:
Policy routing matches: 0 packets, 0 bytes

Table 1 describes the significant fields shown in the display.

Table 1 show route-map Field Descriptions 

Field
Description

route-map ROUTE-MAP-NAME

Name of the route map.

permit

Indicates that the route is redistributed as controlled by the set actions.

sequence

Number that indicates the position a new route map is to have in the list of route maps already configured with the same name.

Match clauses:
  tag

Match criteria—conditions under which redistribution is allowed for the current route map.

Continue:

Continue clause—shows the configuration of a continue clause and the route-map entry sequence number that the continue clause will go to.

Set clauses:
  metric

Set actions—the particular redistribution actions to perform if the criteria enforced by the match commands are met.

Policy routing matches:

Number of packets and bytes that have been filtered by policy routing.


show route-map Command with Dynamic Route Map Specified Example

The following is sample output from the show route-map command when entered with the dynamic keyword:

Router# show route-map dynamic

route-map AAA-02/06/04-14:01:26.619-1-AppSpec, permit, sequence 0, identifier 1137954548
  Match clauses:
    ip address (access-lists): PBR#1 PBR#2 
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
route-map AAA-02/06/04-14:01:26.619-1-AppSpec, permit, sequence 1, identifier 1137956424
  Match clauses:
    ip address (access-lists): PBR#3 PBR#4 
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
route-map AAA-02/06/04-14:01:26.619-1-AppSpec, permit, sequence 2, identifier 1124436704
  Match clauses:
    ip address (access-lists): PBR#5 PBR#6 
    length 10 100
  Set clauses:
    ip next-hop 172.16.1.1
    ip gateway 172.16.1.1
  Policy routing matches: 0 packets, 0 bytes
Current active dynamic routemaps = 1

The following is sample output from the show route-map command when entered with the dynamic and application keywords:

Router# show route-map dynamic application

Application - AAA
  Number of active routemaps = 1

When you specify an application name, only dynamic routes for that application are shown. The following is sample output from the show route-map command when entered with the dynamic and application keywords and the AAA application name:

Router# show route-map dynamic application AAA

AAA
  Number of active rmaps = 2
AAA-02/06/04-14:01:26.619-1-AppSpec
AAA-02/06/04-14:34:09.735-2-AppSpec

Router# show route-map dynamic AAA-02/06/04-14:34:09.735-2-AppSpec

route-map AAA-02/06/04-14:34:09.735-2-AppSpec, permit, sequence 0, identifier 1128046100
  Match clauses:
    ip address (access-lists): PBR#7 PBR#8 
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
route-map AAA-02/06/04-14:34:09.735-2-AppSpec, permit, sequence 1, identifier 1141277624
  Match clauses:
    ip address (access-lists): PBR#9 PBR#10 
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
route-map AAA-02/06/04-14:34:09.735-2-AppSpec, permit, sequence 2, identifier 1141279420
  Match clauses:
    ip address (access-lists): PBR#11 PBR#12 
    length 10 100
  Set clauses:
    ip next-hop 172.16.1.12
    ip gateway 172.16.1.12
  Policy routing matches: 0 packets, 0 bytes
Current active dynamic routemaps = 2

show route-map Command with Detailed ACL Information for Route Maps Specified Example

The following is sample output from the show route-map command with the dynamic and detailed keywords entered:

Router# show route-map dynamic detailed

route-map AAA-01/20/04-22:03:10.799-1-AppSpec, permit, sequence 1, identifier 29675368 
Match clauses: 
ip address (access-lists): 
Extended IP access list PBR#3 
1 permit icmp 0.0.16.12 1.204.167.240 8.1.1.0 0.0.0.255 syn dscp af12 log-input fragments 
Extended IP access list PBR#4 
1 permit icmp 0.0.16.12 1.204.167.240 8.1.1.0 0.0.0.255 syn dscp af12 log-input fragments 
Set clauses: 
ip next-hop 172.16.1.14 
ip gateway 172.16.1.14 
Policy routing matches: 0 packets, 0 bytes 

Related Commands

Command
Description

redistribute (IP)

Redistributes routes from one routing domain into another routing domain.

route-map (IP)

Defines the conditions for redistributing routes from one routing protocol into another, or enables policy routing.