Cisco MDS 9000 Family CLI Configuration Guide, Release 3.3(3)
Configuring Fabric Congestion Control and QoS

Table Of Contents

Configuring Fabric Congestion Control and QoS

FCC

About FCC

FCC Process

Enabling FCC

Assigning FCC Priority

Displaying FCC Settings

QoS

About Control Traffic

Enabling or Disabling Control Traffic

Displaying Control Traffic Information

About Data Traffic

VSAN Versus Zone-Based QoS

Configuring Data Traffic

QoS Initiation for Data Traffic

About Class Map Creation

Creating a Class Map

About Service Policy Definition

Specifying Service Policies

About Service Policy Enforcement

Applying Service Policies

About the DWRR Traffic Scheduler Queue

Changing the Weight in a DWRR Queue

Displaying Data Traffic Information

Example Configuration

Ingress Port Rate Limiting

Default Settings


Configuring Fabric Congestion Control and QoS


Fibre Channel Congestion Control (FCC) is a Cisco proprietary flow control mechanism that alleviates congestion on Fibre Channel networks.

Quality of service (QoS) offers the following advantages:

Provides relative bandwidth guarantee to application traffic.

Controls latency experienced by application traffic.

Prioritizes one application over another (for example, prioritizing transactional traffic over bulk traffic) through bandwidth and latency differentiation.

This chapter provides details on the QoS and FCC features provided in all switches. It includes the following sections:

FCC

QoS

Example Configuration

Ingress Port Rate Limiting

Default Settings

FCC

FCC reduces the congestion in the fabric without interfering with the standard Fibre Channel protocols. This section contains the following topics:

About FCC

FCC Process

Enabling FCC

Assigning FCC Priority

Displaying FCC Settings

About FCC

The FCC protocol increases the granularity and the scale of congestion control applied to any class of traffic (see Figure 57-1).

Figure 57-1 FCC Mechanisms

Edge quench congestion control provides feedback to the source about the rate at which frames should be injected into the network (frame intervals).


Note FCC is not supported on the Cisco Fabric Switch for HP c-Class BladeSystem and Cisco Fabric Switch for IBM BladeCenter.


FCC Process

When a node in the network detects congestion for an output port, it generates an edge quench message. These frames are identified by the Fibre Channel destination ID (DID) and the source ID. A switch from other vendors simply forwards these frames.

Any receiving switch in the Cisco MDS 9000 Family handles frames in one of these ways:

It forwards the frame.

It limits the rate of the frame flow in the congested port.

The behavior of the flow control mechanism differs based on the Fibre Channel DID:

If the Fibre Channel DID is directly connected to one of the switch ports, the input rate limit is applied to that port.

If the destination of the edge quench frame is a Cisco domain or the next hop is a Cisco MDS 9000 Family switch, the frame is forwarded.

If neither of these mechanisms is true, then the frame is processed in the port going towards the FC DID.

All switches (including the edge switch) along the congested path process path quench frames. However, only the edge switch processes edge quench frames.

Enabling FCC

By default, the FCC protocol is disabled. FCC can only be enabled for the entire switch.


Tip If you enable FCC, be sure to enable it in all switches in the fabric.


To enable or disable the FCC feature, follow these steps:

 
Command
Purpose

Step 1 

switch# config t

Enters configuration mode.

Step 2 

switch(config)# fcc

Enables FCC in this switch.

switch(config)# no fcc

Disables FCC in this switch (default).

Assigning FCC Priority

To assign FCC priority, follow these steps:

 
Command
Purpose

Step 1 

switch# config t

Enters configuration mode.

Step 2 

switch(config)# fcc priority 2

Defines the FCC priority threshold to have a priority of 2—0 is the lowest priority and 7 is the highest priority.

Displaying FCC Settings

Use the show fcc command to view FCC settings (see Example 57-1).

Example 57-1 Displays Configured FCC Information

switch# show fcc
fcc is disabled
fcc is applied to frames with priority up to 4

QoS

QoS implementation in the Cisco MDS 9000 Family follows the differentiated services (DiffServ) model. The DiffServ standard is defined in RFCs 2474 and 2475.

