To test the example in this section, perform the following steps:
system {
scripts {
commit {
file ex-add-accept.xsl;
}
}
}
firewall {
policer sgt-friday {
if-exceeding {
bandwidth-percent 10;
burst-size-limit 250k;
}
then discard;
}
family inet {
filter test {
term one {
from {
interface t1-0/0/0;
}
then {
count ten-network;
discard;
}
}
term two {
from {
forwarding-class assured-forwarding;
}
then discard;
}
}
}
}
interfaces {
t1-0/0/0 {
unit 0 {
family inet {
policer output sgt-friday;
filter input test;
}
}
}
}
- [edit]
- user@host# load merge terminal
- [Type ^D at a new line to end input]
- > Paste the contents of the clipboard here<
[edit]
user@host# commit
[edit firewall family inet filter test]
warning: filter is missing final 'then accept' rule
commit complete
[edit]
user@host# show firewall
policer sgt-friday {
if-exceeding {
bandwidth-percent 10;
burst-size-limit 250k;
}
then discard;
}
family inet {
filter test {
term one {
from {
interface t1-0/0/0;
}
then {
count ten-network;
discard;
}
}
term two {
from {
forwarding-class assured-forwarding;
}
then {
discard;
}
}
term very-last {
then accept; /* This term was added by a commit script */
}
}