Configuring QoS mapping between IP packets and MPLS through an LSP

Configure CoS value for the LSP for QoS mapping between IP packet and MPLS through an LSP.

The CoS value is applied to the CoS (EXP) field in the MPLS header of all packets entering the LSP. These packets traveling through an LSP are treated with the same priority as they travel the MPLS domain.
  1. In privileged EXEC mode, enter global configuration mode.
    device# configure terminal
    
  2. Enter router MPLS mode.
    device(config)# router mpls
  3. Enter LSP mode to configure the LSP tunnel.
    device(config-router-mpls)# lsp tunnel4
  4. If the tunnel is enabled, disable it before changing its configuration.
    device(config-router-mpls-lsp-tunnel4)# no enable
  5. Configure the CoS value for all packets traveling through the tunnel 4 LSP.
    device(config-router-mpls-lsp-tunnel4)# cos 7
    In this example, the CoS value is set to 7. You can set a value from 0 to 7. CoS does not have a default setting.
  6. Enable the LSP tunnel.
    device(config-router-mpls-lsp-tunnel4)# enable
    

Example

The following configuration shows the steps in the previous configuration of the CoS value in the tunnel4 LSP.

device# configure terminal
device(config)# router mpls
device(config-router-mpls)# lsp tunnel4
device(config-router-mpls-lsp-tunnel4)# no enable
device(config-router-mpls-lsp-tunnel4)# cos 7
device(config-router-mpls-lsp-tunnel4)# enable