BGP Route Dampening: Penalty, Half-Life and Reuse Limits - 夜莺博客

BGP Route Dampening: Penalty, Half-Life and Reuse Limits

BGP route dampening exists to stop one flapping prefix from consuming CPU cycles across the whole internet: every advertisement and withdrawal of an unstable route generates BGP UPDATE messages that every peer on the path must process. Dampening assigns a penalty to a route each time it flaps and, once the penalty crosses a threshold, suppresses the route entirely — it is neither installed in the routing table nor advertised onward. This article explains the five dampening attributes with their default values, then shows Cisco IOS and Junos configuration with the verification commands that prove dampening is working.

The Five Dampening Attributes

  • Penalty — each flap adds 1000 to the route's penalty.
  • Suppress-limit — when the penalty exceeds 2000 (default), the route is dampened.
  • Half-life — the penalty decays by 50% every 15 minutes (default).
  • Reuse-limit — when the penalty drops below 750 (default), the route is usable and advertised again.
  • Maximum suppress time — 60 minutes default, the cap on how long a route stays suppressed.

Worked example: a penalty of 4000 with a 15-minute half-life decays to 2000 after 15 minutes, 1000 after 30 and 500 after 45. Once below the reuse limit of 750 the route is reinstalled; below 50% of the reuse limit the penalty is removed completely. See also our primer BGP route flap damping explained for the history and rationale.

Cisco IOS Configuration

Enable dampening globally, or selectively per route with a route-map:

R2(config)# router bgp 2
R2(config-router)# bgp dampening
R2(config-router)# exit

Selective dampening uses a route-map that matches specific prefixes with ip prefix-list, so only fragile customer routes are dampened instead of the full table:

R2(config)# ip prefix-list FLAPPY permit 192.168.0.0/16 le 24
R2(config)# route-map DAMPEN permit 10
R2(config-route-map)# match ip address prefix-list FLAPPY
R2(config)# router bgp 2
R2(config-router)# bgp dampening route-map DAMPEN

Verification on Cisco IOS

R2# show ip bgp dampening parameters
R2# show ip bgp dampening flap-statistics
R2# show ip bgp dampened-paths
R2# clear ip bgp dampening

The parameters output shows the running profile — for example dampening 15 750 2000 60 (DEFAULT) — while flap-statistics lists each suppressed prefix with its flap count, duration and reuse time. The d status flag marks a damped route.

Junos Damping and Modern Practice

Junos implements the same mechanics through BGP group damping settings; half-life, reuse and suppress thresholds are configured per peer group or globally with the damping statement, and Juniper's documentation on damping parameters explains the decay math in depth. Before enabling dampening anywhere, read the RIPE-580 recommendation referenced in NetworkLessons' lesson: modern routers are powerful enough that dampening mainly makes sense for very specific instability problems, and enabling it globally on an internet edge can suppress legitimate routes for an hour. Our Junos flap damping configuration guide walks through the parameter tuning.

原文链接:https://networklessons.com/bgp/bgp-route-dampening