16.03.2014 Views

Policy Framework Configuration Guide - Juniper Networks

Policy Framework Configuration Guide - Juniper Networks

Policy Framework Configuration Guide - Juniper Networks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Junos 10.4 <strong>Policy</strong> <strong>Framework</strong> <strong>Configuration</strong> <strong>Guide</strong><br />

Including BGP Communities and Extended Communities in Routing <strong>Policy</strong> Match<br />

Conditions<br />

To include a BGP community or extended community in a routing policy match condition,<br />

include the community condition in the from statement of a policy term:<br />

from {<br />

community [ names ];<br />

}<br />

You can include this statement at the following hierarchy levels:<br />

• [edit policy-options policy-statement policy-name term term-name]<br />

• [edit logical-systems logical-system-name policy-options policy-statement policy-name<br />

term term-name]<br />

Additionally, you can explicitly exclude BGP community information with a static route<br />

by using the none option. Include this option when configuring an individual route in the<br />

route portion to override a community option specified in the defaults portion.<br />

NOTE: You can include the names of multiple communities in the community<br />

match condition. If you do this, only one community needs to match for a<br />

match to occur (matching is effectively a logical OR operation).<br />

How BGP Communities and Extended Communities Are Evaluated in Routing <strong>Policy</strong><br />

Match Conditions<br />

When you use BGP communities and extended communities as match conditions in a<br />

routing policy, the policy framework software evaluates them as follows:<br />

• Each route is evaluated against each named community in a routing policy from<br />

statement. If a route matches one of the named communities in the from statement,<br />

the evaluation of the current term continues. If a route does not match, the evaluation<br />

of the current term ends.<br />

• The route is evaluated against each member of a named community. The evaluation<br />

of all members must be successful for the named community evaluation to be<br />

successful.<br />

• Each member in a named community is identified by either a literal community value<br />

or a regular expression (for information about using regular expressions, see “Using<br />

UNIX Regular Expressions in Community Names” on page 105). Each member is<br />

evaluated against each community associated with the route. (Communities are an<br />

unordered property of a route. For example, 1:2 3:4 is the same as 3:4 1:2.) Only one<br />

community from the route is required to match for the member evaluation to be<br />

successful.<br />

• Community regular expressions are evaluated on a character-by-character basis. For<br />

example, if a route contains community 1234:5678, the regular expressions see nine<br />

110<br />

Copyright © 2010, <strong>Juniper</strong> <strong>Networks</strong>, Inc.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!