All switches support the following types of traffic:

About Control Traffic

Enabling or Disabling Control Traffic

Displaying Control Traffic Information

About Data Traffic

VSAN Versus Zone-Based QoS

Configuring Data Traffic

QoS Initiation for Data Traffic

About Class Map Creation

Creating a Class Map

About Service Policy Definition

Specifying Service Policies

About Service Policy Enforcement

Applying Service Policies

About the DWRR Traffic Scheduler Queue

Changing the Weight in a DWRR Queue

Displaying Data Traffic Information

About Control Traffic

The Cisco MDS 9000 Family supports QoS for internally and externally generated control traffic. Within a switch, control traffic is sourced to the supervisor module and is treated as a high priority frame. A high priority status provides absolute priority over all other traffic and is assigned in the following cases:

Internally generated time-critical control traffic (mostly Class F frames).

Externally generated time-critical control traffic entering a switch in the Cisco MDS 9000 Family from a another vendor's switch. High priority frames originating from other vendor switches are marked as high priority as they enter a switch in the Cisco MDS 9000 Family.

Enabling or Disabling Control Traffic

By default, the QoS feature for certain critical control traffic is enabled. These critical control frames are assigned the highest (absolute) priority.


Tip We do not recommend disabling this feature as all critical control traffic is automatically assigned the lowest priority once you issue this command.


To disable the high priority assignment for control traffic, follow these steps:

 
Command
Purpose

Step 1 

switch# config t

Enters configuration mode.

Step 2 

switch(config)# no qos control priority 0

Enables the control traffic QoS feature.

switch(config)# qos control priority 0

Disables the control traffic QoS feature.

Displaying Control Traffic Information

Use the show qos statistics command to view the current state of the QoS configuration for critical control traffic. This command displays the current QoS settings along with the number of frames marked high priority. The count is only for debugging purposes and cannot be configured (see Example 57-2).

Example 57-2 Displays Current QoS Settings

switch# show qos statistics
Total number of FC frames transmitted from the Supervisor= 15767
Number of highest-priority FC frames transmitted         = 8224
Current priority of FC control frames = 0    (0 = lowest; 7 = highest)

About Data Traffic

Online transaction processing (OLTP), which is a low volume, latency sensitive application, requires quick access to requested information. Backup processing application require high bandwidth but are not sensitive to latency. In a network that does not support service differentiation, all traffic is treated identically—they experience similar latency and are allocated similar bandwidths. The QoS feature in the Cisco MDS 9000 Family switches provides these guarantees.

Data traffic can be prioritized in distinct levels of service differentiation: low, medium, or high priority. You can apply QoS to ensure that Fibre Channel data traffic for your latency-sensitive applications receive higher priority over throughput-intensive applications such as data warehousing (see Figure 57-2).

Figure 57-2 Prioritizing Data Traffic

In Figure 57-2, the OLTP traffic arriving at Switch 1 is marked with a high priority level of throughput classification (class map) and marking (policy map). Similarly, the backup traffic is marked with a low priority level. The traffic is sent to the corresponding priority queue within a virtual output queue (VOQ).

A deficit weighted round robin (DWRR) scheduler configured in the first switch ensures that high priority traffic is treated better than low priority traffic. For example, DWRR weights of 70:20:10 implies that the high priority queue is serviced at 7 times the rate of the low priority queue. This guarantees lower delays and higher bandwidths to high priority traffic if congestion sets in. A similar configuration in the second switch ensures the same traffic treatment in the other direction.

If the ISL is congested when the OLTP server sends a request, the request is queued in the high priority queue and is serviced almost immediately since the high priority queue is not congested. The scheduler assigns its priority over the backup traffic in the low priority queue.


Note When the high priority queue does not have traffic flowing through, the low priority queue uses all the bandwidth and is not restricted to the configured value.


A similar occurrence in Switch 2 sends a response to the transaction request. The round trip delay experienced by the OLTP server is independent of the volume of low priority traffic or the ISL congestion. The backup traffic uses the available ISL bandwidth when it is not used by the OLTP traffic.


Tip To achieve this traffic differentiation, be sure to enable FCC (see the "Enabling FCC" section).


