Two new transitional optional attributes, new-as-path and new-aggregator, are used to
carry the four-octet numbers across the old speakers. A new speaker communicating
with an old speaker will send the new attributes with the four-octet numbers for
locally-originated and propagated routes. The old speaker propagates the new attributes
for received routes. The new speaker also sends the AS-path and aggregator attributes
with two-octet numbers; any AS number greater than 65535 is replaced with a reserved
AS number, 23456.
Graceful Restarts
When BGP restarts on a router, all of the router’s BGP peers detect that the BGP session
transitioned from up to down. The transition causes a routing flap throughout the network
as the peers recalculate their best routes in light of the loss of routes from that peering
session.
The BGP graceful restart capability reduces the network disruption that normally results
from a peer session going down. If the session is with a peer that had previously advertised
the graceful restart capability, the receiving BGP speaker marks all routes from that peer
in the BGP routing table as stale. BGP keeps these stale routes for a limited time and
continues to use these routes to forward traffic. Any existing stale routes from that peer
are deleted to account for consecutive restarts.
When the restarting peer reestablishes the session, the receiving BGP speaker replaces
the stale routes with the fresh routes it receives from the peer. The restarted peer sends
an End-of-RIB marker to signal when it has finished sending all its routes to the BGP
speaker. Until this point, BGP has still been using the stale routes to forward traffic. Upon
receipt of the End-of-RIB marker, the BGP speaker flushes any remaining stale routes
from the restarted peer.
The End-of-RIB marker is an update message that contains no advertised or withdrawn
prefixes; it is sent only to BGP speakers that have previously advertised the graceful
restart capability.
The receiving speaker also sends its own routes to the restarted speaker, and sends an
End-of-RIB marker when it completes the update. The restarted peer defers reinitiating
the BGP best-path selection process until it has received this marker from all peers with
which it had a session in the established state and from which it had received an
End-of-RIB marker before it restarted.
After running the selection process to pick the best route to all prefixes using the fresh
routes, BGP then installs the best routes in the IP routing table on the restarted peer. Any
of these that are best overall routes to a prefix are then pushed by the router to the
forwarding tables on the line modules.
By waiting for all restarted peers to send the End-of-RIB marker, BGP risks delaying the
initiation of the best path decision process indefinitely due to a single very slow peer. For
a specific peer, you can avoid this delay by hard clearing the peer or issuing the clear ip
bgp wait-end-of-rib command. Either method removes that peer from the set of peers
for which BGP is awaiting an End-of-RIB marker. Alternatively, you can minimize this
effect by using the bgp graceful-restart path-selection-defer-time-limit command to
specify a maximum period that the restarted peer waits for the marker from its peers.
125Copyright © 2010, Juniper Networks, Inc.
Chapter 1: Configuring BGP Routing