Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 

How to achieve optimal routing and reduce BGP memory consumption

Core Issue

Optimal routing of network traffic and reducing memory consumption are essentially conflicting requirements. For optimal routing to take place, specific routes should be known. That involves learning all the specific prefixes, which requires a large amount of memory, especially in routers running Border Gateway Protocol (BGP). Using default routes and suppressing specific prefixes would result in reduced memory consumption, but it might also cause sub-optimal routing to take place.

Resolution

A high degree of optimal routing with a reduction in memory requirements can be achieved by accepting routes that only originated from the neighboring Autonomous System (AS). For further destinations, routing is based on default routes. Filtering updates to permit routes originating from the neighboring AS can be achieved only with the AS-Path Access Control List (ACL).

To resolve this issue, perform these steps:

  1. Create a regular expression that allows routes that originated from the neighboring AS and its directly connected AS only. For example, if the neighboring AS is 24357, the regular expression ^24357_[0-9]*$ matches routes originated in AS 24357 and its neighboring ASs.
  2. Create an AS-Path ACL with this regular expression. To define a BGP AS-Path ACL, issue the ip as-path access-list command in global configuration mode.
  3. Use this AS-Path ACL to filter routing updates by using filter lists or route maps.
  4. To create a route map, issue the route-map command in global configuration mode and the match as-path command in route-map configuration mode.
  5. To apply a route map to incoming or outgoing routes, issue the neighbor route-map command in router configuration mode.
  6. To set up a BGP filter, issue the neighbor filter-list command in router configuration mode.

For more information, refer to Achieve Optimal Routing and Reduce BGP Memory Consumption.

 

For more information on configuring BGP regular expressions, refer to Using Regular Expressions in BGP.

Version history
Revision #:
1 of 1
Last update:
‎06-22-2009 05:29 PM
Updated by:
 
Labels (1)
Everyone's tags (3)