VSAN Versus Zone-Based QoS

While you can configure both zone-based QoS and VSAN-based QoS configurations in the same switch, both configurations have significant differences. Table 57-1 highlights the differences between configuring QoS priorities based on VSANs versus zones.

Table 57-1 QoS Configuration Differences 

VSAN-Based QoS
Zone-Based QoS

If you configure the active zone set on a given VSAN and also configure QoS parameters in any of the member zones, you cannot associate the policy map with the VSAN.

You cannot activate a zone set on a VSAN that already has a policy map associated.

If the same flow is present in two class maps associated to a policy map, the QoS value of the class map attached first takes effect.

If the same flow is present in two zones in a given zone set with different QoS values, the higher QoS value is considered.

During a zone merge, if the Cisco SAN-OS software detects a mismatch for the QoS parameter, the link is isolated.

Takes effect only when QoS is enabled.

Takes effect only when QoS is enabled.


See the "About Zone-Based Traffic Priority" section on page 24-18 for details on configuring a zone-based QoS policy.

Configuring Data Traffic

To configure QoS, follow these steps:.


Step 1 Enable the QoS feature.

Step 2 Create and define class maps.

Step 3 Define service policies.

Step 4 Apply the configuration.


QoS Initiation for Data Traffic

By default, the QoS data traffic feature is disabled for data traffic. To configure QoS for data traffic, you must first enable the data traffic feature in the switch.


Tip QoS is supported in interoperability mode. For more information, refer to the Cisco MDS 9000 Family Switch-to-Switch Interoperability Configuration Guide.


To enable the QoS data traffic feature, follow these steps:

 
Command
Purpose

Step 1 

switch# config t

Enters configuration mode.

Step 2 

switch(config)# qos enable

Enables QoS. You can now configure data traffic parameters.

switch(config)# no qos enable

Removes the currently applied QoS configuration and disables QoS. You can no longer configure data traffic parameters.

About Class Map Creation

Use the class map feature to create and define a traffic class with match criteria to identify traffic belonging to that class. The class map name is restricted to 63 alphanumeric characters and defaults to the match-all option. Flow-based traffic uses one of the following values:

WWN—The source WWN or the destination WWN.

Fibre Channel ID (FC ID) —The source ID (SID) or the destination ID (DID). The possible values for mask are FFFFFF (the entire FC ID is used—this is the default), FFFF00 (only domain and area FC ID is used), or FF0000 (only domain FC ID is used).


Note An SID or DID of 0x000000 is not allowed.


Source interface—The ingress interface.


Tip The order of entries to be matched within a class map is not significant.


Creating a Class Map

Use the class-map command to create and define a traffic class with match criteria to identify traffic belonging to that class. Define each match criterion with one match statement from the class map configuration (switch(config-cmap)) mode.

Use the source-wwn option to specify the source WWN or the destination-wwn option to specify the destination WWN.

Use the source-address option to specify the source ID (SID) or the destination-address option to specify the destination ID (DID).

Use the input-interface option to specify the ingress interface.

Use the destination-device-alias option to specify the distributed device alias.

To create a class map, follow these steps:

 
Command
Purpose

Step 1 

switch(config)# qos class-map MyClass

switch(config-cmap)#

Creates a class map called MyClass and places you in the class-map submode to match all criteria specified for this class.

switch(config)# qos class-map MyClass match-all

switch(config-cmap)#

Specifies a logical AND operator for all matching statements in this class. If a frame matches all (default) configured criteria, it qualifies for this class. This is the default.

switch(config)# qos class-map MyClass match-any

switch(config-cmap)#

Specifies a logical OR operator for all matching statements in this class. If a frame matches any one configured criteria, it qualifies for this class.

Step 2 

switch(config-cmap)# match destination-address 0x12ee00

Specifies a destination address match for frames with the specified destination FC ID.

switch(config-cmap)# match source-address 0x6d1090 mask 0xFFFFFF

Specifies a source address and mask match for frames with the specified source FC ID.

Step 3 

switch(config-cmap)# match destination-wwn 20:01:00:05:30:00:28:df

