Routing

last person joined: 4 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.  Juniper MX - VRF RIP export/redistribution to MBGP with local pref changes

    Posted 06-14-2012 03:32

    Hi All,

     

    We have an MPLS network using MX Series routers.

     

    On one of the customer VRFs we have RIP to customer router, the received RIP routes are being redistributed in to MGBP. I need to change the local pref of a selected number of the RIP routes to influence routing within the MPLS network. I assume I need to use  "vrf-export" and create an associated policy.

     

    My current config is as follows:

     

    [edit routing-instances L3VPN_STAPLE]
    cp@TH-MX80-01# show
    instance-type vrf;
    interface ae2.3505;
    interface lo0.364;
    route-distinguisher 65001:3348;
    vrf-target target:65001:3348;
    vrf-table-label;
    protocols {
    rip {
    group staple {
    export staple-l3vpn-export-ae2.3505;
    neighbor ae2.3505 {
    import staple-l3vpn-import-ae2.3505;
    }

     

     

    Would the following policy work to change the local pref of 10.8.0.0/21 to 50 while keeping all other RIP received routes at local pref 100.

     

    [edit routing-instances L3VPN_STAPLE]

    set vrf-export STAPLE-VRF-EXPORT

     

     

    [edit policy-options STAPLE-VRF-EXPORT]
    term set-lpref-50 {
    from {
    route-filter 10.8.0.0/21 exact;
    }
    then local-preference 50
    then accept;
    }
    term everything_else {
    then accept;
    }

     

     

    Any advice would be appreciated.

     

    Thanks,

    Chris



  • 2.  RE: Juniper MX - VRF RIP export/redistribution to MBGP with local pref changes

    Posted 06-17-2012 19:02

    your policy look good to me



  • 3.  RE: Juniper MX - VRF RIP export/redistribution to MBGP with local pref changes

    Posted 06-19-2012 09:01

    If i am not wrong, you need to import it, because you want to influence the routes inside your network (provider), so any routes coming from Customer should be influenced by the import policy...

     

    thanks



  • 4.  RE: Juniper MX - VRF RIP export/redistribution to MBGP with local pref changes
    Best Answer

    Posted 06-20-2012 02:36

    Thanks for your input.

     

    I didn't need to use a vrf-import policy as I didn't need to influence routing on the local PE router. I tested this in a non-production L3VPN. I wanted to set the local-pref on the 10.10.10.0/24 route to 200, while leave the local-pref on the 10.10.11.0/24 route as 100 (the default).

     

    My vrf-export didn't work until I added a community on to the policy as show below:

     

    set interfaces ge-1/0/8 unit 999 description "TEST L3VPN"
    set interfaces ge-1/0/8 unit 999 vlan-id 999
    set interfaces ge-1/0/8 unit 999 family inet address 10.10.10.1/24

     

    set routing-instances L3VPN_TEST description "TEST L3VPN"
    set routing-instances L3VPN_TEST instance-type vrf
    set routing-instances L3VPN_TEST interface ge-1/0/8.999
    set routing-instances L3VPN_TEST route-distinguisher 65001:30703070
    set routing-instances L3VPN_TEST vrf-export L3VPN-VRF-TEST-EXPORT
    set routing-instances L3VPN_TEST vrf-target target:65001:30703070
    set routing-instances L3VPN_TEST vrf-table-label
    set routing-instances L3VPN_TEST routing-options static route 10.10.11.0/24 next-hop 10.10.10.2

     

     

    set policy-options policy-statement L3VPN-VRF-TEST-EXPORT term lpref-200 from route-filter 10.10.10.0/24 exact
    set policy-options policy-statement L3VPN-VRF-TEST-EXPORT term lpref-200 then local-preference 200
    set policy-options policy-statement L3VPN-VRF-TEST-EXPORT term lpref-200 then next term
    set policy-options policy-statement L3VPN-VRF-TEST-EXPORT term everything_else then community add L3VPN_TEST
    set policy-options policy-statement L3VPN-VRF-TEST-EXPORT term everything_else then accept

     

    set policy-options community L3VPN_TEST members target:65001:30703070

     

     

    On a remote PE the routes are show with the correct local-pref.

     

    gel@HT-MX-01> show route table L3VPN_TEST

    L3VPN_TEST.inet.0: 5 destinations, 6 routes (4 active, 0 holddown, 1 hidden)
    + = Active Route, - = Last Active, * = Both

    10.10.10.0/24 *[BGP/170] 00:20:30, localpref 200, from 10.200.10.21
    AS path: I
    > to 10.200.10.193 via xe-1/3/0.1, Push 19, Push 300320(top)
    10.10.11.0/24 *[BGP/170] 00:01:18, localpref 100, from 10.200.10.21
    AS path: I
    > to 10.200.10.193 via xe-1/3/0.1, Push 19, Push 300320(top)

     

     

    This link was on use:

    http://www.juniper.net/techpubs/en_US/junos10.1/information-products/topic-collections/config-guide-vpns/topic-33742.html#id-10149663

     

    Thanks,

    Chris