18. Access Ingress QoS Policies for 7210 SAS-Mxp

18.1. In This Chapter

This chapter provides information about configuring access ingress QoS policies using the command line interface.

18.2. Overview

An access ingress QoS policy is applied to the physical port instead of the SAP. It applies to all SAPs configured on the specific access port. To configure a port-based access ingress QoS policy, the access-ingress-qos-mode command must be configured with the port-mode option specified.

Note:

Refer to the 7210 SAS-M, T, R6, R12, Mxp, Sx, S Interface Configuration Guide for more information about the access-ingress-qos-mode command.

At ingress, the access ingress QoS policy uses dot1p, DEI with dot1p, or IP DSCP values to assign a forwarding class and profile to traffic, which facilitates the classification of traffic received on the access port. The user can assign a profile using DEI configured with a dot1p classification policy. The forwarding class is associated with meters or policers at ingress. The FC meters for unicast and multicast traffic and meter characteristics (for example, the CIR and PIR) are defined in the policy.

An access ingress QoS policy supports the definition of up to one (1) meter per forwarding class for unicast traffic, and up to one (1) meter per forwarding class for multipoint traffic (that is, broadcast, multicast, and unknown-unicast) for multipoint services. The definition of a maximum of 16 meters per access ingress QoS policy is supported.

For VPLS, the following four forwarding types (not to be confused with forwarding classes) are supported: unicast, multicast, broadcast, and unknown. The multicast, broadcast, and unknown traffic types are flooded to all destinations in the service and use the multipoint meter associated with the forwarding class. The unicast traffic type is handled in a point-to-point manner in the service and uses the unicast meter associated with the forwarding class.

Note:

An access ingress policy is supported only when the node is configured to operate in the high SAP scale mode using the configure system resource-profile sap-scale-mode high command.

Refer to the 7210 SAS-M, T, Mxp, Sx, S Services Guide for more information about high SAP scale mode.

Refer to the 7210 SAS-M, T, R6, R12, Mxp, Sx, S Basic System Configuration Guide for more information about the sap-scale-mode command.

18.2.1. Resource Allocation for Access Ingress QoS Policies

This section describes the allocation of QoS resources from the CAM pool allocated to the policy to access ingress QoS policies using the configure system resource-profile ingr-internal-tcam qos-access-port-ingress-resource command.

For every FC in use, the system allocates two (2) classification entries from the qos-access-port-ingress-resource CAM pool: one entry for the unicast meter and one for the multicast meter. Regardless of the number of dot1p entries in the dot1p classification policy and IP DSCP entries in the DSCP classification policy that map to a specific FC name, a maximum of two (2) entries are required for the FC. That is, if the user defines a dot1p classification policy with all seven (7) dot1p values mapped to FC af, FC af needs only two (2) classification entries in the CAM. An FC is considered to be in use if a dot1p classification entry, DSCP classification entry, or the default FC is mapped to the FC name.

For every meter or policer in use, the system allocates one meter in the hardware. A meter or policer is considered to be in use when it is associated with an FC that is in use.

The number of access ports that can be configured in access-ingress-qos-mode port-mode is limited by the number of classification resources available in the hardware and the number of access ports supported by the system.

18.2.1.1. Use of Index File for Access Ingress QoS Policies

7210 SAS platforms use an index file to store the map that indicates the QoS resource allocation to access ports. After a reboot, the file is used to ensure appropriate resource allocation for all access ports that were using the access ingress policy before the reboot. In the absence of an index file, access ports that were configured successfully before the reboot may fail after the reboot. After the configuration file is saved, the index file is stored in flash memory. On system reboot, if the file is found, the system allocates resources as indicated in the stored map. If the file is not found, the system implements a best-fit algorithm and attempts to allocate resources for all access ports on a first-come-first-served basis. If the file is not found after reboot, the saved configuration may not execute successfully because resources may not be allocated to all access ports.

Note:

The index file used for the QoS map is different from the file used for storing interface indexes.

18.2.1.2. Calculating the Number of QoS Resources

To calculate the number of QoS resources used by a port-based access ingress QoS policy, the user must determine the number of FCs to use.

Only the FCs used by the match criteria classification entries configured in the dot1p and DSCP classification policies, which are referred to as “FCs in use,” are considered to calculate the number of FCs.

Default unicast meter 1 and default mulitpoint meter 9, which are created by default when a new policy is created, cannot be deleted. Unless the user explicitly configures another unicast meter or multicast meter for the FCs, the default unicast meter 1 is used for all unicast traffic and default mulitpoint meter 9 is used for all multipoint traffic (that is, broadcast, multicast, and unknown-unicast).

