Skip navigation
Cisco Learning Home > Certifications > CCIE Routing & Switching > Discussions

_Communities

This Question is Answered 1 Helpful Answer available (2 pts)
1547 Views 25 Replies Latest reply: Apr 20, 2012 8:29 AM by Stephen RSS 1 2 Previous Next

Currently Being Moderated

Is this a bug?

Apr 16, 2012 10:31 AM

Stephen 488 posts since
Apr 22, 2011

Hi guys,

 

I'm using gns3.  Just come across a situation where I think BGP picked the wrong best path.  Check the BGP 100.100.100.0/24 entry below (I included the bgp config so you can see that I don't have deterministic med, always-compare med, or bgp best path compare router-id on).

 

R1#sh run | s bgp

router bgp 10

no synchronization

bgp router-id 1.1.1.1

bgp log-neighbor-changes

network 12.12.12.0 mask 255.255.255.252

network 13.13.13.0 mask 255.255.255.252

network 14.14.14.0 mask 255.255.255.252

neighbor 12.12.12.2 remote-as 20

neighbor 13.13.13.2 remote-as 30

neighbor 14.14.14.2 remote-as 30

no auto-summary

 

R1#sh ip bgp 100.100.100.0/24

BGP routing table entry for 100.100.100.0/24, version 55

Paths: (3 available, best #1, table Default-IP-Routing-Table)

  Advertised to update-groups:

     1

  30 40

    13.13.13.2 from 13.13.13.2 (3.3.3.3)

      Origin IGP, metric 100, localpref 100, valid, external, best

  20 40

    12.12.12.2 from 12.12.12.2 (2.2.2.2)

      Origin IGP, metric 150, localpref 100, valid, external

  30 40

    14.14.14.2 from 14.14.14.2 (4.4.4.4)

      Origin IGP, metric 200, localpref 100, valid, external

 

So the first two paths are compared.  AS_PATHs are different, so med is ignored.  The best-path should be via the oldest route (2.2.2.2).  This should then be compared against the entry below via the router 4.4.4.4.  The bottom entry should then win because of age. 

 

Can anyone tell me why it's picked the first path please, is it a bug?

  • Marek 7 posts since
    Dec 15, 2010
    Currently Being Moderated
    1. Apr 16, 2012 10:48 AM (in response to Stephen)
    Re: Is this a bug?

    I think the decision is made using IGP metric:

     

    Prefer the path with the lowest IGP metric to the BGP next hop.

     

    See this: http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094431.shtml

     

    Or am I wrong?

     

    Marek

  • Martin 13,077 posts since
    Jan 16, 2009
    Currently Being Moderated
    2. Apr 16, 2012 12:21 PM (in response to Stephen)
    Re: Is this a bug?

    MED is 100, which is smaller than 150 or 200, so it is picked as the best. btw. this is not IGP metric to neighbor.

     

    AS Path -  in terms of Hops of AS - the shortest path is the Best.

  • Marek 7 posts since
    Dec 15, 2010
    Currently Being Moderated
    3. Apr 16, 2012 12:27 PM (in response to Martin)
    Re: Is this a bug?

    Thanks Martin for the clarification - I was wrong. A good resource for the MED topic:

     

    http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094934.shtml#med

     

    Marek

  • Martin 13,077 posts since
    Jan 16, 2009
    Currently Being Moderated
    5. Apr 16, 2012 2:34 PM (in response to Stephen)
    Re: Is this a bug?

    Yes, but I see two paths with 30 40; and one 20, 40; total 3 paths;

    so I guess 100 is compared with 200, skipping 150; no skipping allowed

     

    Try this: remove 1st one with 100 so that u have 150 and 200 or 30 40 and 20 40;

    what happens?

     

    btw. this  might depend on IOS version or even a Bug; what is your IOS?

  • Martin 13,077 posts since
    Jan 16, 2009
    Currently Being Moderated
    7. Apr 16, 2012 3:07 PM (in response to Stephen)
    Re: Is this a bug?

    You are right about comparing 1st two paths from top, then next one and so on - default Cisco way is my understanding.

    Let me read the link Marek posted and make sense out of it.

     

    No idea why your outputs are different than expected. if u attach gns3 configs and .net files here, I can try it later. Try it on another IOS.

    of course, order of booting routers will matter here as well.

     

    Message was edited by: Martin

  • Currently Being Moderated
    9. Apr 17, 2012 5:39 AM (in response to Stephen)
    Re: Is this a bug?

    It looks like it's choosing the path received from the neighbor with the lowest router ID.

  • Currently Being Moderated
    11. Apr 17, 2012 6:49 AM (in response to Stephen)
    Re: Is this a bug?

    It's not a bug.  In your initial post MED was used because you have two paths being receive from the same AS. (1st & 3rd entries).  It chose the path with the best MED.  In this example, that was the path with the MED value of 100.

  • Currently Being Moderated
    13. Apr 17, 2012 7:27 AM (in response to Stephen)
    Re: Is this a bug?

    You can check the release notes for the IOS you are using to see if there is a bug related to this, but it looks like BGP deterministic-med is enabled by default in the IOS.  When you said you tried 3 different IOS versions, did you try 3 different router model IOSs or 3 different sub releases of the 3600 model?

     

    What happens if you issue the command no bgp deterministic-med and update your policy?

Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)