Alcatel-Lucent 6850 Switch User Manual


 
Configuring BGP Routing Policies
OmniSwitch 6800/6850/9000 Advanced Routing Configuration Guide December 2007 page 4-45
Routing Policies
BGP selects routes for subsequent advertisement by applying policies available in a pre-configured local
Policy Information database. This support of policy-based routing provides flexibility by applying poli-
cies based on the path (i.e. AS path list), community attributes (i.e. community lists), specific destinations
(i.e. prefix lists), etc.
You could also configure route maps to include all of the above in a single policy.
For BGP to do policy-based routing, each BGP peer needs to be tied to inbound and/or outbound policies
(direction based on whether routes are being learned or advertised). Each one of the above policies can be
assigned as an in-bound or out-bound policy for a peer.
First, you must create policies that match one of the specified criteria:
AS Paths. An AS path list notes all of the ASs the route travels to reach its destination.
Community List. Communities can affect route behavior based on the definition of the community.
Prefix List. Prefix list policies filter routes based on a specific network address, or a range of network
addresses.
Route Map. Route map policies filter routes by amalgamating other policies into one policy.
Then you must assign these policies to a peer. Policies can be assigned to affect routes learned from the
peer, routes being advertised to the peer, or both.
Creating a Policy
There are four different types of policies that can be created using the CLI, as described above. Each
policy has several steps that must be implemented for a complete policy to be constructed. Minimally, the
policy must be named, defined, and enabled.
The following sections describe the process of creating the four types of policies.
Creating an AS Path Policy
AS path policies must be assigned a name and a regular expression. Regular expressions are a set of
symbols and characters that represent an AS or part of an AS path. Regular expressions are fully described
in “Regular Expressions” on page 4-13.
To create an AS path policy:
1 Use the ip bgp policy aspath-list command, with a regular expression and a name, as shown:
-> ip bgp policy aspath-list aspathfilter “^100 200$”
This AS path policy is called aspathfilter. The policy looks for routes with an AS path with the next hop
AS 100, and originating from AS 200. Regular expressions must be enclosed by quotes.