Applying Classifiers and Rewrite Rules at the Global, Physical, and Logical Interface Levels
Depending on your platform, CoS supports classification and rewrite at the global, physical, and logical interface levels.
To apply a global EXP classifier, include the following statements at the [edit class-of-service] system-defaults hierarchy level.
[edit class-of-service] user@device# set system-defaults classifiers exp classifier-name
On supported platforms, CoS supports one global system default classifier of the EXP type, as shown in the following example:
[edit class-of-service]
{
system-defaults {
classifiers {
exp exp-classf-core;
}
}
}
To configure classifiers and rewrite rules at the physical interface level, include the following statements at the [edit class-of-service] interfaces hierarchy level.
[edit class-of-service]
interfaces {
interface-name
classifiers dscp classifier-name
classifiers inet-precedence classifier-name
classifiers ieee-802.1 [vlan-tag (outer | inner)] classifier-name
rewrite-rules dscp rewrite-name
rewrite-rules inet-prec rewrite-name
rewrite-rules ieee-802.1 rewrite-name
}
The following example shows classifiers and rewrite rules configured on physical and logical interfaces:
ge-0/1/0 {
unit 0 {
rewrite-rules {
exp custom-exp;
}
}
classifiers {
dscp d1;
ieee-802.1 ci;
}
rewrite-rules {
dscp default;
}
}
ge-0/1/2 {
classifiers {
ieee-802.1 ci;
}
rewrite-rules {
ieee-802.1 ri;
}
}
ge-0/1/3 {
unit 0 {
rewrite-rules {
exp custom-exp2;
}
}
}
ge-0/1/7 {
classifiers {
dscp d1;
}
}
ge-0/1/8 {
classifiers {
dscp d1;
}
}
Rewrite Rules on ACX7000 Series Routers
ACX7000 Series routers do not support rewrite functionality on ethernet-bridge and ethernet-ccc encapsulation. For rewrite rules to work on an ACX7000 Series router, the router always needs tagged packets to be present, and the logical interface must be VLAN aware. For example, only packet forwarding will work with the following configuration:
[edit] set interfaces et-0/0/6 encapsulation ethernet-ccc set interfaces et-0/0/6 unit 0 family ccc
For both forwarding and rewrite to work on a logical interface, use the following configuration:
[edit] set interfaces et-0/0/0 flexible-vlan-tagging set interfaces et-0/0/0 encapsulation flexible-ethernet-services set interfaces et-0/0/0 unit 0 encapsulation vlan-ccc set interfaces et-0/0/0 unit 0 vlan-id-list [1-4094] set interfaces et-0/0/0 unit 0 family ccc