Routing

last person joined: 3 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.  Policy statements and default routes

    Posted 11-22-2012 01:09

    Hi guys

    im new to juniper and wanted some help on inbound route filtering.  

     

    A peer is sending me a default route along with other prefixes and I wanted to write a term within a policy statement whereby I just allow the default route - set it with a local pref of 75 and ignore all other prefixes received from them.


    so Far i have this :

     

    term FROM_PEER1 {
    from {
    next-hop x.x.x.x;
    route-filter 0.0.0.0/0 exact;
    }
    then {
    local-preference 75;
    accept;
    }
    }

     

    It kind of works - I get a default route with a local pref of 75 - BUT im also getting all other prefixes they are sending.  


    In cisco - I would right an ACL allowing 0.0.0.0/0 and then deny any any - 

     

    Any ideas where Im going wrong with my syntax above?

     

    thanks

     

    Sol



  • 2.  RE: Policy statements and default routes

    Posted 11-22-2012 02:10

    Hi Sol,

     

    Juniper is similar to Cisco you have to add another term equal to the line you type in Cisco ACL

     

    term reject {
    then {
    reject;
    }
    }

     

    Mohamed Elhariry

     

    JNCIE-M/T # 1059, CCNP & CCIP

     

    ----------------------------------------------------------------------------------------------------------------------------------------

    If this post was helpful, please mark this post as an "Accepted Solution". Kudos are always appreciated!



  • 3.  RE: Policy statements and default routes

    Posted 11-22-2012 02:14

    Mohammed

     

    thanks for the reply -  so would that term be nested within the term  FROM_PEER1   or would it be applied right at the bottom of the other terms

     

     

     

    policy statement ROUTES_IN 
    term FROM_PEER1 { 
    from { 
    next-hop x.x.x.x; 
    route-filter 0.0.0.0/0 exact; 

    then { 
    local-preference 75; 
    accept; 
    }

    term reject {
    then {
    reject;
    }
    }

    }



  • 4.  RE: Policy statements and default routes

    Posted 11-22-2012 02:22

    It is exactly as you typed with same order. No need to match term (from statement) it will match all traffic by default (equal to 0.0.0.0 0.0.0.0)

     

    Regards,

    Mohamed



  • 5.  RE: Policy statements and default routes
    Best Answer

    Posted 11-22-2012 02:36

    thanks Mohammed 

    much appreciated.

     

    Regards

     

    Sol