© 2006 Cisco Systems, Inc. All rights reserved. BSCI v3.06-1 Implementing BGP Using Route Maps to Manipulate Basic BGP Paths.

Презентация:



Advertisements
Похожие презентации
© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Implementing BGP Selecting a BGP Path.
Advertisements

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Module Summary BGP is a path-vector routing protocol that allows routing policy decisions.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v BGP Overview Understanding BGP Path Attributes.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v BGP Overview Processing BGP Routes.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Route Selection Using Attributes Setting BGP Local Preferences.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Customer-to-Provider Connectivity with BGP Connecting a Multihomed Customer to Multiple Service.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Route Selection Using Policy Controls Applying Route-Maps as BGP Filters.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v BGP Transit Autonomous Systems Configuring a Transit AS.
© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Implementing BGP Explaining EBGP and IBGP.
© 2006 Cisco Systems, Inc. All rights reserved. MPLS v MPLS VPN Implementation Configuring Small-Scale Routing Protocols Between PE and CE Routers.
© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Implementing BGP Explaining BGP Concepts and Terminology.
© 2006 Cisco Systems, Inc. All rights reserved.IP6FD v IPv6-Enabled Routing Protocols Understanding Multi-Protocol BGP (BGP4+)
© 2006 Cisco Systems, Inc. All rights reserved. MPLS v MPLS VPN Implementation Configuring an MP-BGP Session Between PE Routers.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Route Selection Using Policy Controls Using Multihomed BGP Networks.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Scaling Service Provider Networks Introducing Confederations.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v BGP Transit Autonomous Systems Working with a Transit AS.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Customer-to-Provider Connectivity with BGP Connecting a Multihomed Customer to a Single Service.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Route Selection Using Policy Controls Using Outbound Route Filtering.
© 2005 Cisco Systems, Inc. All rights reserved. BGP v Route Selection Using Attributes Using AS-Path Prepending.
© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Configuring EIGRP Configuring Advanced EIGRP Options.
Транксрипт:

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Implementing BGP Using Route Maps to Manipulate Basic BGP Paths

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v BGP is designed for manipulating routing paths. BGP Is Designed to Implement Policy Routing

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Changing BGP Local Preference For All Routes bgp default local-preference value Router(config-router)# This command changes the default local preference value. All routes advertised to an IBGP neighbor have the local preference set to the value specified. Local preference is used in these ways: Within an AS between IBGP speakers To determine the best path to exit the AS to reach an outside network Set to 100 by default; higher values preferred

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v What is the best path for router C to 65003, 65004, and 65005? Local Preference Case Study

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Router C BGP Table with Default Settings RouterC# show ip bgp BGP table version is 7, local router ID is Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale Origin codes: i - IGP, e - EGP, ? - incomplete Network Next Hop Metric LocPrf Weight Path * i i *>i i *>i i * i i *>i i * i i By default, BGP selects the shortest AS path as the best (>) path. In AS 65001, the percentage of traffic going to is 30%, is 20%, and is 10%. 50% of all traffic will go to the next hop of (AS 65005), and 10% of all traffic will go to the next hop of (AS 65002). Make traffic to select the next hop of to achieve load sharing where both external links get approximately 30% of the load.

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Route Map for Router A router bgp neighbor remote-as neighbor remote-as neighbor remote-as update-source loopback0 neighbor remote-as update-source loopback0 neighbor remote-as neighbor route-map local_pref in ! access-list 65 permit ! route-map local_pref permit 10 match ip address 65 set local-preference 400 ! route-map local_pref permit 20 Router A configuration

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Router C BGP Table with Local Preference Learned RouterC# show ip bgp BGP table version is 7, local router ID is Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale Origin codes: i - IGP, e - EGP, ? - incomplete Network Next Hop Metric LocPrf Weight Path * i i *>i i *>i i * i i * i i *>i i Best (>) paths for networks /16 and /16 have not changed. Best (>) path for network has changed to a new next hop of because the next hop of has a higher local preference, 400. In AS 65001, the percentage of traffic going to is 30%, is 20%, and is 10%. 30% of all traffic will go to the next hop of (AS 65005), and 30% of all traffic will go to the next hop of (AS 65002).

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Changing BGP MED for All Routes default-metric number Router(config-router)# MED is considered the metric of BGP. All routes that are advertised to an EBGP neighbor are set to the value specified using this command. MED is used when multiple paths exist between two autonomous systems. A lower MED value is preferred. The default setting for Cisco is MED = 0. The metric is an optional, nontransitive attribute. Usually, MED is shared only between two autonomous systems that have multiple EBGP connections with each other.

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v BGP Using Route Maps and the MED

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Route Map for Router A Router As Configuration: router bgp neighbor remote-as neighbor remote-as neighbor update-source loopback0 neighbor update-source loopback0 neighbor remote-as neighbor route-map med_65004 out ! access-list 66 permit access-list 66 permit ! route-map med_65004 permit 10 match ip address 66 set metric 100 ! route-map med_65004 permit 100 set metric 200

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Route Map for Router B Router Bs Configuration: router bgp neighbor remote-as neighbor remote-as neighbor update-source loopback0 neighbor update-source loopback0 neighbor remote-as neighbor route-map med_65004 out ! access-list 66 permit ! route-map med_65004 permit 10 match ip address 66 set metric 100 ! route-map med_65004 permit 100 set metric 200

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v MED Learned by Router Z RouterZ# show ip bgp BGP table version is 7, local router ID is Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale Origin codes: i - IGP, e - EGP, ? - incomplete Network Next Hop Metric LocPrf Weight Path *>i i * i i * i i *>i i * i i *>i i Examine the networks that have been learned from AS on Router Z in AS For all networks: Weight is equal (0); local preference is equal (100); routes are not originated in this AS; AS path is equal (65001); origin code is equal (i) has a lower metric (MED) through (100) than (200) has a lower metric (MED) through (100) than (200) has a lower metric (MED) through (100) than (200).

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v BGP in an Enterprise

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v Summary The BGP local preference attribute can be changed to manipulate the best-path decision process, either for all routes or for selected routes using route maps. –Higher local preference values are preferred. –Local preference is used only between IBGP speakers within the same AS. The MED values can be changed to manipulate packets returning to an AS, either for all routes or for selected routes, using route maps. –Lower MED values are preferred. –The MED is sent to EBGP neighbors; those routers propagate the MED within their AS. The routers within the AS use the MED but do not pass it on to the next AS. Routers in a typical enterprise BGP implementation multihome to two ISPs and pass default routes to other routers within the enterprise.

© 2006 Cisco Systems, Inc. All rights reserved. BSCI v