Routing

 View Only
last person joined: 2 days ago 

Ask questions and share experiences about ACX Series, CTP Series, MX Series, PTX Series, SSR Series, JRR Series, and all things routing, including portfolios and protocols.
  • 1.  Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-15-2012 13:50

    If a static route is defined with multiple qualified-next-hops, but all with the same preference, what is the criteria for the selected route?

     

    Eg.  The configuration snippet below :-

     

    root@R1# show routing-options

    static {

    route 1.1.1.0/24 {
    Qualified-next-hop 192.168.12.101 {
    Preference 100;
    }
    Qualified-next-hop 192.168.12.2 {
    Preference 10;
    }
    Qualified-next-hop 192.168.12.200 {
    Preference 10;
    }
    Qualified-next-hop 192.168.12.100 {
    Preference 10;
    }
    }
    }

     

    This results in the middle IP 192.168.100 being selected. There seems to be no set criteria for this selection like highest or lowest IP, first configured, last configured etc.

     

    root@R1# run show route 1.1.1/24 extensive

    .NET: 12 destinations, 14 routes (11 active, 0 holding, 1 hidden)
    1.1.1.0/24 (2 entries, 1 announced)
    State: <Record Pending>
    TSI:
    KRT in-kernel 1.1.1.0/24 -> {192.168.12.100}
    *Static Preference: 10
    Next hop type: Router
    Next-hop reference count: 1
    Next hop: 192.168.12.2 via fxp0.0
    Next hop: 192.168.12.100 via fxp0.0, selected
    Next hop: 192.168.12.200 via fxp0.0
    State: <Active Int Ext>
    Age: 4:27
    Task: RT
    Announcement bits (2): 0-KRT 5-RT
    AS path: I
    AS path: Recorded
    Static Preference: 100
    Next hop type: Router, Next hop index: 471
    Next-hop reference count: 2
    Next hop: 192.168.12.101 via fxp0.0, selected
    State: <Int Ext>
    Inactive reason: Route Preference
    Age: 4:27
    Task: RT
    AS path: I
    AS path: Recorded

     

    Does anyone know the rule/algorithm used by RE to make this selection?  The documentation does not address this.

     

    Thanks,

     

    Nic

     


    #qualified-next-hop
    #floatingstaticroutes


  • 2.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-15-2012 23:00

    Hi Nic

         Pls you may check the next-hop metric.



  • 3.  RE: Junos Tie-Breakers for Qualified-Next-Hops
    Best Answer

    Posted 09-15-2012 23:24

    Hi,

     

    it will select one of these next hop randomly per subnet and install it in the forwarding table as no load-balancing by default

     

    IF you want to load-balance you could apply this command

     

    policy-options {
        policy-statement Load-Balance {
            then {
                load-balance per-packet;
            }
        }

    }

     

    routing-options {
        forwarding-table {
            export Load-Balance;
        }
    }

     

    and you could check the status before and after by this command

     

    # run show route forwarding-table destination 1.1.1.1

     

     

    Regards,

    Mohamed Elhariry

     



  • 4.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-15-2012 23:52

    Hi 

       Mr. Elhariry is correct if you want to load balance. For floading route, the next tie breaker will be metric when the preference is the same.



  • 5.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-16-2012 05:26

    Hi Guys

         I found it on Juniper.net. When you do not set a preferred route, traffic is alternated between routes in round-robin fashion. 

     

    http://www.juniper.net/techpubs/en_US/junos12.1/topics/topic-map/policy-static-route-selection.html



  • 6.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-16-2012 05:51

    Thanks Mohamed, Hugo,

     

    One thing that is contradictory in my mind is this.

     

    As per Mohamed and from my own research, we have to use the policy to enforce per-packet load balancing and as a result, all NHs with the same preference are now installed in the forwarding table.

     

    But from Hugo's article, it would seem that this is happening by default. My own tests lead me to believe that the article might be assuming that the user hasalready put the policy in place.

     

    Thanks again,

     

    Nic



  • 7.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-16-2012 09:31

    Hi Guys,

    Please check the following topic. Even though it is discussed for EX series, it is applicable to other platforms too.

     

    http://forums.juniper.net/t5/Ethernet-Switching/How-does-EX-switch-select-route-with-same-metrics/td-p/159286

     

    Regards,

    Moses N



  • 8.  RE: Junos Tie-Breakers for Qualified-Next-Hops

    Posted 09-16-2012 09:56

    Hi Moses

        I just did a test on M7i with 2 next-hop or 2 qualified-next-hop, it won't load balance by native configuration(without balancing policy). Mohamed and you guys are correct with real practice. Just wondering why Juniper documentation says so. It's weird. Anyway , thank you guys let me clarify some scenarios on this topic.