[j-nsp] Policy-statement to match on metrics less than, greater than, or within a range

Mark Tinka mark.tinka at seacom.mu
Thu Aug 27 00:40:52 EDT 2015



On 27/Aug/15 01:55, Phil Rosenthal wrote:

> Hello all,
>
> On Cisco, it is possible to write a route policy as such:
>
> route-policy test
>     if med le 1000 then
>     set local-preference 100
>   endif
>   end-policy
>
> Is there any way to do the same thing with Juniper? It seems that the “from metric” statement only accepts a static value (comparable to "if med eq 1000”).

I've never used metric as a match condition in anything, but from what I
can see in Junos, the value needs to be absolute.

Of course, you can have as many terms as you want matching various
metric values, but this is not as elegant as the IOS XR one, I suppose.

Mark.


More information about the juniper-nsp mailing list