Table Of Contents
WRED — Explicit Congestion Notification
ECN Extends WRED Functionality
How Packets Are Treated When ECN Is Enabled
Supported Standards, MIBs, and RFCs
Configuring Explicit Congestion Notification
Verifying the Explicit Congestion Notification Configuration
Verifying the ECN Configuration Example
WRED — Explicit Congestion Notification
Feature History
This document describes the WRED — Explicit Congestion Notification feature in Cisco IOS Release 12.2(8)T. It includes the following sections:
•
Supported Standards, MIBs, and RFCs
Feature Overview
Currently, the congestion control and avoidance algorithms for Transmission Control Protocol (TCP) are based on the idea that packet loss is an appropriate indication of congestion on networks transmitting data using the best-effort service model. When a network uses the best-effort service model, the network delivers data if it can, without any assurance of reliability, delay bounds, or throughput. However, these algorithms and the best-effort service model are not suited to applications that are sensitive to delay or packet loss (for instance, interactive traffic including Telnet, web-browsing, and transfer of audio and video data). Weighted Random Early Detection (WRED), and by extension, Explicit Congestion Notification (ECN), helps to solve this problem.
RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP, states that with the addition of active queue management (for example, WRED) to the Internet infrastructure, routers are no longer limited to packet loss as an indication of congestion.
How WRED Works
WRED makes early detection of congestion possible and provides a means for handling multiple classes of traffic. WRED can selectively discard lower priority traffic when the router begins to experience congestion and provide differentiated performance characteristics for different classes of service. It also protects against global synchronization. Global synchronization occurs as waves of congestion crest, only to be followed by periods of time during which the transmission link is not used to capacity. For these reasons, WRED is useful on any output interface or router where congestion is expected to occur.
WRED is implemented at the core routers of a network. Edge routers assign IP precedences to packets as the packets enter the network. With WRED, core routers then use these precedences to determine how to treat different types of traffic. WRED provides separate thresholds and weights for different IP precedences, enabling the network to provide different qualities of service, in regard to packet dropping, for different types of traffic. Standard traffic may be dropped more frequently than premium traffic during periods of congestion.
For more information about WRED, refer to the "Congestion Avoidance Overview" chapter of the Cisco IOS Quality of Service Solutions Configuration Guide, Release 12.2.
ECN Extends WRED Functionality
WRED drops packets, based on the average queue length exceeding a specific threshold value, to indicate congestion. ECN is an extension to WRED in that ECN marks packets instead of dropping them when the average queue length exceeds a specific threshold value. When configured with the WRED — Explicit Congestion Notification feature, routers and end hosts would use this marking as a signal that the network is congested and slow down sending packets.
As stated in RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP, implementing ECN requires an ECN-specific field that has two bits—the ECN-capable Transport (ECT) bit and the CE (Congestion Experienced) bit—in the IP header. The ECT bit and the CE bit can be used to make four ECN field combinations of 00 to 11. The first number is the ECT bit and the second number is the CE bit. Table 1 lists each of the ECT and CE bit combination settings in the ECN field and what the combinations indicate.
The ECN field combination 00 indicates that a packet is not using ECN.
The ECN field combinations 01 and 10—called ECT(1) and ECT(0), respectively—are set by the data sender to indicate that the endpoints of the transport protocol are ECN-capable. Routers treat these two field combinations identically. Data senders can use either one or both of these two combinations. For more information about these two field combinations, and the implications of using one over the other, refer to RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP.
The ECN field combination 11 indicates congestion to the endpoints. Packets arriving a full queue of a router will be dropped.
How Packets Are Treated When ECN Is Enabled
•
If the number of packets in the queue is below the minimum threshold, packets are transmitted. This happens whether or not ECN is enabled, and this treatment is identical to the treatment a packet receives when WRED only is being used on the network.
•
If the number of packets in the queue is between the minimum threshold and the maximum threshold, one of the following three scenarios can occur:
–
If the ECN field on the packet indicates that the endpoints are ECN-capable (that is, the ECT bit is set to 1 and the CE bit is set to 0, or the ECT bit is set to 0 and the CE bit is set to 1)—and the WRED algorithm determines that the packet should have been dropped based on the drop probability—the ECT and CE bits for the packet are changed to 1, and the packet is transmitted. This happens because ECN is enabled and the packet gets marked instead of dropped.
–
If the ECN field on the packet indicates that neither endpoint is ECN-capable (that is, the ECT bit is set to 0 and the CE bit is set to 0), the packet may be dropped based on the WRED drop probability. This is the identical treatment that a packet receives when WRED is enabled without ECN configured on the router.
–
If the ECN field on the packet indicates that the network is experiencing congestion (that is, both the ECT bit and the CE bit are set to 1), the packet is transmitted. No further marking is required.
•
If the number of packets in the queue is above the maximum threshold, packets are dropped based on the drop probability. This is the identical treatment a packet receives when WRED is enabled without ECN configured on the router.
For More Information
For more information about implementing ECN and about the changes required at the routers and end hosts, refer to the following RFCs:
•
RFC 2309, Internet Performance Recommendations
•
RFC 2884, Performance Evaluation of Explicit Congestion Notification (ECN) in IP Networks
•
RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP
Benefits
Improved Method for Congestion Avoidance
This feature provides an improved method for congestion avoidance by allowing the network to mark packets for transmission later, rather than dropping them from the queue. Marking the packets for transmission later accommodates applications that are sensitive to delay or packet loss and provides improved throughput and application performance.
Enhanced Queue Management
Currently, dropped packets indicate that a queue is full and the network is experiencing congestion. When a network experiences congestion, this feature allows networks to mark the IP header of a packet with a CE bit. This marking, in turn, triggers the appropriate congestion avoidance mechanism and allows the network to better manage the data queues. With this feature, ECN-capable routers and end hosts can respond to congestion before a queue overflows and packets are dropped, providing enhanced queue management.
For more information on the benefits associated with ECN, refer to RFC 2309, Internet Performance Recommendations.
Related Documents
•
Cisco IOS Quality of Service Solutions Configuration Guide, Release 12.2
•
Cisco IOS Quality of Service Solutions Command Reference, Release 12.2
•
RFC 2309, Internet Performance Recommendations
•
RFC 2884, Performance Evaluation of Explicit Congestion Notification (ECN) in IP Networks
•
RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP
Supported Platforms
•
Cisco 805
•
Cisco 806
•
Cisco 820
•
Cisco 828
•
Cisco 1400 series
•
Cisco 1600 series
•
Cisco 1751
•
Cisco 2420
•
Cisco 3631
•
Cisco 3725
•
Cisco 3745
•
Cisco 7100 series
•
Cisco 7200 series
•
Cisco 7500
•
Cisco 7700
•
Cisco CVA120 series
•
Cisco MC3810
•
Cisco uBR7200 series
•
URM (Universal Route Module)
Determining Platform Support Through Cisco Feature Navigator
Cisco IOS software is packaged in feature sets that support specific platforms. To get updated information regarding platform support for this feature, access Cisco Feature Navigator. Cisco Feature Navigator dynamically updates the list of supported platforms as new platform support is added for the feature.
Cisco Feature Navigator is a web-based tool that enables you to quickly determine which Cisco IOS software images support a specific set of features and which features are supported in a specific Cisco IOS image. You can search by feature or release. Under the release section, you can compare releases side by side to display both the features unique to each software release and the features in common.
Cisco Feature Navigator is updated regularly when major Cisco IOS software releases and technology releases occur. For the most current information, go to the Cisco Feature Navigator home page at the following URL:
Supported Standards, MIBs, and RFCs
Standards
No new or modified standards are supported by this feature.
MIBs
No new or modified MIBs are supported by this feature.
To obtain lists of supported MIBs by platform and Cisco IOS release, and to download MIB modules, go to the Cisco MIB website on Cisco.com at the following URL:
http://www.cisco.com/public/sw-center/netmgmt/cmtk/mibs.shtml
RFCs
•
RFC 2309, Internet Performance Recommendations
•
RFC 2884, Performance Evaluation of Explicit Congestion Notification (ECN) in IP Networks
•
RFC 3168, The Addition of Explicit Congestion Notification (ECN) to IP
Prerequisites
ECN must be configured through the Modular Quality of Service Command-Line Interface (MQC). For more information about MQC, refer to the "Modular Quality of Service Command-Line Interface" part of the Cisco IOS Quality of Service Solutions Configuration Guide, Release 12.2.
Configuration Tasks
See the following sections for configuration tasks for the WRED — Explicit Congestion Notification feature. Each task in the list is identified as either required or optional.
•
Configuring Explicit Congestion Notification (required)
•
Verifying the Explicit Congestion Notification Configuration (optional)
Configuring Explicit Congestion Notification
To configure ECN, use the following commands beginning in global configuration mode:
Verifying the Explicit Congestion Notification Configuration
To verify the ECN configuration, use the following commands in EXEC or privileged EXEC mode, as needed:
Configuration Examples
This section provides the following configuration examples:
•
Verifying the ECN Configuration Example
Enabling ECN Example
The following example enables ECN in the policy map called pol1:
Router(config)# policy-map pol1Router(config-pmap)# class class-defaultRouter(config-pmap)# bandwidth per 70Router(config-pmap-c)# random-detectRouter(config-pmap-c)# random-detect ecnVerifying the ECN Configuration Example
The following is sample output from the show policy-map command. The words "explicit congestion notification" (along with the ECN marking information) included in the output indicate that ECN has been enabled.
Router# show policy-mapPolicy Map pol1Class class-defaultWeighted Fair QueueingBandwidth 70 (%)exponential weight 9explicit congestion notificationclass min-threshold max-threshold mark-probability--------------------------------------------------------------------------------------------------------------------0 - - 1/101 - - 1/102 - - 1/103 - - 1/104 - - 1/105 - - 1/106 - - 1/107 - - 1/10rsvp - - 1/10The following is sample output from the show policy-map interface command. The words "explicit congestion notification" included in the output indicate that ECN has been enabled.
Router# show policy-map interface Serial4/1Serial4/1Service-policy output:policy_ecnClass-map:prec1 (match-all)1000 packets, 125000 bytes30 second offered rate 14000 bps, drop rate 5000 bpsMatch:ip precedence 1Weighted Fair QueueingOutput Queue:Conversation 42Bandwidth 20 (%)Bandwidth 100 (kbps)(pkts matched/bytes matched) 989/123625(depth/total drops/no-buffer drops) 0/455/0exponential weight:9explicit congestion notificationmean queue depth:0class Transmitted Random drop Tail drop Minimum Maximum Markpkts/bytes pkts/bytes pkts/bytes threshold threshold probability0 0/0 0/0 0/0 20 40 1/101 545/68125 0/0 0/0 22 40 1/102 0/0 0/0 0/0 24 40 1/103 0/0 0/0 0/0 26 40 1/104 0/0 0/0 0/0 28 40 1/105 0/0 0/0 0/0 30 40 1/106 0/0 0/0 0/0 32 40 1/107 0/0 0/0 0/0 34 40 1/10rsvp 0/0 0/0 0/0 36 40 1/10class ECN Markpkts/bytes0 0/01 43/53752 0/03 0/04 0/05 0/06 0/07 0/0rsvp 0/0Command Reference
This section documents new and modified commands. All other commands used with this feature are documented in the Cisco IOS Release 12.2 command reference publications.
New Commands
Modified Commands
random-detect ecn
To enable explicit congestion notification (ECN), use the random-detect ecn command in policy-map class configuration mode. To disable ECN, use the no form of this command.
random-detect ecn
no random-detect ecn
Syntax Description
This command has no arguments or keywords.
Defaults
By default, ECN is disabled.
Command Modes
Policy-map class configuration
Command History
Usage Guidelines
If ECN is enabled, ECN can be used whether WRED is based on the IP precedence value or the differentiated services code point (DSCP) value.
Examples
The following example enables ECN in a policy map called pol1:
Router(config)# policy-map pol1Router(config-pmap)# class class-defaultRouter(config-pmap)# bandwidth per 70Router(config-pmap-c)# random-detectRouter(config-pmap-c)# random-detect ecnRelated Commands
show policy-map
To display the configuration of all classes for a specified service policy map or all classes for all existing policy maps, use the show policy-map command in EXEC or privileged EXEC mode.
show policy-map [policy-map]
Syntax Description
policy-map
(Optional) Name of the service policy map whose complete configuration is to be displayed.
Defaults
All existing policy map configurations are displayed.
Command Modes
EXEC or privileged EXEC
Command History
Usage Guidelines
The show policy-map command displays the configuration of a service policy map created using the policy-map command. You can use the show policy-map command to display all class configurations comprising any existing service policy map, whether or not that service policy map has been attached to an interface.
The show policy-map command will display ECN marking information only if ECN is enabled on the interface.
Examples
The following is sample output from the show policy-map command. The words "explicit congestion notification" (along with the ECN marking information) included in the output indicate that ECN has been enabled.
Router# show policy-mapPolicy Map pol1Class class-defaultWeighted Fair QueueingBandwidth 70 (%)exponential weight 9explicit congestion notificationclass min-threshold max-threshold mark-probability--------------------------------------------------------------------------------------------------------------------0 - - 1/101 - - 1/102 - - 1/103 - - 1/104 - - 1/105 - - 1/106 - - 1/107 - - 1/10rsvp - - 1/10Table 2 describes the significant fields shown in this display.
Related Commands
show policy-map interface
To display the configuration of all classes configured for all service policies on the specified interface or to display the classes for the service policy for a specific permanent virtual circuit (PVC) on the interface, use the show policy-map interface command in EXEC or privileged EXEC mode.
show policy-map interface interface-name [vc [vpi/] vci][dlci dlci]
Syntax Description
Defaults
This command has no default behavior or values.
Command Modes
EXEC or privileged EXEC
Command History
Usage Guidelines
The show policy-map interface command displays the configuration for classes on the specified interface or the specified PVC only if a service policy has been attached to the interface or the PVC.
You can use the interface-name argument to display output for a PVC only for Enhanced ATM port adapters (PA-A3) that support per-VC queueing.
The counters displayed after the show policy-map interface command is entered are updated only if congestion is present on the interface.
The show policy-map interface command displays ECN marking information only if ECN is enabled on the interface.
Examples
The following is sample output from the show policy-map interface command. The words "explicit congestion notification" included in the output indicate that ECN has been enabled.
Router# show policy-map interface Serial4/1Serial4/1Service-policy output:policy_ecnClass-map:prec1 (match-all)1000 packets, 125000 bytes30 second offered rate 14000 bps, drop rate 5000 bpsMatch:ip precedence 1Weighted Fair QueueingOutput Queue:Conversation 42Bandwidth 20 (%)Bandwidth 100 (kbps)(pkts matched/bytes matched) 989/123625(depth/total drops/no-buffer drops) 0/455/0exponential weight:9explicit congestion notificationmean queue depth:0class Transmitted Random drop Tail drop Minimum Maximum Markpkts/bytes pkts/bytes pkts/bytes threshold threshold probability0 0/0 0/0 0/0 20 40 1/101 545/68125 0/0 0/0 22 40 1/102 0/0 0/0 0/0 24 40 1/103 0/0 0/0 0/0 26 40 1/104 0/0 0/0 0/0 28 40 1/105 0/0 0/0 0/0 30 40 1/106 0/0 0/0 0/0 32 40 1/107 0/0 0/0 0/0 34 40 1/10rsvp 0/0 0/0 0/0 36 40 1/10class ECN Markpkts/bytes0 0/01 43/53752 0/03 0/04 0/05 0/06 0/07 0/0rsvp 0/0Table 3 describes the fields associated with the WRED — Explicit Congestion Notification feature shown in this display. For more information about the other fields shown in this display, refer to the documentation for the show policy-map interface command in the Cisco IOS Quality of Service Command Reference, Release 12.2.
Related Commands
