Multicast and Routing Guide K/KA/KB.15.15
• Prefer the route with the lowest IGP cost to the BGP next hop. IGP cost is determined by
comparing the preference, then the weight, then the metric, and finally the metric2 of the two
resolving routes.
• If “ip load-sharing” is enabled, BGP inserts up to n most recently received paths in the IP
routing table. This allows eBGP multipath load sharing. The maximum value of n is currently
4. The default value of n, when “ip load-sharing” is disabled, is 1. The oldest received path
is marked as the best path in the output of show ip bgp prefix/len.
• Prefer routes received from external peers.
• If bgp tie-break-on-age has been specified, prefer the older route.
• If bgp bestpath compare-router-id has been specified, prefer the route learned with
the lowest router ID. The router ID is taken from the Open message of the peering session over
which the route was received, unless bgp bestpath compare-originator-id has been
specified, and the route was received with an ORIGIN_ID. In the latter case, the ORIGIN_ID
is used instead of the router ID from the Open message.
• If bgp bestpath compare-cluster-list-length has been specified, prefer the route
with the lowest CLUSTER_LIST length.
• Prefer the route with the lowest neighbor address.
NOTE: CLUSTER_IDs of route reflectors form a CLUSTER_LIST. If a route reflector receives a route
that contains its own CLUSTER ID in the CLUSTER_LIST, the router discards the route to avoid routing
loops.
Recursive route in iBGP
The nexthop of an iBGP route may not always be directly connected. One of the reasons is next
hops in routing information exchanged between iBGPs are not modified. In this case, the BGP
router needs to find the directly connected next hop via IGP. The matching route with the direct
next hop is called the recursive route. The process of finding a recursive route is route recursion.
Route selection with BGP load sharing
BGP differs from IGP in the implementation of load balancing in the following:
• IGP routing protocols such as RIP and OSPF compute metrics of routes, and then implement
load sharing over routes with the same metric and to the same destination. The route selection
criterion is metric.
• BGP has no route computation algorithm, so it cannot implement load sharing according to
metrics of routes. However, BGP has abundant route selection rules, through which it selects
available routes for load sharing and adds load sharing to route selection rules.
BGP route selection 307










