Two routing protocols, Same administrative distance?

Filed in Routing by on December 31, 2007 7 Comments

What happens when a router has two routing protocols running and is receiving similar routes from each routing protocol?

Easy question, right? The routing protocol with the lower administrative distance has its routes installed in the routing table (routing information base – RIB).

However, an interesting question that comes up from time to time is this:

What if I configure the administrative distance to be the same for two routing protocols? Will the router install routes from each routing protocol and allow me to load balance traffic?

The answer is NO. A route for a specific prefix can only be installed in the routing table by one routing protocol. For example, you cannot have a route to the prefix 10.1.1.0 /24 exist in the routing table from both EIGRP and eBGP.

So lets say you configured EIGRP to have the same administrative distance as eBGP (20). Which route to 10.1.1.0 /24 will be installed? When there is a tie of configured administrative distance settings the router will use the default administrative distance to make the decision.

In this case, since eBGP has lower default administrative distance than EIGRP (20 vs. 90), only the route from eBGP will be installed in the routing table (RIB).

From http://www.cisco.com/warp/public/105/admin_distance.html:

Default Distance Value Table

This table lists the administrative distance default values of the protocols that Cisco supports:

Route Source Default Distance Values
Connected interface 0
Static route 1
Enhanced Interior Gateway Routing Protocol (EIGRP) summary route 5
External Border Gateway Protocol (BGP) 20
Internal EIGRP 90
IGRP 100
OSPF 110
Intermediate System-to-Intermediate System (IS-IS) 115
Routing Information Protocol (RIP) 120
Exterior Gateway Protocol (EGP) 140
On Demand Routing (ODR) 160
External EIGRP 170
Internal BGP 200
Unknown* 255

About the Author ()

Brad Hedlund is an Engineering Architect with the CTO office of VMware’s Networking and Security Business Unit (NSBU), focused on network & security virtualization (NSX) and the software-defined data center. Brad’s background in data center networking begins in the mid-1990s with a variety of experience in roles such as IT customer, systems integrator, architecture and technical strategy roles at Cisco and Dell, and speaker at industry conferences. CCIE Emeritus #5530.

Comments (7)

Trackback URL | Comments RSS Feed

  1. Stas says:

    And what if I configure two identical static routes with the same metric and AD? Which of the routes will be used?

  2. Brad Hedlund says:

    So if the same routing protocol has two or more equal cost routes, each route will be installed in the routing table and load balanced. Static routes can be considered a routing protocol in this context. Therefore two static routes with the same AD will result in both static routes being installed in the routing table and the router will perform equal cost load balancing.

    The point of this article was to address what happens if two different routing protocols have the same route with the same administrative distance. The router will never install a similar route from two different routing protocols.

    Thanks for the question.

  3. Dara says:

    A very good practice,

    This blog is surely a great idea to share the knowledge wealth that the Author has, a nice idea to improve the overall knowledge of all the Engineers.

    Thanks a lot for the contribution,
    Good Luck

  4. Smitha says:

    Hi Brad,
    This article was a great one but I still have a question,

    If we have routes to destination 130.10.10.1 getting advertised
    as
    1]130.10.0.0 by IGRP
    2]130.10.10.0 by RIP

    which one will be installed ? will it install IGRP as its AD is lower or RIP as it is more precise.
    What is the order(AD and precision) that the router will look for ?

    Regards,
    Smitha

    • Brad Hedlund says:

      Smitha,
      In your case both routes will be installed as they are different, not identical. Once both routes are installed in the routing table, traffic destined to 130.10.10.1 will use the RIP route as it provides the more precise match.

  5. mostafa ahdy says:

    really, this is very confusing question,and i was thinking about an answer to it until my brain become like a platter of egg.
    so, thank you, Brad Hedlund about your information.
    And this site will be in my favorites.

Leave a Reply

Your email address will not be published. Required fields are marked *