bgp route-map

BGP route maps are used to control and modify routing information. A BGP route map is a collection of deny and/or permit route rules that define and control redistribution of routes between routers and routing processes. Each rule consists of match criteria and set lines. If a route matches a criteria, the corresponding set line is applied, and the route is passed to the BGP table or to the neighbor, depending on whether the route map is set for incoming or outgoing route updates.

Use the (config) instance to configure BGP route map related parameters.

To navigate to this instance, use the following command:
<DEVICE>(config)#route-map <ROUTE-MAP-NAME>
<DEVICE>(config)#route-map test
<DEVICE>(config-dr-route-map-test)#?
Route Map Mode commands:
  deny     Add a deny route map rule to deny set operations
  no       Negate a command or set its defaults
  permit   Add a permit route map rule to permit set operations

  clrscr   Clears the display screen
  commit   Commit all changes made in this session
  do       Run commands from Exec mode
  end      End current mode and change to EXEC mode
  exit     End current mode and down to previous mode
  help     Description of the interactive help system
  revert   Revert changes
  service  Service Commands
  show     Show running system information
  write    Write running configuration to memory or terminal

<DEVICE>(config-dr-route-map-test)#
In the route-map configuration mode, use the following commands to create and configure a deny or permit route map rule:
<DEVICE>(config-dr-route-map-test)#deny route-map <1-65535>
<DEVICE>(config-dr-route-map-test)#permit route-map <1-65535>
For example:
<DEVICE>(config-dr-route-map-test)#permit route-map 1
<DEVICE>(config-dr-route-map-test)#deny route-map 2
<DEVICE>(config-dr-route-map-test)#show context
route-map test
 permit route-map 1
 deny route-map 2
<DEVICE>(config-dr-route-map-test)#
<DEVICE>(config-dr-route-map-test-dr-route-map-rule-1)#?
Route Map Rule Mode commands:
  description  Configure comment for this route map
  match        Match values from routing table
  no           Negate a command or set its defaults
  set          Set values in destination routing protocol

  clrscr       Clears the display screen
  commit       Commit all changes made in this session
  do           Run commands from Exec mode
  end          End current mode and change to EXEC mode
  exit         End current mode and down to previous mode
  help         Description of the interactive help system
  revert       Revert changes
  service      Service Commands
  show         Show running system information
  write        Write running configuration to memory or terminal

<DEVICE>(config-dr-route-map-test-dr-route-map-rule-1)#
The following table summarizes BGP Route Map deny/permit route map rules configuration mode commands:
Click to expand in new window

BGP-Route-Map Config Mode Commands

Command Description
description (bgp-route-map) Configures a description for this route-map rule (deny or permit) that uniquely distinguishes it from others with similar access permissions
match (bgp-route-map) Configures the match criteria associated with this deny or permit BGP route map
set (bgp-route-map) Configures the values attributed to a route matching the match criteria specified in the BGP deny or permit route-map rules
no (bgp-route-map) Removes or reverts the settings defined for a deny or permit route-map rule