- play_arrow Overview
- play_arrow Understanding How Class of Service Manages Congestion and Defines Traffic Forwarding Behavior
- Understanding How Class of Service Manages Congestion and Controls Service Levels in the Network
- How CoS Applies to Packet Flow Across a Network
- The Junos OS CoS Components Used to Manage Congestion and Control Service Levels
- Mapping CoS Component Inputs to Outputs
- Default Junos OS CoS Settings
- Packet Flow Through the Junos OS CoS Process Overview
- Configuring Basic Packet Flow Through the Junos OS CoS Process
- Example: Classifying All Traffic from a Remote Device by Configuring Fixed Interface-Based Classification
- Interface Types That Do Not Support Junos OS CoS
-
- play_arrow Configuring Class of Service
- play_arrow Assigning Service Levels with Behavior Aggregate Classifiers
- Understanding How Behavior Aggregate Classifiers Prioritize Trusted Traffic
- Default IP Precedence Classifier
- Default DSCP and DSCP IPv6 Classifiers
- Default MPLS EXP Classifier
- Default IEEE 802.1p Classifier
- Default IEEE 802.1ad Classifier
- Default Aliases for CoS Value Bit Patterns Overview
- Defining Aliases for CoS Value Bit Patterns
- Configuring Behavior Aggregate Classifiers
- Applying Behavior Aggregate Classifiers to Logical Interfaces
- Example: Configuring and Applying a Default DSCP Behavior Aggregate Classifier
- Example: Configuring Behavior Aggregate Classifiers
- Understanding DSCP Classification for VPLS
- Example: Configuring DSCP Classification for VPLS
- Configuring Class of Service for MPLS LSPs
- Applying DSCP Classifiers to MPLS Traffic
- Applying MPLS EXP Classifiers to Routing Instances
- Applying MPLS EXP Classifiers for Explicit-Null Labels
- Manage Ingress Oversubscription with Traffic Class Maps
- play_arrow Assigning Service Levels with Multifield Classifiers
- Overview of Assigning Service Levels to Packets Based on Multiple Packet Header Fields
- Configuring Multifield Classifiers
- Using Multifield Classifiers to Set Packet Loss Priority
- Example: Configuring and Applying a Firewall Filter for a Multifield Classifier
- Example: Classifying Packets Based on Their Destination Address
- Example: Configuring and Verifying a Complex Multifield Filter
- play_arrow Controlling Network Access with Traffic Policing
- Controlling Network Access Using Traffic Policing Overview
- Effect of Two-Color Policers on Shaping Rate Changes
- Configuring Policers Based on Logical Interface Bandwidth
- Example: Limiting Inbound Traffic at Your Network Border by Configuring an Ingress Single-Rate Two-Color Policer
- Example: Performing CoS at an Egress Network Boundary by Configuring an Egress Single-Rate Two-Color Policer
- Example: Limiting Inbound Traffic Within Your Network by Configuring an Ingress Single-Rate Two-Color Policer and Configuring Multifield Classifiers
- Example: Limiting Outbound Traffic Within Your Network by Configuring an Egress Single-Rate Two-Color Policer and Configuring Multifield Classifiers
- Overview of Tricolor Marking Architecture
- Enabling Tricolor Marking and Limitations of Three-Color Policers
- Configuring and Applying Tricolor Marking Policers
- Configuring Single-Rate Tricolor Marking
- Configuring Two-Rate Tricolor Marking
- Example: Configuring and Verifying Two-Rate Tricolor Marking
- Applying Firewall Filter Tricolor Marking Policers to Interfaces
- Policer Overhead to Account for Rate Shaping in the Traffic Manager
- play_arrow Defining Forwarding Behavior with Forwarding Classes
- Understanding How Forwarding Classes Assign Classes to Output Queues
- Default Forwarding Classes
- Configuring a Custom Forwarding Class for Each Queue
- Configuring Up to 16 Custom Forwarding Classes
- Classifying Packets by Egress Interface
- Forwarding Policy Options Overview
- Configuring CoS-Based Forwarding
- Example: Configuring CoS-Based Forwarding
- Example: Configuring CoS-Based Forwarding for Different Traffic Types
- Example: Configuring CoS-Based Forwarding for IPv6
- Applying Forwarding Classes to Interfaces
- Understanding Queuing and Marking of Host Outbound Traffic
- Forwarding Classes and Fabric Priority Queues
- Default Routing Engine Protocol Queue Assignments
- Assigning Forwarding Class and DSCP Value for Routing Engine-Generated Traffic
- Example: Writing Different DSCP and EXP Values in MPLS-Tagged IP Packets
- Change the Default Queuing and Marking of Host Outbound Traffic
- Example: Configure Different Queuing and Marking Defaults for Outbound Routing Engine and Distributed Protocol Handler Traffic
- Overriding the Input Classification
- play_arrow Defining Output Queue Properties with Schedulers
- How Schedulers Define Output Queue Properties
- Default Schedulers Overview
- Configuring Schedulers
- Configuring Scheduler Maps
- Applying Scheduler Maps Overview
- Applying Scheduler Maps to Physical Interfaces
- Configuring Traffic Control Profiles for Shared Scheduling and Shaping
- Configuring an Input Scheduler on an Interface
- Understanding Interface Sets
- Configuring Interface Sets
- Interface Set Caveats
- Configuring Internal Scheduler Nodes
- Example: Configuring and Applying Scheduler Maps
- play_arrow Controlling Bandwidth with Scheduler Rates
- Oversubscribing Interface Bandwidth
- Configuring Scheduler Transmission Rate
- Providing a Guaranteed Minimum Rate
- PIR-Only and CIR Mode
- Excess Rate and Excess Priority Configuration Examples
- Controlling Remaining Traffic
- Bandwidth Sharing on Nonqueuing Packet Forwarding Engines Overview
- Configuring Rate Limits on Nonqueuing Packet Forwarding Engines
- Applying Scheduler Maps and Shaping Rate to DLCIs and VLANs
- Example: Applying Scheduler Maps and Shaping Rate to DLCIs
- Example: Applying Scheduling and Shaping to VLANs
- Applying a Shaping Rate to Physical Interfaces Overview
- Configuring the Shaping Rate for Physical Interfaces
- Example: Limiting Egress Traffic on an Interface Using Port Shaping for CoS
- Configuring Input Shaping Rates for Both Physical and Logical Interfaces
- play_arrow Setting Transmission Order with Scheduler Priorities and Hierarchical Scheduling
- Priority Scheduling Overview
- Configuring Schedulers for Priority Scheduling
- Associating Schedulers with Fabric Priorities
- Hierarchical Class of Service Overview
- Hierarchical Class of Service Network Scenarios
- Understanding Hierarchical Scheduling
- Priority Propagation in Hierarchical Scheduling
- Hierarchical CoS for Metro Ethernet Environments
- Hierarchical Schedulers and Traffic Control Profiles
- Example: Building a Four-Level Hierarchy of Schedulers
- Hierarchical Class of Service for Network Slicing
- Configuring Ingress Hierarchical CoS
- play_arrow Controlling Congestion with Scheduler RED Drop Profiles, Buffers, PFC, and ECN
- RED Drop Profiles for Congestion Management
- Determining Packet Drop Behavior by Configuring Drop Profile Maps for Schedulers
- Managing Congestion by Setting Packet Loss Priority for Different Traffic Flows
- Mapping PLP to RED Drop Profiles
- Managing Congestion on the Egress Interface by Configuring the Scheduler Buffer Size
- Managing Transient Traffic Bursts by Configuring Weighted RED Buffer Occupancy
- Example: Managing Transient Traffic Bursts by Configuring Weighted RED Buffer Occupancy
- Understanding PFC Using DSCP at Layer 3 for Untagged Traffic
- Configuring DSCP-based PFC for Layer 3 Untagged Traffic
- PFC Watchdog
- CoS Explicit Congestion Notification
- Example: Configuring Static and Dynamic ECN
- play_arrow Altering Outgoing Packet Headers Using Rewrite Rules
- Rewriting Packet Headers to Ensure Forwarding Behavior
- Applying Default Rewrite Rules
- Configuring Rewrite Rules
- Configuring Rewrite Rules Based on PLP
- Applying IEEE 802.1p Rewrite Rules to Dual VLAN Tags
- Applying IEEE 802.1ad Rewrite Rules to Dual VLAN Tags
- Rewriting IEEE 802.1p Packet Headers with an MPLS EXP Value
- Setting IPv6 DSCP and MPLS EXP Values Independently
- Configuring DSCP Values for IPv6 Packets Entering the MPLS Tunnel
- Setting Ingress DSCP Bits for Multicast Traffic over Layer 3 VPNs
- Applying Rewrite Rules to Output Logical Interfaces
- Rewriting MPLS and IPv4 Packet Headers
- Rewriting the EXP Bits of All Three Labels of an Outgoing Packet
- Defining a Custom Frame Relay Loss Priority Map
- Example: Per-Node Rewriting of EXP Bits
- Example: Rewriting CoS Information at the Network Border to Enforce CoS Strategies
- Example: Remarking Diffserv Code Points to MPLS EXPs to Carry CoS Profiles Across a Service Provider’s L3VPN MPLS Network
- Example: Remarking Diffserv Code Points to 802.1P PCPs to Carry CoS Profiles Across a Service Provider’s VPLS Network
- Assigning Rewrite Rules on a Per-Customer Basis Using Policy Maps
- Host Outbound Traffic IEEE802.1p Rewrite
- play_arrow Altering Class of Service Values in Packets Exiting the Network Using IPv6 DiffServ
- Resources for CoS with DiffServ for IPv6
- System Requirements for CoS with DiffServ for IPv6
- Terms and Acronyms for CoS with DiffServ for IPv6
- Default DSCP Mappings
- Default Forwarding Classes
- Juniper Networks Default Forwarding Classes
- Roadmap for Configuring CoS with IPv6 DiffServ
- Configuring a Firewall Filter for an MF Classifier on Customer Interfaces
- Applying the Firewall Filter to Customer Interfaces
- Assigning Forwarding Classes to Output Queues
- Configuring Rewrite Rules
- DSCP IPv6 Rewrites and Forwarding Class Maps
- Applying Rewrite Rules to an Interface
- Configuring RED Drop Profiles
- Configuring BA Classifiers
- Applying a BA Classifier to an Interface
- Configuring a Scheduler
- Configuring Scheduler Maps
- Applying a Scheduler Map to an Interface
- Example: Configuring DiffServ for IPv6
-
- play_arrow Configuring Platform-Specific Functionality
- play_arrow Configuring Class of Service on ACX Series Universal Metro Routers
- CoS on ACX Series Routers Features Overview
- Understanding CoS CLI Configuration Statements on ACX Series Routers
- DSCP Propagation and Default CoS on ACX Series Routers
- Configuring CoS on ACX Series Routers
- Classifiers and Rewrite Rules at the Global, Physical, and Logical Interface Levels Overview
- Configuring Classifiers and Rewrite Rules at the Global and Physical Interface Levels
- Applying DSCP and DSCP IPv6 Classifiers on ACX Series Routers
- Schedulers Overview for ACX Series Routers
- Shared and Dedicated Buffer Memory Pools on ACX Series Routers
- CoS for PPP and MLPPP Interfaces on ACX Series Routers
- CoS for NAT Services on ACX Series Routers
- Hierarchical Class of Service in ACX Series Routers
- Storm Control on ACX Series Routers Overview
- play_arrow Configuring Class of Service on MX Series 5G Universal Routing Platforms
- Junos CoS on MX Series 5G Universal Routing Platforms Overview
- CoS Features and Limitations on MX Series Routers
- Configuring and Applying IEEE 802.1ad Classifiers
- Scheduling and Shaping in Hierarchical CoS Queues for Traffic Routed to GRE Tunnels
- Example: Performing Output Scheduling and Shaping in Hierarchical CoS Queues for Traffic Routed to GRE Tunnels
- CoS-Based Interface Counters for IPv4 or IPv6 Aggregate on Layer 2
- Enabling a Timestamp for Ingress and Egress Queue Packets
- play_arrow Configuring Class of Service on PTX Series Packet Transport Routers
- CoS Features and Limitations on PTX Series Routers
- CoS Feature Differences Between PTX Series Packet Transport Routers and T Series Routers
- Understanding Scheduling on PTX Series Routers
- Virtual Output Queues on PTX Series Packet Transport Routers
- Example: Configuring Excess Rate for PTX Series Packet Transport Routers
- Identifying the Source of RED Dropped Packets on PTX Series Routers
- Configuring Queuing and Shaping on Logical Interfaces on PTX Series Routers
- Example: Configuring Queuing and Shaping on Logical Interfaces in PTX Series Packet Transport Routers
- Example: Configuring Strict-Priority Scheduling on a PTX Series Router
- CoS Support on EVPN VXLANs
- Understanding CoS CLI Configuration Statements on PTX Series Routers
- Classification Based on Outer Header of Decapsulation Tunnel
-
- play_arrow Configuration Statements and Operational Commands
Example: Configuring Scheduling Modes on Aggregated Interfaces
You can configure class-of-service parameters, such as queuing
or shaping parameters on aggregated interfaces, in either link-protect
or non-link-protect mode. You can configure these parameters for per-unit
schedulers, hierarchical schedulers, or shaping at the physical and
logical interface level. You can control the way these parameters
are applied by configuring the aggregated interface to operate in scale
or replicate
mode.
You can apply these parameters on the following routers:
MX Series router interfaces on EQ DPCs
MX Series router interfaces on MICs or MPCs through Junos OS Release 10.2 (non-link-protect mode only)
M120 or M320 routers
T Series router interfaces on IQ2 PICs
PTX Series Packet Transport Routers
You can configure the applied parameters for aggregated interfaces operating in non-link-protected mode. In link-protected mode, only one link in the bundle is active at a time (the other link is a backup link) so schedulers cannot be scaled or replicated. In non-link-protected mode, all the links in the bundle are active and send traffic; however, there is no backup link. If a link fails or is added to the bundle in non-link-protected mode, the links’ traffic is redistributed among the active links.
To set the scheduling mode for aggregated interfaces, include
the scale
or replicate
option of the member-link-scheduler
statement at the [edit class-of-service interfaces aen]
hierarchy level, where n is the configured number of the interface:
[edit class-of-service interfaces aen] member-link-scheduler (replicate | scale);
By default, if you do not include the member-link-scheduler
statement, scheduler parameters are applied to the member links
in the scale
mode (also called “equal division mode”).
The aggregated Ethernet interfaces are otherwise configured as usual. For more information on configuring aggregated Ethernet interfaces, see the Junos OS Network Interfaces Library for Routing Devices.
The following examples set scale
mode on the ae0
interface and replicate
mode on the ae1
interface.
[edit class-of-service] interfaces ae0 { member-link-scheduler scale; } [edit class-of-service] interfaces ae1 { member-link-scheduler replicate; }
The member-link-scheduler
statement only appears
for aggregated interfaces. You configure this statement for aggregated
interfaces in non-link-protected mode. For more information about
link protection modes, see the Network Interfaces Configuration
Guide.
Aggregated interfaces support both hierarchical and per-unit schedulers.
The traffic-control-profiles
statement is not
supported for PTX Series Packet Transport Routers.
When interface parameters are using the scale
option of the member-link-scheduler
statement, the following
parameters under the [edit class-of-service traffic-control-profiles traffic-control-profile-name]
configuration are
scaled on egress when hierarchical schedulers are configured:
shaping-rate
(PIR)guaranteed-rate
(CIR)delay–buffer-rate
When interface parameters are using the scale
option of the member-link-scheduler
statement, the following
parameters under the [edit class-of-service schedulers scheduler-name]
configuration are scaled on egress
when per-unit schedulers are configured:
transmit-rate
buffer-size
You cannot apply a hierarchical scheduler at the interface
set level for an ae
interface. (Interface sets cannot be
configured under an ae
interface.)
The following configuration parameters are not supported
on ae
interfaces in non-link-protection mode:
Input scheduler maps
Input traffic control profiles
Input shaping rates
The following configuration conventions are also not supported:
Scaling of the
input-traffic-control-profile-remaining
statement.The
scheduler-map-chassis
statement and thederived
option for theae
interface. Chassis scheduler maps should be applied under the physical interfaces.Dynamic and demux interfaces are not supported as part of the
ae
bundle.
Depending on the whether the scale
or replicate
option is configured, the member-link-scheduler
statement
operates in either scaled mode (also called “equal division
mode”) or replicated mode, respectively.
In scaled mode, a VLAN can have multiple flows that can be sent
over multiple member links of the ae
interface. Likewise,
a member link can receive traffic from any VLAN in the ae
bundle. In scaled mode, the physical interface bandwidth is divided
equally among all member links of the ae
bundle.
In scaled mode, the following scheduler parameter values are divided equally among the member links:
When the parameters are configured using traffic control profiles, then the parameters scaled are the shaping rate, guaranteed rate, and delay buffer rate.
When the parameters are configured using scheduler maps, then the parameters scaled are the transmit rate and buffer size. Shaping rate is also scaled if you configure it in bits per second (bps). Shaping rate is not scaled if you configure it as a percentage of the available interface bandwidth.
For example, consider an ae
bundle between routers
R1 and R2 consisting of three links. These are ge-0/0/1
, ge-0/0/2
and ge-0/0/3
(ae0
) on
R1; and ge-1/0/0
, ge-1/0/1
, and ge-1/0/2
(ae2
) on R2. Two logical interfaces (units) are also
configured on the ae0
bundle on R1: ae0.0
and ae0.1
.
On ae0
, traffic control profiles on R1 are
configured as follows:
ae0
(the physical interface level) has a PIR of 450 Mbps.ae0.0
(VLAN 100 at the logical interface level) has a PIR of 150 Mbps and a CIR of 90 Mbps.ae0.1
(VLAN 200 at the logical interface level) has a PIR of 90 Mbps and a CIR of 60 Mbps.
In scaled mode, the ae0
PIR is first divided among
the member physical interfaces. Because there are three members, each
receives 450 / 3 = 150 Mbps as a derived value. So the scaled PIR
for the members interfaces is 150 Mbps each.
However, there are also two logical interfaces (ae0.0
and ae0.1
) and VLANs (100 and 200) on ae0
.
Traffic can leave on any of the three physical interfaces (ge-0/0/1
, ge-0/0/2
, or ge-0/0/3
) in the bundle. Therefore,
two derived logical interfaces are added to the member links to represent
the two VLANs.
There are now six logical interfaces on the physical
interfaces of the links making up the ae
bundle, one set
for VLAN 100 and the other for VLAN 200:
ge-0/0/1.0
andge-0/0/1.1
ge-0/0/2.0
andge-0/0/2.1
ge-0/0/3.0
andge-0/0/3.1
The traffic control profile parameters configured on ae0.0
are divided across all the underlying logical interfaces (the unit
0s). In the same way, the traffic control profile parameters configured
on ae0.1
are divided across all the underlying logical
interfaces (the unit 1s).
Therefore, the derived values of the scaled parameters on the interfaces are:
For
ge-0/0/1.0
andge-0/0/2.0
andge-0/0/3.0
, each CIR = 90 / 3 = 30 Mbps, and each PIR = 150 / 3 = 50 Mbps.For
ge-0/0/1.1
andge-0/0/2.1
andge-0/0/3.1
, each CIR = 60 / 3 = 20 Mbps, and each PIR = 90 / 3 = 30 Mbps.
The scaled values are shown in Figure 1.

