BGP bases its decision process on the
attribute values. When faced with multiple routes to the same
destination, BGP chooses the best route for routing traffic toward
the destination. The following process summarizes how BGP chooses
the best route:
- If the next hop is inaccessible,
the route is ignored (this is why it is important to have an IGP
route to the next hop).
- The BGP router will prefer the
path with the largest weight (weight is a Cisco-proprietary
parameter).
- If the weights are the same, the
BGP router will prefer the route with the largest local
preference.
- If the routes have the same local
preference, the BGP router will prefer the route that was
locally originated (originated by this router).
- If the local preference is the
same, the BGP router will prefer the route with the shortest
AS_Path.
- If the AS_Path length is the same,
the BGP router will prefer the route with the lowest origin type
(where IGP is lower than EGP, and EGP is lower than INCOMPLETE).
- If the origin type is the same,
the BGP router will prefer the route with the lowest MED.
- If the routes have the same MED,
the BGP router will prefer the route in the following manner:
External (EBGP) is better than confederation external, which is
better than IBGP. (BGP confederations are not covered in this
book. For more information, consult Cisco's web site, at http://www.cisco.com/univercd.
- If all the preceding scenarios are identical, the BGP router
will prefer the route that can be reached via the closest IGP
neighbor; that is, take the shortest internal path inside the AS
to reach the destination (follow the shortest path to the BGP
Next Hop).
- If the internal path is the same,
the BGP router ID will be a tiebreaker. The BGP router will
prefer the route coming from the BGP router with the lowest
router ID. The router ID is usually the highest IP address on
the router or the loopback address.
|
|