Specifies a destination WWN to match frames.

switch(config-cmap)# match source-wwn 23:15:00:05:30:00:2a:1f

Specifies a source WWN to match frames.

Step 4 

switch(config-cmap)# match destination-device-alias DocDeviceAlias

Specifies a destination device alias to match frames.

Step 5 

switch(config-cmap)# match input-interface fc 2/1

Specifies a source interface to match frames.

Step 6 

switch(config-cmap)# no match input-interface fc 3/5

Removes a match based on the specified source interface.

About Service Policy Definition

Service policies are specified using policy maps. Policy maps provide an ordered mapping of class maps to service levels. You can specify multiple class maps within a policy map, and map a class map to a high, medium, or low service level. The default priority is low. The policy map name is restricted to 63 alphanumeric characters.

As an alternative, you can map a class map to a differentiated services code point (DSCP).The DSCP is an indicator of the service level for a specified frame. The DSCP value ranges from 0 to 63, and the default is 0. A DSCP value of 46 is disallowed.

The order of the class maps within a policy map is important to determine the order in which the frame is compared to class maps. The first matching class map has the corresponding priority marked in the frame.


Note Refer to /en/US/tech/tk543/tk757/technologies_tech_note09186a00800949f2.shtml#dscpandassuredforwardingclasses for further information on implementing QoS DSCP values.



Note Class maps are processed in the order in which they are configured in each policy map.


Specifying Service Policies

To specify a service policy, follow these steps:

 
Command
Purpose

Step 1 

switch(config)# qos policy-map MyPolicy

switch(config-pmap)#

Creates a policy map called MyPolicy and places you in the policy-map submode.

switch(config)# no qos policy-map OldPolicy

switch(config)#

Deletes the policy map called OldPolicy and places you in the policy-map submode.

Step 2 

switch(config-pmap)# class MyClass

switch(config-pmap-c)#

Specifies the name of a predefined class and places you at the policy-map submode for that class.

switch(config-pmap)# no class OldClass

Removes the class map called OldClass from the policy map.

Step 3 

switch(config-pmap-c)# priority high

Specifies the priority to be given for each frame matching this class.

switch(config-pmap-c)# no priority high

Deletes a previously assigned priority and reverts to the default value of low.

Step 4 

switch(config-pmap-c)# dscp 2

Specifies the DSCP value to mark each frame matching this class.

switch(config-pmap-c)# no dscp 60

Deletes a previously assigned DSCP value and reverts to the factory default of 0.

About Service Policy Enforcement

When you have configured a QoS data traffic policy, you must enforce the data traffic configuration by applying that policy to the required VSAN(s). If you do not apply the policy to a VSAN, the data traffic configuration is not enforced. You can only apply one policy map to a VSAN.


Note You can apply the same policy to a range of VSANs.


Applying Service Policies

To apply a service policy, follow these steps:

 
Command
Purpose

Step 1 

switch(config)# qos service policy MyPolicy vsan 3

Applies a configured policy to VSAN 3.

switch(config)# no qos service policy OldPolicy vsan 7

Deletes a configured policy that was applied to VSAN 7.

About the DWRR Traffic Scheduler Queue

The Cisco SAN-OS software supports four scheduling queues:

Strict priority queues are queues that are serviced in preference to other queues—it is always serviced if there is a frame queued in it regardless of the state of the other queues.

QoS assigns all other traffic to the DWRR scheduling high, medium, and low priority traffic queues.

The DWRR scheduler services the queues in the ratio of the configured weights. Higher weights translate to proportionally higher bandwidth and lower latency. The default weights are 50 for the high queue, 30 for the medium queue, and 20 for the low queue. Decreasing order of queue weights is mandated to ensure the higher priority queues have a higher service level, though the ratio of the configured weights can vary (for example, one can configure 70:30:5 or 60:50:10 but not 50:70:10).

Table 57-2 describes the QoS behavior for Generation 1 and Generation 2 switching modules.

Table 57-2 QoS Behavior for Generation 1 and Generation 2 Switching Modules

Source Module Type
Destination Module Type
QoS Behavior Description

Generation 1