Use the following rules to compute the number of classification entries per FC in use.

  1. If an FC is in use and is created without explicit meters, use default meter 1 for unicast traffic and default meter 9 for all other traffic (that is, broadcast, multicast, and unknown-unicast). The FC requires two (2) classification entries in the hardware.
  2. If an FC is in use and is created with an explicit unicast meter, use the unicast meter for unicast traffic and default meter 9 for all other traffic. The FC requires two (2) classification entries in the hardware.
  3. If an FC is in use and is created with an explicit unicast meter and an explicit multicast meter, use the unicast meter for unicast traffic and the multicast meter for all other traffic. The FC requires two (2) classification entries in the hardware.
  4. Two (2) classification entries are used for the default fc-name configured using the config qos access-ingress default-fc command. The entries for the default FC are in addition to the FCs configured in the dot1p and DSCP classification policies.

Using the number of match criteria and FCs in use, calculate the total number of classification entries per policy with the following formula.

TC = ∑ 2 * E(i) + 2

i = nc, h1, ef, h2, l1, af, l2, be

where:

  1. TC is the total number of classification entries per policy
  2. E(i) is the number of match criteria entries that classify packets to FCi. E(i) is one (1) if there is a dot1p or DSCP classification entry that classifies packets to FCi; itherwise, E(i) is zero (0).
  3. the number is multiplied by two (2) for the number of classification entries that FCi requires
  4. another two (2) entries are added for the default FC

18.2.1.3. Calculating the Number of Meters or Policers

The total number of policers (TP) used is the number of meters configured in the policy. From the meters configured in the policy, only meters configured for use with an FC are counted for resource allocation. That is, meters that are created but not associated with an FC are not counted for resource allocation. A maximum of 16 meters are available per access ingress QoS policy.

18.2.1.4. Determining the Number of Resources Allocated to the Policy

The user must determine the value for the config qos access-ingress num-qos-classifiers command using the following formula.

max (TC, TP)

See sections 18.2.1.2 and 18.2.1.3 for information about determining the values for TC and TP respectively.

18.2.1.5. Example of Access Ingress QoS Policy Resource Calculations

The following sections describe example calculations for an access ingress QoS policy.

18.2.1.5.1. Example 1

The following output example shows the FC mapping in a configured dot1p classification policy, in which the FC is using the default meters (meter 1 for unicast and meter 9 for multicast).

configure> qos> dot1p-classification 10
dot1p 7 fc nc
dot1p 6 fc nc
default-dot1p-fc be profile out
exit
configure> qos> access-ingress 10
     dot1p-classification 10
     meter 1 create
        rate pir max cir 0
     exit
meter 9 multi-point create
     rate pir 100 cir 0
     exit
table-classification-criteria use-dot1p 
     default-fc h1 profile in
exit

TC = 2 x 1 (for FC nc) + 2 x 1 (for default-dot1p-fc be) + 2 (for default-fc h1) = 6

TP = 2 x 2 = 4; (only 2 default meters)

The num-qos-classifiers value should be set to max (TC, TP) = max (6, 4) = 6

18.2.1.5.2. Example 2

The following output example shows the FC mapping in a configured dot1p classification policy, in which the FC is using the default meters (meter 1 for unicast and meter 9 for multicast).

configure> qos> dot1p-classification 10
dot1p 7 fc nc
dot1p 6 fc nc
default-dot1p-fc be profile out
exit
configure> qos> access-ingress 20
     dot1p-classification 10
     meter 1 create
        rate pir max cir 0
     exit
meter 9 multi-point create
     rate pir 100 cir 0
     exit
table-classification-criteria use-dot1p 
     default-fc be profile out
exit

TC = 2 x 1 (for FC nc) + 2 x 1 (for default-dot1p-fc be) + 2 (for default-fc be) = 6

TP = 2 x 2= 4; (only 2 default meters)

The num-qos-classifiers value should be set to max (TC, TP) = max (6, 4) = 6

18.2.1.5.3. Example 3

The following output example shows the configuration of the FC mapping in a dot1p classification policy, in which the FC is using both user-defined and default meters.

Note:

By default, unicast meter 1 and multipoint meter 9 are used if no explicit meter mapping is defined for the FC.

configure> qos> dot1p-classification 10
dot1p 7 fc nc
dot1p 6 fc nc
default-dot1p-fc be profile out
exit
 
configure> qos> access-ingress 30
dot1p-classification 10
meter 1 create
rate pir max cir 0
     exit
     meter 9 multi-point create
          rate pir 100 cir 0
     exit
     meter 2 create
     rate 100 max cir 100
