- Table of Contents
- Related Documents
-
Title | Size | Download |
---|---|---|
03-MPLS QoS configuration | 66.81 KB |
Configuring MPLS priority marking
Configuring the MPLS DiffServ mode
Appendix A Default priority maps
Configuring MPLS QoS
About MPLS QoS
MPLS uses 3 bits, called EXP bits, to carry class-of-service information to provide support for DiffServ. MPLS QoS identifies different traffic flows with different EXP bits and implements differentiated services.
MPLS QoS supports CAR and priority marking. MPLS QoS classifies traffic on the PE and apply differentiated QoS strategies for different traffic classes. For example, MPLS QoS can organize packets with EXP value 1 into a class and packets with EXP value 2 into another class. Then it performs traffic policing and priority marking for each class of packets.
An MPLS label is encapsulated between the Layer 2 header and Layer 3 header of a packet. Multiple MPLS labels are supported, which are referred to as a label stack. If there are m labels between the Layer 2 header and Layer 3 header, the label closest to the Layer 2 header is called the first label (top label). The label closest to the Layer 3 header is called the mth label (bottom label).
Configuring MPLS priority marking
About this task
In an MPLS network, you can adjust the priority of an MPLS traffic flow by marking its EXP value. For more information about priority marking, see "Configuring priority marking."
Restrictions and guidelines
The remark imposition-mpls-exp command takes effect only when the QoS policy is applied to the inbound direction. On a P device, this command modifies only the EXP value in the first label. On a PE device, this command modifies the EXP values in all labels.
The remark mpls-exp command modifies the EXP values in all labels when the QoS policy is applied to the inbound direction.
The remark mpls-exp command modifies only the EXP value in the first label when the QoS policy is applied to the outbound direction.
Procedure
1. Enter system view.
system-view
2. Define a traffic class.
a. Create a traffic class and enter traffic class view.
traffic classifier classifier-name [ operator { and | or } ]
b. Configure match criteria for the traffic class.
- if-match mpls-exp exp-value&<1-8>
By default, no match criteria are configured.
The match criteria apply only to MPLS packets.
c. Return to system view.
quit
3. Define a traffic behavior.
a. Create a traffic behavior and enter traffic behavior view.
traffic behavior behavior-name
b. Configure an EXP marking action in the traffic behavior.
- remark mpls-exp exp-value
- remark imposition-mpls-exp exp-value
By default, no EXP marking action is configured.
c. Return to system view.
quit
4. Define a QoS policy r.
a. Create a QoS policy and enter QoS policy view.
qos policy policy-name
b. Associate the traffic class with the traffic behavior in the QoS policy.
classifier classifier-name behavior behavior-name
By default, no traffic behavior is associated with a traffic class.
c. Return to system view.
quit
5. Apply the QoS policy.
For more information, see "Configuring a QoS policy."
Configuring the MPLS DiffServ mode
About this task
In a DiffServ architecture, an intermediate node can modify the IP precedence, DSCP, and EXP fields, which are collectively referred to as class of service (CoS). Therefore, the CoS value of a packet might change during transmission in an IP network or MPLS network. The device supports the following MPLS DiffServ modes to process CoS:
· pipe—When an IP packet enters an MPLS network, the ingress node ignores the IP precedence or DSCP value of the IP packet and uses the configured value as the EXP value of the MPLS packet. When the MPLS packet leaves the MPLS network, the egress node does not modify the original IP precedence or DSCP value. In the MPLS network, the packet is scheduled based on the configured EXP value.
· short-pipe—When an IP packet enters and leaves an MPLS network, the packet is processed in the same way as in pipe mode.
¡ On nodes from the ingress node to the penultimate node, the packet is scheduled based on the configured EXP value.
¡ On the egress node, the top label is popped, and then the packet is scheduled based on its IP precedence or DSCP value.
· uniform
¡ For a L2VPN:
- If the ingress node is configured with the qos trust command on an AC interface, it maps the trusted priority of the incoming IP packet to the EXP value of the MPLS packet.
- If the ingress node is not configured with the qos trust command on the AC interface, the ingress node maps the 802.1p priority of the IP packet to the EXP value of the MPLS packet. If the IP packet does not have VLAN tags, the EXP value will be 0. When the MPLS packet leaves the MPLS network, the ingress node maps the EXP value to the 802.1p priority. If the MPLS packet does not have VLAN tags, the ingress node performs no mapping.
¡ For a L3VPN, when an IP packet enters an MPLS network, the ingress node maps the IP precedence or DSCP value of the IP packet to the EXP value of the MPLS packet. When the MPLS packet leaves the MPLS network, the ingress node maps the EXP value to the IP precedence or DSCP value.
Restrictions and guidelines
Mappings between IP precedence or DSCP and EXP are performed according to the IP precedence-exp map, dscp-exp map, and exp-dscp map. For more information about these priorities and maps, see "Configuring priority mapping." For information about the default mappings of these maps, see "Appendixes
Appendix A Default priority maps."
Procedure
1. Enter system view.
system-view
2. Enter one of the following views:
¡ Enter VPN instance view.
ip vpn-instance vpn-instance-name
¡ Enter VSI view.
vsi vsi-name
¡ Execute the following commands in sequence to enter the view of a cross-connect.
xconnect-group group-name
connection connection-name
3. Configure the MPLS DiffServ mode.
diffserv-mode { ingress { pipe service-class | short-pipe service-class | uniform } egress { pipe | short-pipe | uniform } | { pipe service-class | short-pipe service-class | uniform } }
The default MPLS DiffServ mode is uniform.
Appendixes
Appendix A Default priority maps
Table 1 Default dscp-exp priority map
DSCP values |
EXP value |
dscp |
exp |
0 to 7 |
0 |
8 to 15 |
1 |
16 to 23 |
2 |
24 to 31 |
3 |
32 to 39 |
4 |
40 to 47 |
5 |
48 to 55 |
6 |
56 to 63 |
7 |
Table 2 Default exp-dscp map
EXP value |
DSCP value |
0 |
0 |
1 |
8 |
2 |
16 |
3 |
24 |
4 |
32 |
5 |
40 |
6 |
48 |
7 |
56 |
Table 3 Default ippre-exp priority map
IP precedence |
EXP value |
0 |
0 |
1 |
1 |
2 |
2 |
3 |
3 |
4 |
4 |
5 |
5 |
6 |
6 |
7 |
7 |