Generation 1

QoS behavior reflects the DWRR configuration for traffic coming in through a given port and queued to the same egress port. All the other traffic share equal bandwidth.

Generation 1

Generation 2

QoS behavior reflects the DWRR configuration for traffic coming in through a given port and queued to the same egress port. All the other streams share equal bandwidth.

Generation 2

Generation 1

Bandwidth partitioning is equal for all the traffic.

Generation 2

Generation 2

QoS behavior reflects the DWRR weights configuration for all possible streams.


Changing the Weight in a DWRR Queue

To associate a weight with a DWRR queue, follow these steps:

 
Command
Purpose

Step 1 

switch(config)# qos dwrr-q high weight 10

Associates a relative weight (10) to a specified queue (default queue).

switch(config)# no qos dwrr-q low weight 51

Restores the default weight of 20.

Displaying Data Traffic Information

The show qos commands display the current QoS settings for data traffic (see Examples 57-3 to 57-11).

Example 57-3 Displays the Contents of all Class Maps

switch# show qos class-map
qos class-map MyClass match-any
    match destination-wwn 20:01:00:05:30:00:28:df
    match source-wwn 23:15:00:05:30:00:2a:1f
    match input-interface fc2/1
qos class-map Class2 match-all
    match input-interface fc2/14
qos class-map Class3 match-all
    match source-wwn 20:01:00:05:30:00:2a:1f

Example 57-4 Displays the Contents of a Specified Class Map

switch# show qos class-map name MyClass
qos class-map MyClass match-any
    match destination-wwn 20:01:00:05:30:00:28:df
    match source-wwn 23:15:00:05:30:00:2a:1f
    match input-interface fc2/1

Example 57-5 Displays All Configured Policy Maps

switch# show qos policy-map
qos policy-map MyPolicy
    class MyClass
    priority medium
qos policy-map Policy1
    class Class2
    priority low

Example 57-6 Displays a Specified Policy Map

switch# show qos policy-map name MyPolicy
qos policy-map MyPolicy
    class MyClass
        priority medium

Example 57-7 Displays Scheduled DWRR Configurations

switch# show qos dwrr
qos dwrr-q high weight 50
qos dwrr-q medium weight 30
qos dwrr-q low weight 20

Example 57-8 Displays All Applied Policy Maps

switch# show qos service policy
qos service policy MyPolicy vsan 1
qos service policy Policy1 vsan 4

Example 57-9 Displays the Policy Map Associated with a Specified VSAN

switch# show qos service policy vsan 1
qos policy-map pmap1
   class cmap1
       priority medium
   class cmap2
       priority high

Example 57-10 Displays the Class Map Associated with a Specified Interface

switch# show qos service policy interface fc3/10
qos policy-map pmap1
   class cmap3
       priority high
   class cmap4
       priority low

Example 57-11 Displays QoS Statistics

switch# show qos statistics
Total number of FC frames transmitted from the Supervisor= 301431
Number of highest-priority FC frames transmitted         = 137679
Current priority of FC control frames = 7    (0 = lowest; 7 = highest)

Example Configuration

This section describes a configuration example for the application illustrated in Figure 57-3.

Figure 57-3 Example Application for Traffic Prioritization

Both the OLTP server and the backup server are accessing the disk. The backup server is writing large amounts of data to the disk. This data does not require specific service guarantees. The volumes of data generated by the OLTP server to the disk are comparatively much lower but this traffic requires faster response because transaction processing is a low latency application.

The point of congestion is the link between Switch 2 and the disk, for traffic from the switch to the disk. The return path is largely uncongested as there is little backup traffic on this path.

Service differentiation is needed at Switch 2 to prioritize the OLTP-server-to-disk traffic higher than the backup-server-to-disk traffic.

To configure traffic prioritization for the example application, follow these steps:


Step 1 Create the class maps.

