Defining CoS Rewrite Rules (CLI Procedure)
You configure rewrite rules to alter CoS values in outgoing packets on the outbound interfaces of an EX-series switch to match the policies of a targeted peer. Policy matching allows the downstream router in a neighboring network to classify each packet into the appropriate service group.
In addition, you often need to rewrite a given marker such as IP precedence, DSCP, or IEEE 802.1p at the switch's inbound interfaces to accommodate behavior aggregate (BA) classification by core devices.
You do not need to explicitly apply rewrite rules to interfaces. By default, rewrite rules are applied to routed packets.
To configure CoS rewrite rules, associate the rewrite rule (customup-rw) with forwarding class, loss priority, and code point:
[edit class-of-service rewrite-rules]
user@switch# set ieee-802.1 customup-rw forwarding-class
be loss-priority low code-point 000
user@switch# set ieee-802.1 customup-rw forwarding-class be loss-priority high
code-point 001
user@switch# set ieee-802.1 customup-rw forwarding-class af loss-priority low
code-point 010
user@switch# set ieee-802.1 customup-rw forwarding-class af loss-priority high
code-point 011
user@switch# set ieee-802.1 customup-rw forwarding-class ef loss-priority low
code-point 100
user@switch# set ieee-802.1 customup-rw forwarding-class ef loss-priority high
code-point 101
user@switch# set ieee-802.1 customup-rw forwarding-class nc loss-priority low
code-point 110
user@switch# set ieee-802.1 customup-rw forwarding-class nc loss-priority high
code-point 111