In scaled mode, when a new member link is added to the bundle, or an existing member link is either removed or fails, then the scaling factor (based on the number of active links) is recomputed and the new scheduler or traffic control profile parameters are reassigned. Only the PIR, CIR, and buffer parameters are recomputed: all other parameters are simply copied at each level.
In show class-of-service scheduler-map
commands,
values derived in scaled mode instead of explicitly configured are
flagged with &**sf**n
suffix,
where n indicates the value of the scaling factor.
The following sample shows the output for the scheduler
map named smap-all-abs
with and without a scaling factor:
user@host> show class-of-service scheduler-map Scheduler map: smap-all-abs, Index: 65452 Scheduler: q0_sch_abs, Forwarding class: be, Index: 6775 Transmit rate: 40000000 bps, Rate Limit: none, Buffer size: remainder, Priority: low Excess Priority: unspecified Drop profiles: Loss priority Protocol Index Name Low any 1 <default-drop-profile> Medium low any 1 <default-drop-profile> Medium high any 1 <default-drop-profile> High any 1 <default-drop-profile> user@host> show class-of-service scheduler-map Scheduler map: smap-all-abs, Index: 65452 Scheduler: q0_sch_abs&**sf**3, Forwarding class: be, Index: 2128 Transmit rate: 13333333 bps, Rate Limit: none, Buffer size: remainder, Priority: low Excess Priority: unspecified Drop profiles: Loss priority Protocol Index Name Low any 1 <default-drop-profile> Medium low any 1 <default-drop-profile> Medium high any 1 <default-drop-profile> High any 1 <default—drop—profile>
There can be multiple scheduler maps created with different
scaling factors, depending on when the child interfaces come up. For
example, if there are only two active children on a parent interface,
a new scheduler map with a scaling factor of 2 is created. The scheduler
map name is smap-all-abs&**sf**2
.
In replicated mode, in contrast to scaled mode, the configured
scheduler parameters are simply replicated, not divided, among all
member links of the ae
bundle.
In replicated mode, the following scheduler parameter values are replicated among the member links and logical interfaces:
When the parameters are configured using traffic control profiles, then the parameters replicated are the shaping rate, guaranteed rate, and delay buffer rate.
When the parameters are configured using scheduler maps, then the parameters replicated are the transmit rate and buffer size.
If the scheduler parameters in the example configuration
between routers R1 and R2 are applied with the member-link-scheduler
replicate
statement and option, the following parameters are
applied:
The
ae0
PIR is copied among the member physical interfaces. Each receives 450 Mbps as a PIR.For each logical interface unit
.0
, the configured PIR and CIR forae0.0
is replicated (copied). Each logical interface unit.0
receives a PIR of 150 Mbps and a CIR of 90 Mbps.For each logical interface unit
.1
, the configured PIR and CIR forae0.1
is replicated (copied). Each logical interface unit.1
receives a PIR of 90 Mbps and a CIR of 60 Mbps.
The replicated values are shown in Figure 2.

In replicated mode, when a new member link is added to the bundle, or an existing member link is either removed or fails, the values are either copied or deleted from the required levels.