Switch 2# config t
Switch 2(config)# qos class-map jc1 match-all
Switch 2(config-cmap)# match source-wwn 21:00:00:0c:50:02:ca:b5
Switch 2(config-cmap)# match destination-wwn 22:00:00:04:cf:22:eb:dc
Switch 2(config-cmap)# exit
Switch 2(config)# qos class-map jc2 match-all
Switch 2(config-cmap)# match source-wwn 21:00:00:0c:50:02:c7:ff
Switch 2(config-cmap)# match destination-wwn 22:00:00:04:cf:22:eb:dc
Switch 2(config-cmap)# exit
Switch 2(config)# 

Step 2 Create the policy map.

Switch 2(config)# qos policy-map jp1
Switch 2(config-pmap)# class jc1
Switch 2(config-pmap-c)# priority high
Switch 2(config-pmap-c)# exit
Switch 2(config-pmap)# class jc2
Switch 2(config-pmap-c)# priority low
Switch 2(config-pmap-c)# exit
Switch 2(config-pmap)# exit
Switch 2(config)#

Step 3 Assign the service policy.

Switch 2(config)# qos service policy jp1 vsan 1

Step 4 Assign the weights for the DWRR queues.

Switch 2(config)# qos dwrr-q high weight 50
Switch 2(config)# qos dwrr-q medium weight 30
Switch 2(config)# qos dwrr-q low weight 20

Step 5 Repeat Step 1 through Step 4 on Switch 1 to address forward path congestion at both switches.


Congestion could occur anywhere in the example configuration. To address congestion of the return path at both switches, you need to create two more class maps and include them in the policy map as follows:


Step 1 Create two more class maps.

Switch 2(config)# qos class-map jc3 match-all
Switch 2(config-cmap)# match source-wwn 22:00:00:04:cf:22:eb:dc
Switch 2(config-cmap)# match destination-wwn 21:00:00:0c:50:02:ca:b5
Switch 2(config-cmap)# exit
Switch 2(config)# qos class-map jc4 match-all
Switch 2(config-cmap)# match source-wwn 22:00:00:04:cf:22:eb:dc
Switch 2(config-cmap)# match destination-wwn 21:00:00:0c:50:02:c7:ff
Switch 2(config-cmap)# exit
Switch 2(config)#

Step 2 Assign the class maps to the policy map.

Switch 2(config)# qos policy-map jp1
Switch 2(config-pmap)# class jc3
Switch 2(config-pmap-c)# priority high
Switch 2(config-pmap-c)# exit
Switch 2(config-pmap)# class jc4
Switch 2(config-pmap-c)# priority low
Switch 2(config-pmap-c)# exit
Switch 2(config-pmap)# exit
Switch 2(config)#

Step 3 Repeat Step 1 through Step 2 on Switch 1 to address return path congestion at both switches.


Ingress Port Rate Limiting

A port rate limiting feature helps control the bandwidth for individual Fibre Channel ports. Port rate limiting is also referred to as ingress rate limiting because it controls ingress traffic into a Fibre Channel port. The feature controls traffic flow by limiting the number of frames that are transmitted out of the exit point on the MAC. Port rate limiting works on all Fibre Channel ports. The rate limit ranges from 1 to 100% and the default is 100%.


Note Port rate limiting can only be configured on Cisco MDS 9100 Series switches, Cisco MDS 9216i switches, and MPS-14/2 modules.


This feature can only be configured if the QoS feature is enabled and if this configuration is performed on a Cisco MDS 9100 series switch, Cisco MDS 9216i switch, or MPS-14/2 module.

To configure the port rate limiting value, follow these steps.

 
Command
Purpose

Step 1 

switch # config t

switch(config)#

Enters the configuration mode.

Step 2 

switch(config)# interface fc 1/1

Selects the interface to specify the ingress port rate limit.

Step 3 

switch(config-if)# switchport ingress-rate 50

Configures a 50% port rate limit for the selected interface.

switch(config-if)# no switchport ingress-rate 50

Reverts a previously configured rate to the factory default of 100%.

Default Settings

Table 57-3 lists the default settings for FCC, QoS, and rate limiting features.

.

Table 57-3 Default FCC, QoS, and Rate Limiting Settings 

Parameters
Default

FCC protocol

Disabled.

QoS control traffic

Enabled.

QoS data traffic

Disabled.

Zone-based QoS priority

Low.

Rate limit

100%.