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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 9: Firewall Filter <strong>Configuration</strong><br />

NOTE: <strong>Configuration</strong> of interface-specific counters also creates separate<br />

instances of any policers and counters you have configured for the same<br />

interface.<br />

To configure interface-specific counters, include the interface-specific statement at the<br />

[edit firewall family family-name filter filter-name] hierarchy level:<br />

[edit firewall family filter filter-name]<br />

interface-specific;<br />

NOTE: The suffixes -i (input) and -o (output) are added to the counter names<br />

automatically. The counter name is restricted to 24 bytes, and if the renamed<br />

counter exceeds this maximum length, the policy framework software might<br />

reject it.<br />

Example: Configuring Interface-Specific Counters<br />

Configure an interface-specific counter:<br />

Defining Interface Groups<br />

[edit firewall]<br />

family inet {<br />

filter test {<br />

interface-specific;<br />

term 1 {<br />

from {<br />

address {<br />

10.0.0.0/12;<br />

}<br />

protocol tcp;<br />

}<br />

then {<br />

count sample1;<br />

accept;<br />

}<br />

}<br />

}<br />

}<br />

When you apply this filter to the input interface of at-1/1/1.0 and the output interface of<br />

so-2/2/2.2, the counters are named sample1-at-1/1/1.0-i and sample1-so-2/2/2/.2-o. The<br />

suffixes -i (input) and -o (output) are added to the counter names automatically.<br />

The Junos OS does not sample packets originating from the router. If you configure a<br />

filter and apply it to the output side of an interface, then only the transit packets going<br />

through that interface are sampled. Packets that are sent from the Routing Engine to<br />

the Packet Forwarding Engine are not sampled.<br />

When applying a firewall filter, you can define an interface to be part of an interface group.<br />

Packets received on that interface are tagged as being part of the group. You then can<br />

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

237

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

Saved successfully!

Ooh no, something went wrong!