exit
     meter 10 multi-point create
     rate pir 100 cir 0
     exit
 
     fc nc
     meter 2
     multicast-meter 10
 exit
table-classification-criteria use-dot1p 
     default-fc be profile out
exit

TC = 2 x 1 (for FC nc) + 2 x 1 (for default-dot1p-fc be) + 2 (for default-fc be) = 6

TP = 2 x 4 = 8; (2 default meters and 2 user-defined meters)

The num-qos-classifiers value should be set to max (TC, TP) = max (6, 8) = 8

18.2.2. Configuration Guidelines for Using a Port-based Access Ingress QoS Policy

Use the following guidelines to configure a port-based access ingress QoS policy on the 7210 SAS-Mxp.

  1. Delete all SAPs on the port or the LAG before changing between the sap-mode and port-mode options for the access-ingress-qos-mode command.
  2. Perform the following steps before changing the access-ingress-qos-mode command to port-mode.
    1. Reboot the node in sap-scale-mode high.
    2. Ensure that resources are allocated to qos-access-ingress-resource.
    3. Configure an access port using the config>port>ethernet>mode command with the access option specified.
  3. If the config>port>ethernet>access-ingress-qos-mode command is set to port-mode, access ingress policy 1 is attached to the port by default. The policy can be replaced with a user-defined access ingress QoS policy provided that sufficient resources are available in the qos-access-port-ingress-resource slice.
  4. Resource allocation from qos-access-port-ingress-resource has no restrictions. Resources can be allocated in sap-scale-mode low and high; however, allocating resources in sap-scale-mode low wastes resources because an access ingress QoS policy can only be attached in sap-scale-mode high.
  5. Reset the user-defined access ingress QoS policy to 1 on the port before changing the access-ingress-qos-mode command to sap-mode.
  6. If the access-ingress-qos-mode command is configured in the config>lag context, reset the user-defined access ingress QoS policy to 1 on the primary LAG member before changing the access-ingress-qos-mode command to sap-mode.

18.2.3. Basic Configurations

A basic access ingress QoS policy must conform to the following configurations.

  1. The policy must have a unique access ingress QoS policy ID.
  2. The policy can have meters defined for use with meter parameters specified, such as CIR and PIR.
  3. The policy can have a dot1p and DSCP template attachment to map dot1p and IP DSCP values to the FC.
  4. The policy has an optional configuration to choose either IP DSCP or dot1p or both for classification. The user can also assign an ingress profile based on either a dot1p, DEI with dot1p, or IP DSCP.

The following output is an example configuration of an access ingress QoS policy.

*A:Dut-A>config>qos# access-ingress 10 
*A:Dut-A>config>qos>access-ingress# info 
----------------------------------------------
            meter 1 create
                mode trtcm2 
                adaptation-rule cir min
                rate cir 1010 pir 4040
                color-mode color-blind
                mbs 512 bytes
                cbs 100 kbytes
            exit
            meter 3 create
            exit
            meter 5 multi-point create
            exit
            meter 9 multi-point create
            exit
            fc "ef" create
                meter 3
                multicast-meter 5
            exit
            counter-mode forward-drop-count
            default-fc "ef" profile in 
            dot1p-classification 40
            dscp-classification 30
            table-classification-criteria use-dscp
            num-qos-classifiers 8
----------------------------------------------

18.2.3.1. Editing an Access Ingress QoS Policy Configuration

The user can edit existing policies and entries through the CLI or NMS. The changes are applied immediately to all services to which the policy applies.

Perform the following to prevent configuration errors.

  1. Copy the policy to a work area.
  2. Edit the policy.
  3. Overwrite the original policy.
Note:

The num-resources parameter value for the config>qos>access-ingress>num-qos-classifiers command cannot be modified when the policy is in use.

18.2.3.2. Removing a Policy from the QoS Configuration

Use the following syntax to remove an access ingress policy from the QoS configuration.

CLI Syntax:
config>qos# no access-ingress policy-id
Example:
config>qos# no access-ingress 100
config>qos# no access-ingress 1010

18.2.3.3. Deleting Access Ingress QoS Policies

Every access Ethernet port is associated, by default, with the default access ingress policy (policy-id 1) when the access-ingress-qos mode command is set to port-mode. You can replace the default policy with a user-defined policy. If the non-default access ingress policy is removed, the association reverts to default policy-id 1. A QoS policy cannot be deleted until it is removed from all access ports where it is applied.

*A:card-1>config>qos# no access-ingress 30
MINOR: CLI Could not remove Access ingress policy "30" because it is in use.
Note:

The access-ingress-qos-mode command can only be changed to sap-mode if access ingress policy 1 is attached to the port.