![](/user_photo/1438_p9ksI.png)
- •Table of Contents
- •About the Technical Reviewers
- •Acknowledgments
- •Introduction
- •Objectives
- •Audience
- •Organization
- •Approach
- •Features and Text Conventions
- •Command Syntax Conventions
- •Icons Used in This Book
- •Origins and Recent History of the Internet
- •Network Access Points
- •Routing Arbiter Project
- •The Very High-Speed Backbone Network Service
- •Transitioning the Regional Networks from the NSFNET
- •NSF Solicits NIS Managers
- •Other Internet Registries
- •Internet Routing Registries
- •The Once and Future Internet
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •ISP Services
- •Looking Ahead
- •Frequently Asked Questions
- •History of Internet Addressing
- •IP Address Space Depletion
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •Overview of Routers and Routing
- •Routing Protocol Concepts
- •Segregating the World into Autonomous Systems
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •How BGP Works
- •BGP Capabilities Negotiation
- •Multiprotocol Extensions for BGP
- •TCP MD5 Signature Option
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •Building Peer Sessions
- •Sources of Routing Updates
- •Overlapping Protocols: Backdoors
- •The Routing Process Simplified
- •Controlling BGP Routes
- •Route Filtering and Attribute Manipulation
- •BGP-4 Aggregation
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •Redundancy
- •Symmetry
- •Load Balancing
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •Interaction of Non-BGP Routers with BGP Routers
- •BGP Policies Conflicting with Internal Defaults
- •Policy Routing
- •Looking Ahead
- •Frequently Asked Questions
- •Route Reflectors
- •Confederations
- •Controlling IGP Expansion
- •Looking Ahead
- •Frequently Asked Questions
- •References
- •Route Instabilities on the Internet
- •BGP Stability Features
- •Looking Ahead
- •Frequently Asked Questions
- •Building Peering Sessions
- •Route Filtering and Attribute Manipulation
- •Peer Groups
- •Sources of Routing Updates
- •Overlapping Protocols: Backdoors
- •BGP Attributes
- •BGP-4 Aggregation
- •Looking Ahead
- •Redundancy, Symmetry, and Load Balancing
- •Following Defaults Inside an AS
- •Policy Routing
- •Route Reflectors
- •Confederations
- •Controlling Route and Cache Invalidation
- •BGP Outbound Request Filter Capability
- •Route Dampening
- •Looking Ahead
- •Interesting Organizations
- •Research and Education
- •Miscellaneous
- •Books
- •Internet Request For Comments
- •When to Use BGP ORF
- •Configuration
- •EXEC Commands
- •Closing Remarks
- •The Motivation Behind the New Command-Line Interface
- •Organizing Command Groups in the New Configuration
- •Peer Groups
- •Route Maps
- •Redistribution
- •Route Reflector
- •Aggregation
- •List of BGP Commands
- •Upgrading to the AF Style
Internet Routing Architectures, Second Edition
Example 12-87. Forcing a Peer to Readvertise Adj-RIB-Out
r1# clear ip bgp 1.1.2.2 soft in r1#
2w0d: BGP: 1.1.2.2 sending REFRESH_REQ for afi/safi: 1/1
2w0d: BGP: 1.1.2.2 send message type 128, length (incl. header) 23 2w0d: BGP: 1.1.2.2 send message type 4, length (incl. header) 19 2w0d: BGP: 1.1.2.2 rcv message type 4, length (excl. header) 0
As you can see from the associated debug output in Example 12-87, this triggers a route refresh request to the peer and a subsequent readvertisement of the peer's Adj-RIB-Out.
As displayed in the show ip bgp neighbor output of Example 12-86, there are also counters available to track the number of route refresh requests sent to and received from the peer.
BGP Outbound Request Filter Capability
BGP ORF, enabled by BGP Capabilities (discussed in Chapter 5), helps conserve resources during BGP route update processing. If the ORF capability is advertised by a neighbor during session establishment, this means that the local BGP speaker will allow its neighbor to push over its inbound prefix filter. After it's received, the local BGP speaker installs the filter, in addition to any locally configured outbound filters associated with the neighbor.
Several benefits are associated with BGP ORF:
•The local BGP speaker will no longer consume resources generating routing update messages that will be filtered by the neighbor on input.
•Link bandwidth will not be consumed by the routing updates.
•The neighbor router will not need to consume resources processing routing updates that will be discarded once a filter lookup occurs.
NOTE
It's important to understand that the impact of BGP ORF can be quite significant. For example, if a BGP peer were to send a global Internet routing table (more than 75,000 routes today) to a low-end router that is limited in memory, it might cause this router to run out of memory even if the router has inbound filters installed. Also, sending the routes to the neighbor can consume a significant amount of link bandwidth on lower-speed connections.
This is ideal for ISPs with automated route filter-generation tools and routers with lots of BGP peers. Once the filter is generated and deployed to the edge router in the ISPs network, it is pushed over to the customer's router, thereby conserving both customer and ISP resources.
By default, the ORF Capability is not advertised to neighbors. Also, BGP ORF cannot be advertised to a neighbor that's a BGP peer group member.
As a result of varying BGP ORF syntax across different versions of IOS, we've decided to include Appendix C, "BGP Outbound Route Filter (ORF)," that contains the Cisco release
page 378
Internet Routing Architectures, Second Edition
notes associated with BGP ORF. For additional information, consult the documentation specific to your version of IOS.
Route Dampening
Route dampening is a mechanism used to minimize the instability caused by route flapping and oscillation over the network. The following is the command used to control route dampening:
bgp dampening [[route-map map-name] [half-life-time reuse-value suppressvalue maximum-suppress-time]]
•half-life-time is in the range of 1 to 45 minutes. The current default is 15 minutes.
•reuse-value is in the range of 1 to 20000. The default is 750.
•suppress-value is in the range of 1 to 20000. The default is 2000.
•maximum-suppress-time is the maximum duration that a route can be suppressed. The range is 1 to 255. The default is 4 × half-life-time.
A route map can be associated with BGP dampening to selectively apply the dampening parameters if certain criteria are found. Sample criteria include matching on a specific IP route, AS_PATH, or community.
Figure 12-15 shows two ASs, AS3 and AS1. RTA in AS3 is running IBGP with RTG in AS3 and EBGP with RTC in AS1. Information coming via EBGP from AS3 is injected into OSPF in AS1.
page 379
![](/html/1438/356/html_2oW2HNXhq7.0xAt/htmlconvd-6MtXWk385x1.jpg)
Internet Routing Architectures, Second Edition
Figure 12-15. Route Dampening
RTC has noticed lots of fluctuations in network 172.16.220.0/24 coming from AS3, causing oscillation in its BGP and consequently in OSPF. The 172.16.220.0/24 keeps showing up and disappearing from RTH's routing table. To rectify the problem, RTC will apply dampening to the BGP by using a route map to selectively dampen route 172.16.220.0/24 only. Example 1288 and Example 12-89 show the configurations for RTG and RTA, respectively.
Example 12-88. Route Dampening: RTG Configuration
router bgp 3
no synchronization
network 172.16.112.0 mask 255.255.255.0 neighbor 172.16.70.1 remote-as 3
no auto-summary
Example 12-89. Route Dampening: RTA Configuration
router bgp 3
no synchronization
network 172.16.220.0 mask 255.255.255.0 network 172.16.70.0 mask 255.255.255.0 neighbor 172.16.20.1 remote-as 1 neighbor 172.16.70.2 remote-as 3 neighbor 172.16.70.2 next-hop-self
no auto-summary
page 380
Internet Routing Architectures, Second Edition
RTC is EBGP peered with RTA, and IBGP peered with RTH. RTC is injecting the BGP routes it receives into OSPF, which is running in AS1. RTC is applying BGP dampening with a route map SELECTIVE_DAMPENING, which applies the dampening parameters to network 172.16.220.0/24 only. All other routes such as 172.16.112.0/24 will not be dampened.
The RTC configuration in Example 12-90 specifies the dampening parameters in the following manner:
•The half-life-time is 20 minutes.
•The reuse limit for the penalty is 950.
•Routes will be suppressed if the cumulative penalty exceeds 2500.
•The maximum time a route could be suppressed is 80 minutes.
Example 12-90. Route Dampening: RTC Configuration
router ospf 10 redistribute bgp 1 subnets
network 192.68.0.0 0.0.255.255 area 0 router bgp 1
bgp dampening route-map SELECTIVE_DAMPENING network 192.68.11.0
neighbor 172.16.20.2 remote-as 3 neighbor 192.68.6.1 remote-as 1 no auto-summary
access-list 1 permit 172.16.220.0 0.0.0.255 route-map SELECTIVE_DAMPENING permit 10 match ip address 1
set dampening 20 950 2500 80
route-map SELECTIVE_DAMPENING permit 20
The output in Example 12-90 shows how RTC treats the flapping route 172.16.220.0/24. A flap is counted anytime the path information changes for a route. The BGP table in Example 12-91 shows the route before any flaps have occurred.
Example 12-91. Route Dampening: RTC BGP Table Before Route Flapping
RTC#show ip bgp 172.16.220.0
BGP routing table entry for 172.16.220.0/24, version 326 Paths: (1 available, best #1, advertised over IBGP)
3
172.16.20.2 from 172.16.20.2 (172.16.220.1) Origin IGP, metric 0, valid, external, best
The output in Example 12-92 shows the route after one flap. The route is down and is put in the history state. The route was given the default penalty of 1000, which has already decayed to 997.
Example 12-92. Route Dampening: RTC BGP Table After the First Instance of Route Flapping
RTC#show ip bgp 172.16.220.0
BGP routing table entry for 172.16.220.0/24, version 327
page 381
Internet Routing Architectures, Second Edition
Paths: (1 available, no best path, advertised over IBGP) 3 (history entry)
172.16.20.2 from 172.16.20.2 (172.16.220.1) Origin IGP, metric 0, external
Dampinfo: penalty 997, flapped 1 times in 00:00:06
The output in Example 12-93 shows the route after a second flap (it has come back up again). Another penalty of 1000 has been added, and the cumulative penalty after decay has reached 1454.
Example 12-93. Route Dampening: RTC BGP Table After the Second Instance of Route Flapping
RTC#show ip bgp 172.16.220.0
BGP routing table entry for 172.16.220.0/24, version 328 Paths: (1 available, best #1, advertised over IBGP)
3
172.16.20.2 from 172.16.20.2 (172.16.220.1) Origin IGP, metric 0, valid, external, best
Dampinfo: penalty 1454, flapped 2 times in 00:01:20
Example 12-94 shows the route after four flaps. The penalty is now 2851, which exceeds the 2500 limit. The route is now suppressed (dampened) and will not be passed on to RTH. The route will be usable in 31 minutes and 40 seconds. At that time, the penalty will decay to the reuse limit of 950.
Example 12-94. Route Dampening: RTC BGP Table After Four Instances of Route Flapping
RTC#show ip bgp 172.16.220.0
BGP routing table entry for 172.16.220.0/24, version 329 Paths: (1 available, no best path, advertised over IBGP) 3, (suppressed due to dampening)
172.16.20.2 from 172.16.20.2 (172.16.220.1) Origin IGP, metric 0, valid, external
Dampinfo: penalty 2851, flapped 4 times in 00:03:05, reuse in 00:31:40
The output in Example 12-95 shows the same route after six flaps. The differences are that the half-life-time has been set to 5 minutes instead of 20 minutes, and the maximum-suppress-time is 20 minutes instead of 80. With a shorter half-life-time, the penalty will be decayed much faster, and the route will be used a lot sooner. Note the reuse time of 8 minutes and 10 seconds.
Example 12-95. Route Dampening: RTC BGP Table After Six Instances of Route Flapping
RTC#show ip bgp 172.16.220.0
BGP routing table entry for 172.16.220.0/24, version 336 Paths: (1 available, no best path, advertised over IBGP) 3, (suppressed due to dampening)
172.16.20.2 from 172.16.20.2 (172.16.220.1) Origin IGP, metric 0, valid, external
Dampinfo: penalty 2939, flapped 6 times in 00:08:21, reuse in 00:08:10
Adjusting the dampening timers becomes essential when administrators cannot afford to have a long outage for a specific route. BGP dampening with route maps is a powerful tool to selectively penalize ill-behaved routes in a user-configurable and controlled manner.
page 382