BGP is slow to converge. What makes it slow, and how do you speed it up?
Show the answer
Say this first
Four things. Detecting the failure (a 180 second hold timer). Recomputing, including path hunting through alternatives that are also failing. Propagating (the advertisement interval, 30 seconds for eBGP on Cisco, plus the time to send many prefixes). And reprogramming the forwarding table prefix by prefix. Fixes map onto each: BFD and fast external fallover for detection, next hop tracking so IGP changes trigger BGP at once, add-path or best-external so backup paths are already known, and BGP PIC so the FIB switches all affected prefixes to a precomputed backup next hop in one step.
Go deeper
Detection
bgp fast-external-fallover(on by default in IOS) for directly connected eBGP.- BFD with
neighbor x fall-over bfdfor everything else.
Reacting to IGP changes
Next hop tracking watches the routes to BGP next hops and recalculates when they change, instead of waiting for a periodic scan. On IOS it is on by default, with a short trigger delay (5 seconds).
Knowing the backup in advance
A route reflector advertises one best path, so after a failure its clients wait for the RR to compute and send a new one. Add-path sends extra paths; best-external makes a router advertise its own external path even when an internal one is best.
Programming the FIB
Without PIC, a router with 900,000 prefixes behind a failed next hop rewrites 900,000 entries. With BGP PIC (prefix independent convergence), prefixes share next hop objects with a precomputed backup, so one change moves them all.
Planned work
Graceful shutdown: before maintenance, tag routes with GRACEFUL_SHUTDOWN (65535:0) or lower their local preference and wait for traffic to move, then shut the session. Graceful restart and NSR keep forwarding while a control plane restarts.
They will ask next
What is route flap dampening, and why is it used less now?
It adds a penalty each time a prefix flaps (1000 per flap on Cisco) and suppresses it above 2000 until the penalty decays below 750, with a 15 minute half-life and 60 minute maximum suppression. Aggressive settings punished normal convergence events, so operators now use it lightly or not at all.
How do you take an edge router out of service without dropping traffic?
Make its paths less preferred first (graceful shutdown community, lower local preference, or prepend outbound), wait until traffic has moved to the other edge, then shut the sessions.
Traps
- Focusing only on timers. Big tables converge slowly because of the FIB, which is why PIC exists.